You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xap-commits@incubator.apache.org by bb...@apache.org on 2007/06/25 03:05:26 UTC
svn commit: r550329 [5/13] - in /incubator/xap/site: docs/ docs/xmodify/
docs/xmodify/content/ docs/xmodify/css/ docs/xmodify/doc/
docs/xmodify/doc/complexTypes/ docs/xmodify/doc/complexTypes/html/
docs/xmodify/doc/complexTypes/xml/ docs/xmodify/doc/ov...
Added: incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-attribute-element-type.xml
URL: http://svn.apache.org/viewvc/incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-attribute-element-type.xml?view=auto&rev=550329
==============================================================================
--- incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-attribute-element-type.xml (added)
+++ incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-attribute-element-type.xml Sun Jun 24 20:05:18 2007
@@ -0,0 +1,207 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<complexType targetNamespace="http://openxal.org/core/xmodify"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:event="http://www.w3.org/2001/XMLSchema"
+ xmlns:meta="http://www.w3.org/2001/XMLSchema" name="set-attribute-element-type">
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+<br>The set-attribute command sets the specified attributes in all of the elements
+returned by the XPath query. All attributes to be set need to be specified as
+an attribute directive element (i.e. <xm:attribute name="myattr" value="somevalue"/>)
+<br><br>
+
+A sample set-attribute command element looks like: <br><br>
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify" document="mydocument"><br>
+ <xm:set-attribute select="/ui/rootPane/freePane[1]/button"><br>
+ <xm:attribute name="myattr1" value="somevalue1"/><br>
+ <xm:attribute name="myattr2" value="somevalue2"/><br>
+ </xm:set-attribute><br>
+ </xm:modifications><br><br>
+</pre>
+After the above command is executed, every button element that is a child of the
+first child freePane of the rootPane element in the document "mydocument" will have
+2 new attributes: myattr1 and myattr2 with the specified values. <br><br>
+
+The XPath query of the set-attribute command must return the following set: ( Element )*.
+If any of the results of the XPath query is not an Element, an UpdateException is thrown
+and the execution of the <xm:modifications/> block is halted.<br><br>
+
+<br><br>
+
+<h4>HTML Example:</h4>
+<br><br>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/jquery/jquery-latest.js"></script>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/xmodify/xmodify-jquery.js"></script>
+
+The buttons below can be used to clear and reset the values of the form inputs.
+<br><br>
+
+<div style="border:1px solid #aaa;margin:10px;padding:10px;" id="replace-contents">
+ <div><b>Please login!</b></div><br>
+ <div>
+ Username: <input id="username" type="text" value="janesmith"><br>
+ Password: <input id="password" type="password" value="wakeup"><br><br>
+ <input style="width:150px" type="button" value="Clear" onclick="$.xmodify({url:'../../../operations/clear-form.xml'});"/>
+ <input style="width:150px" type="button" value="Reset" onclick="$.xmodify({url:'../../../operations/reset-form.xml'});"/>
+ </div>
+</div>
+<br>
+<p><b>clear-form.xml</b></p>
+<p>This file uses the set-attribute xModify instruction to change the text of the input.
+The select attribute of the replace tag denotes the location of the element to change.
+</p>
+<pre>
+<xal xmlns:xm="http://openxal.org/core/xmodify">
+ <xm:modifications document="html">
+ <xm:set-attribute select="#username">
+ <xm:attribute name="value" value=""/>
+ </xm:set-attribute>
+ <xm:set-attribute select="#password">
+ <xm:attribute name="value" value=""/>
+ </xm:set-attribute>
+ </xm:modifications>
+</xal>
+</pre>
+
+]]></xsd:documentation>
+ </xsd:annotation>
+ <xsd:sequence maxOccurs="unbounded" minOccurs="1">
+ <xsd:element name="attribute" type="attribute-element-type" ref="attribute-element-type.xml">
+ <xsd:document lang="en" from="attribute-element-type">
+The attribute directive element is only used as an argument to the set-attribute
+directive. The element contains two attributes:<br>
+<ul>
+<li> name - the name of the attribute to be set.
+<li> value - the value of the attribute to be set.
+</ul>
+
+<br><br>
+
+<h4>HTML Example:</h4>
+<br><br>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/jquery/jquery-latest.js"></script>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/xmodify/xmodify-jquery.js"></script>
+
+The buttons below can be used to clear and reset the values of the form inputs.
+<br><br>
+
+<div style="border:1px solid #aaa;margin:10px;padding:10px;" id="replace-contents">
+ <div><b>Please login!</b></div><br>
+ <div>
+ Username: <input id="username" type="text" value="janesmith"><br>
+ Password: <input id="password" type="password" value="wakeup"><br><br>
+ <input style="width:150px" type="button" value="Clear" onclick="$.xmodify({url:'../../../operations/clear-form.xml'});"/>
+ <input style="width:150px" type="button" value="Reset" onclick="$.xmodify({url:'../../../operations/reset-form.xml'});"/>
+ </div>
+</div>
+<br>
+<p><b>clear-form.xml</b></p>
+<p>This file uses the set-attribute xModify instruction to change the text of the input.
+The select attribute of the replace tag denotes the location of the element to change.
+</p>
+<pre>
+&lt;xal xmlns:xm="http://openxal.org/core/xmodify"&gt;
+ &lt;xm:modifications document="html"&gt;
+ &lt;xm:set-attribute select="#username"&gt;
+ &lt;xm:attribute name="value" value=""/&gt;
+ &lt;/xm:set-attribute&gt;
+ &lt;xm:set-attribute select="#password"&gt;
+ &lt;xm:attribute name="value" value=""/&gt;
+ &lt;/xm:set-attribute&gt;
+ &lt;/xm:modifications&gt;
+&lt;/xal&gt;
+</pre>
+
+</xsd:document>
+ <xsd:briefDocument lang="en" from="attribute-element-type">
+The attribute directive element is only used as an argument to the set-attribute
+directive.</xsd:briefDocument>
+ </xsd:element>
+ </xsd:sequence>
+ <xsd:extension base="base-directive-element-type" ref="base-directive-element-type.xml">
+ <attributes>
+ <attribute name="select" type="select-attribute-type" ref="select-attribute-type.xml">
+ <xsd:document lang="en">
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on. <p>
+Shown below is a valid xModify command set containing just 1 command: remove-element.<br><br>
+
+<pre>
+ &lt;xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="mydocument"&gt;
+ &lt;xm:remove-element select="/ui/rootPane/freePane[1]/button"/&gt;
+ &lt;/xm:modifications&gt;
+</pre>
+<br>
+The 'select' attribute of this command contains the following XPath query:
+"/ui/rootPane/freePane[1]/button". This query selects all buttons in the document "mydocument"
+that are children of the first child freePane of the rootPane element. All of these buttons
+are then removed from the document by the remove-element command.
+
+<br><br>
+When selecting elements in the HTML document be sure to capitalize the element names. This is
+a result of the way the are store in the browser. The following example will append a row to the table
+with an id of &quot;myTable&quot;. Notice on the XPath statement also contains the TBODY which is
+standard on all tables.
+<br>
+<pre>
+ &lt;xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="html"&gt;
+ &lt;xm:append select="TABLE[@id='myTable']/TBODY"&gt;
+ &lt;![CDATA[ &lt;tr&gt;&lt;td&gt;New Person&lt/td&gt;&lt;/tr&gt;
+ ]]&gt;
+ &lt;/xm:append&gt;<br>
+ &lt;/xm:modifications&gt;<br>
+</pre>
+
+</xsd:document>
+ <xsd:briefDocument lang="en">
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on.</xsd:briefDocument>
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on. <p>
+Shown below is a valid xModify command set containing just 1 command: remove-element.<br><br>
+
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="mydocument">
+ <xm:remove-element select="/ui/rootPane/freePane[1]/button"/>
+ </xm:modifications>
+</pre>
+<br>
+The 'select' attribute of this command contains the following XPath query:
+"/ui/rootPane/freePane[1]/button". This query selects all buttons in the document "mydocument"
+that are children of the first child freePane of the rootPane element. All of these buttons
+are then removed from the document by the remove-element command.
+
+<br><br>
+When selecting elements in the HTML document be sure to capitalize the element names. This is
+a result of the way the are store in the browser. The following example will append a row to the table
+with an id of "myTable". Notice on the XPath statement also contains the TBODY which is
+standard on all tables.
+<br>
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="html">
+ <xm:append select="TABLE[@id='myTable']/TBODY">
+ <![CDATA[ <tr><td>New Person</td></tr>
+ ]]>
+ </xm:append><br>
+ </xm:modifications><br>
+</pre>
+
+]]></xsd:documentation>
+ <xsd:appinfo>
+ <meta:property category="Basic" display-name="Select"/>
+ </xsd:appinfo>
+ </xsd:annotation>
+ </attribute>
+ </attributes>
+ </xsd:extension>
+</complexType>
Added: incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-innerhtml-element-type.xml
URL: http://svn.apache.org/viewvc/incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-innerhtml-element-type.xml?view=auto&rev=550329
==============================================================================
--- incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-innerhtml-element-type.xml (added)
+++ incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-innerhtml-element-type.xml Sun Jun 24 20:05:18 2007
@@ -0,0 +1,136 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<complexType targetNamespace="http://openxal.org/core/xmodify"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:event="http://www.w3.org/2001/XMLSchema"
+ xmlns:meta="http://www.w3.org/2001/XMLSchema" name="set-innerhtml-element-type">
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+<br>The set-innerhtml command takes the contents of the tag and uses it
+as the value of the htmlElement.innerHTML.
+<br><br>
+
+<h4>HTML Example:</h4>
+<br><br>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/jquery/jquery-latest.js"></script>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/xmodify/xmodify-jquery.js"></script>
+
+The buttons below can be used to clear and reset the values of the form inputs.
+<br><br>
+
+<div style="border:1px solid #aaa;margin:10px;padding:10px;" id="replace-contents">
+ <div><b>Will the Redsox win the World Series?</b></div>
+ <div>
+ <input type="radio" name="yes">Yes<br>
+ <input type="radio" name="no">No<br>
+ <input style="width:150px" type="button" value="Submit" onclick="$.xmodify({url:'../../../operations/set-innerhtml.xml'});"/>
+ </div>
+</div>
+<br>
+<p><b>set-innerhtml.xml</b></p>
+<p>This file uses the set-innerhtml xModify instruction to change the contents of the "replace-contents" div.
+</p>
+<pre>
+<xal xmlns:xm="http://openxal.org/core/xmodify">
+ <xm:modifications document="html">
+ <xm:set-innerhtml select="replace-contents"><![CDATA[
+ <div><b>Results of Poll.</b></div><br>
+ <div>
+ 100% Yes<br>
+ 0% No
+ </div>
+ </div>
+ ]]>
+ </xm:set-innerhtml>
+ </xm:modifications>
+</xal>
+</pre>
+
+
+]]></xsd:documentation>
+ </xsd:annotation>
+ <xsd:extension base="base-directive-element-type" ref="base-directive-element-type.xml">
+ <attributes>
+ <attribute name="select" type="select-attribute-type" ref="select-attribute-type.xml">
+ <xsd:document lang="en">
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on. <p>
+Shown below is a valid xModify command set containing just 1 command: remove-element.<br><br>
+
+<pre>
+ &lt;xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="mydocument"&gt;
+ &lt;xm:remove-element select="/ui/rootPane/freePane[1]/button"/&gt;
+ &lt;/xm:modifications&gt;
+</pre>
+<br>
+The 'select' attribute of this command contains the following XPath query:
+"/ui/rootPane/freePane[1]/button". This query selects all buttons in the document "mydocument"
+that are children of the first child freePane of the rootPane element. All of these buttons
+are then removed from the document by the remove-element command.
+
+<br><br>
+When selecting elements in the HTML document be sure to capitalize the element names. This is
+a result of the way the are store in the browser. The following example will append a row to the table
+with an id of &quot;myTable&quot;. Notice on the XPath statement also contains the TBODY which is
+standard on all tables.
+<br>
+<pre>
+ &lt;xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="html"&gt;
+ &lt;xm:append select="TABLE[@id='myTable']/TBODY"&gt;
+ &lt;![CDATA[ &lt;tr&gt;&lt;td&gt;New Person&lt/td&gt;&lt;/tr&gt;
+ ]]&gt;
+ &lt;/xm:append&gt;<br>
+ &lt;/xm:modifications&gt;<br>
+</pre>
+
+</xsd:document>
+ <xsd:briefDocument lang="en">
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on.</xsd:briefDocument>
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on. <p>
+Shown below is a valid xModify command set containing just 1 command: remove-element.<br><br>
+
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="mydocument">
+ <xm:remove-element select="/ui/rootPane/freePane[1]/button"/>
+ </xm:modifications>
+</pre>
+<br>
+The 'select' attribute of this command contains the following XPath query:
+"/ui/rootPane/freePane[1]/button". This query selects all buttons in the document "mydocument"
+that are children of the first child freePane of the rootPane element. All of these buttons
+are then removed from the document by the remove-element command.
+
+<br><br>
+When selecting elements in the HTML document be sure to capitalize the element names. This is
+a result of the way the are store in the browser. The following example will append a row to the table
+with an id of "myTable". Notice on the XPath statement also contains the TBODY which is
+standard on all tables.
+<br>
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="html">
+ <xm:append select="TABLE[@id='myTable']/TBODY">
+ <![CDATA[ <tr><td>New Person</td></tr>
+ ]]>
+ </xm:append><br>
+ </xm:modifications><br>
+</pre>
+
+]]></xsd:documentation>
+ <xsd:appinfo>
+ <meta:property category="Basic" display-name="Select"/>
+ </xsd:appinfo>
+ </xsd:annotation>
+ </attribute>
+ </attributes>
+ </xsd:extension>
+</complexType>
Added: incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-style-element-type.xml
URL: http://svn.apache.org/viewvc/incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-style-element-type.xml?view=auto&rev=550329
==============================================================================
--- incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-style-element-type.xml (added)
+++ incubator/xap/site/docs/xmodify/doc/complexTypes/xml/set-style-element-type.xml Sun Jun 24 20:05:18 2007
@@ -0,0 +1,182 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<complexType targetNamespace="http://openxal.org/core/xmodify"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:event="http://www.w3.org/2001/XMLSchema"
+ xmlns:meta="http://www.w3.org/2001/XMLSchema" name="set-style-element-type">
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+<br>The set-style command sets the specified attributes in all of the elements
+returned by the XPath query. All attributes to be set need to be specified as
+an style directive element (i.e. <xm:style name="background-color" value="red"/>)
+<br><br>
+
+<h4>HTML Example:</h4>
+<br><br>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/jquery/jquery-latest.js"></script>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/xmodify/xmodify-jquery.js"></script>
+
+The buttons below can be used to clear and reset the values of the form inputs.
+<br><br>
+
+<div style="border:1px solid #aaa;margin:10px;padding:10px;" id="replace-contents">
+ <div><b>Please login!</b></div><br>
+ <div>
+ Username: <input id="username" type="text" value="janesmith"><br>
+ Password: <input id="password" type="password" value="wakeup"><br><br>
+ <input style="width:150px" type="button" value="Change Style" onclick="$.xmodify({url:'../../../operations/set-style.xml'});"/>
+ </div>
+</div>
+<br>
+<p><b>set-style.xml</b></p>
+<p>This file uses the set-style xModify instruction to change the background-color and border styles of the input.
+The select attribute of the set-style tag denotes the location of the element to change.
+</p>
+<pre>
+<xal xmlns:xm="http://openxal.org/core/xmodify">
+ <xm:modifications document="html">
+ <xm:set-style select="//INPUT">
+ <xm:style name="background-color" value="red"/>
+ <xm:style name="border" value="3px dashed #aaa"/>
+ </xm:set-style>
+ </xm:modifications>
+</xal>
+</pre>
+
+]]></xsd:documentation>
+ </xsd:annotation>
+ <xsd:sequence maxOccurs="unbounded" minOccurs="1">
+ <xsd:element name="style" type="style-element-type" ref="style-element-type.xml">
+ <xsd:document lang="en" from="style-element-type">
+The style directive element is only used as an argument to the set-style
+directive. The element contains two attributes:<br>
+<ul>
+<li> name - the name of the style to be set.
+<li> value - the value of the style to be set.
+</ul>
+
+<br><br>
+
+<h4>HTML Example:</h4>
+<br><br>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/jquery/jquery-latest.js"></script>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/xmodify/xmodify-jquery.js"></script>
+
+The buttons below can be used to clear and reset the values of the form inputs.
+<br><br>
+
+<div style="border:1px solid #aaa;margin:10px;padding:10px;" id="replace-contents">
+ <div><b>Please login!</b></div><br>
+ <div>
+ Username: <input id="username" type="text" value="janesmith"><br>
+ Password: <input id="password" type="password" value="wakeup"><br><br>
+ <input style="width:150px" type="button" value="Change Style" onclick="$.xmodify({url:'../../../operations/set-style.xml'});"/>
+ </div>
+</div>
+<br>
+<p><b>set-style.xml</b></p>
+<p>This file uses the set-style xModify instruction to change the background-color and border styles of the input.
+The select attribute of the set-style tag denotes the location of the element to change.
+</p>
+<pre>
+&lt;xal xmlns:xm="http://openxal.org/core/xmodify"&gt;
+ &lt;xm:modifications document="html"&gt;
+ &lt;xm:set-style select="//INPUT"&gt;
+ &lt;xm:style name="background-color" value="red"/&gt;
+ &lt;xm:style name="border" value="3px dashed #aaa"/&gt;
+ &lt;/xm:set-style&gt;
+ &lt;/xm:modifications&gt;
+&lt;/xal&gt;
+</pre>
+
+</xsd:document>
+ <xsd:briefDocument lang="en" from="style-element-type">
+The style directive element is only used as an argument to the set-style
+directive.</xsd:briefDocument>
+ </xsd:element>
+ </xsd:sequence>
+ <xsd:extension base="base-directive-element-type" ref="base-directive-element-type.xml">
+ <attributes>
+ <attribute name="select" type="select-attribute-type" ref="select-attribute-type.xml">
+ <xsd:document lang="en">
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on. <p>
+Shown below is a valid xModify command set containing just 1 command: remove-element.<br><br>
+
+<pre>
+ &lt;xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="mydocument"&gt;
+ &lt;xm:remove-element select="/ui/rootPane/freePane[1]/button"/&gt;
+ &lt;/xm:modifications&gt;
+</pre>
+<br>
+The 'select' attribute of this command contains the following XPath query:
+"/ui/rootPane/freePane[1]/button". This query selects all buttons in the document "mydocument"
+that are children of the first child freePane of the rootPane element. All of these buttons
+are then removed from the document by the remove-element command.
+
+<br><br>
+When selecting elements in the HTML document be sure to capitalize the element names. This is
+a result of the way the are store in the browser. The following example will append a row to the table
+with an id of &quot;myTable&quot;. Notice on the XPath statement also contains the TBODY which is
+standard on all tables.
+<br>
+<pre>
+ &lt;xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="html"&gt;
+ &lt;xm:append select="TABLE[@id='myTable']/TBODY"&gt;
+ &lt;![CDATA[ &lt;tr&gt;&lt;td&gt;New Person&lt/td&gt;&lt;/tr&gt;
+ ]]&gt;
+ &lt;/xm:append&gt;<br>
+ &lt;/xm:modifications&gt;<br>
+</pre>
+
+</xsd:document>
+ <xsd:briefDocument lang="en">
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on.</xsd:briefDocument>
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on. <p>
+Shown below is a valid xModify command set containing just 1 command: remove-element.<br><br>
+
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="mydocument">
+ <xm:remove-element select="/ui/rootPane/freePane[1]/button"/>
+ </xm:modifications>
+</pre>
+<br>
+The 'select' attribute of this command contains the following XPath query:
+"/ui/rootPane/freePane[1]/button". This query selects all buttons in the document "mydocument"
+that are children of the first child freePane of the rootPane element. All of these buttons
+are then removed from the document by the remove-element command.
+
+<br><br>
+When selecting elements in the HTML document be sure to capitalize the element names. This is
+a result of the way the are store in the browser. The following example will append a row to the table
+with an id of "myTable". Notice on the XPath statement also contains the TBODY which is
+standard on all tables.
+<br>
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="html">
+ <xm:append select="TABLE[@id='myTable']/TBODY">
+ <![CDATA[ <tr><td>New Person</td></tr>
+ ]]>
+ </xm:append><br>
+ </xm:modifications><br>
+</pre>
+
+]]></xsd:documentation>
+ <xsd:appinfo>
+ <meta:property category="Basic" display-name="Select"/>
+ </xsd:appinfo>
+ </xsd:annotation>
+ </attribute>
+ </attributes>
+ </xsd:extension>
+</complexType>
Added: incubator/xap/site/docs/xmodify/doc/complexTypes/xml/style-element-type.xml
URL: http://svn.apache.org/viewvc/incubator/xap/site/docs/xmodify/doc/complexTypes/xml/style-element-type.xml?view=auto&rev=550329
==============================================================================
--- incubator/xap/site/docs/xmodify/doc/complexTypes/xml/style-element-type.xml (added)
+++ incubator/xap/site/docs/xmodify/doc/complexTypes/xml/style-element-type.xml Sun Jun 24 20:05:18 2007
@@ -0,0 +1,77 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<complexType targetNamespace="http://openxal.org/core/xmodify"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:event="http://www.w3.org/2001/XMLSchema"
+ xmlns:meta="http://www.w3.org/2001/XMLSchema" name="style-element-type">
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+The style directive element is only used as an argument to the set-style
+directive. The element contains two attributes:<br>
+<ul>
+<li> name - the name of the style to be set.
+<li> value - the value of the style to be set.
+</ul>
+
+<br><br>
+
+<h4>HTML Example:</h4>
+<br><br>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/jquery/jquery-latest.js"></script>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/xmodify/xmodify-jquery.js"></script>
+
+The buttons below can be used to clear and reset the values of the form inputs.
+<br><br>
+
+<div style="border:1px solid #aaa;margin:10px;padding:10px;" id="replace-contents">
+ <div><b>Please login!</b></div><br>
+ <div>
+ Username: <input id="username" type="text" value="janesmith"><br>
+ Password: <input id="password" type="password" value="wakeup"><br><br>
+ <input style="width:150px" type="button" value="Change Style" onclick="$.xmodify({url:'../../../operations/set-style.xml'});"/>
+ </div>
+</div>
+<br>
+<p><b>set-style.xml</b></p>
+<p>This file uses the set-style xModify instruction to change the background-color and border styles of the input.
+The select attribute of the set-style tag denotes the location of the element to change.
+</p>
+<pre>
+<xal xmlns:xm="http://openxal.org/core/xmodify">
+ <xm:modifications document="html">
+ <xm:set-style select="//INPUT">
+ <xm:style name="background-color" value="red"/>
+ <xm:style name="border" value="3px dashed #aaa"/>
+ </xm:set-style>
+ </xm:modifications>
+</xal>
+</pre>
+
+]]></xsd:documentation>
+ </xsd:annotation>
+ <attributes>
+ <attribute name="value" type="string">
+ <xsd:document lang="en">
+ Specifies the value of the attribute to be set.
+ </xsd:document>
+ <xsd:briefDocument lang="en">
+ Specifies the value of the attribute to be set.</xsd:briefDocument>
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+ Specifies the value of the attribute to be set.
+ ]]></xsd:documentation>
+ </xsd:annotation>
+ </attribute>
+ <attribute name="name" type="string">
+ <xsd:document lang="en">
+ Specifies the name of the attribute to be set.
+ </xsd:document>
+ <xsd:briefDocument lang="en">
+ Specifies the name of the attribute to be set.</xsd:briefDocument>
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+ Specifies the name of the attribute to be set.
+ ]]></xsd:documentation>
+ </xsd:annotation>
+ </attribute>
+ </attributes>
+</complexType>
Added: incubator/xap/site/docs/xmodify/doc/complexTypes/xml/value-of-element-type.xml
URL: http://svn.apache.org/viewvc/incubator/xap/site/docs/xmodify/doc/complexTypes/xml/value-of-element-type.xml?view=auto&rev=550329
==============================================================================
--- incubator/xap/site/docs/xmodify/doc/complexTypes/xml/value-of-element-type.xml (added)
+++ incubator/xap/site/docs/xmodify/doc/complexTypes/xml/value-of-element-type.xml Sun Jun 24 20:05:18 2007
@@ -0,0 +1,89 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<complexType targetNamespace="http://openxal.org/core/xmodify"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:event="http://www.w3.org/2001/XMLSchema"
+ xmlns:meta="http://www.w3.org/2001/XMLSchema" name="value-of-element-type">
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+The value-of command is used to extract the value of a bound variable.
+Usually the variable is bound by the "variable" command first. Then you can
+use the value-of command as an argument to other commands that take arguments.
+<br><br>
+
+The value of the 'name' attribute should be the name of a variable bound by
+the 'variable' directive.
+<br><br>
+
+Here is a sample use of a value-of command:<br><br>
+
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify" document="mydocument">
+ <xm:variable name="myvar" select="/ui/rootPane/freePane[1]" clone="true"/>
+ <xm:append select="/ui/rootPane">
+ <xm:value-of name="myvar"/>
+ </xm:append>
+ </xm:modifications>
+</pre>
+The above set of commands does the following:<br><br>
+<ul>
+<li>The first command (variable) binds a variable named "myvar" to a clone of the first
+child freePane of the rootPane element in document "mydocument".
+<li>The second command (append) appends the value of the variable "myvar" (the cloned freePane from step 1)
+to the same rootPane element (end result: the rootPane element now has another child freePane).
+</ul>
+
+<br><br>
+
+<h4>HTML Example:</h4>
+<br><br>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/jquery/jquery-latest.js"></script>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/xmodify/xmodify-jquery.js"></script>
+
+Change the value of the input field and click the clone button.
+<br><br>
+
+<div style="border:1px solid #aaa;margin:10px;padding:10px;" id="replace-contents">
+ <div><b>Please login!</b></div><br>
+ <div><input id="username" type="text" value="janesmith"></div><br>
+ <div id="inputContainer">
+ </div>
+ <input style="width:150px" type="button" value="Clone the Input" onclick="$.xmodify({url:'../../../operations/variable.xml'});"/>
+</div>
+<br>
+<p><b>variable.xml</b></p>
+<p>This file uses the variable xModify instruction create a copy of the input field. Then inside of the
+ append tag the value-of tag is used to refer to the variable tag.
+</p>
+<pre>
+<xal xmlns:xm="http://openxal.org/core/xmodify">
+ <xm:modifications document="html">
+ <xm:variable name="variableName" select="#username"/>
+ <xm:append select="#inputContainer">
+ <xm:value-of name="variableName"/>
+ </xm:append>
+ </xm:modifications>
+</xal>
+</pre>
+
+]]></xsd:documentation>
+ </xsd:annotation>
+ <attributes>
+ <attribute name="name" type="string">
+ <xsd:document lang="en">
+The name of the variable bound by the 'variable' directive contained in the same
+&lt;xm:modifications/&gt; block. The variable directive should be placed before
+a value-of directive that tries to use the variable value.
+</xsd:document>
+ <xsd:briefDocument lang="en">
+The name of the variable bound by the 'variable' directive contained in the same
+&lt;xm:modifications/&gt; block.</xsd:briefDocument>
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+The name of the variable bound by the 'variable' directive contained in the same
+<xm:modifications/> block. The variable directive should be placed before
+a value-of directive that tries to use the variable value.
+]]></xsd:documentation>
+ </xsd:annotation>
+ </attribute>
+ </attributes>
+</complexType>
Added: incubator/xap/site/docs/xmodify/doc/complexTypes/xml/variable-element-type.xml
URL: http://svn.apache.org/viewvc/incubator/xap/site/docs/xmodify/doc/complexTypes/xml/variable-element-type.xml?view=auto&rev=550329
==============================================================================
--- incubator/xap/site/docs/xmodify/doc/complexTypes/xml/variable-element-type.xml (added)
+++ incubator/xap/site/docs/xmodify/doc/complexTypes/xml/variable-element-type.xml Sun Jun 24 20:05:18 2007
@@ -0,0 +1,191 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<complexType targetNamespace="http://openxal.org/core/xmodify"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:event="http://www.w3.org/2001/XMLSchema"
+ xmlns:meta="http://www.w3.org/2001/XMLSchema" name="variable-element-type">
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+<br>The variable command binds an arbitrary variable name to some value (the
+result of the XPath query specified by the select attribute). A sample
+variable command element looks like this:<br><br>
+
+ <xm:variable name="myvar" select="/ui/rootPane/freePane[1]" clone="true"/><br><br>
+
+The variable command should be used together with other commands that can use the
+value of the bound variable. Otherwise it's not of much use. For example: <br><br>
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify" document="mydocument">
+ <xm:variable name="myvar" select="/ui/rootPane/freePane[1]" clone="true"/>
+ <xm:append select="/ui/rootPane">
+ <xm:value-of name="myvar"/>
+ </xm:append>
+ </xm:modifications>
+</pre>
+The above set of commands does the following:
+<ul>
+<li>The first command (variable) binds a variable named "myvar" to a clone of the first
+child freePane of the rootPane element.
+<li>The second command (append) appends the value of the variable "myvar" (the cloned freePane from the first command)
+to the rootPane element of the same document.
+</ul><br>
+Variables bound by the variable command are only visible to other commands enclosed
+by the same <xm:modifications/> element. They also have to appear before the
+commands that need to use the bound variables (since the commands are
+executed in order).
+
+
+<br><br>
+
+<h4>HTML Example:</h4>
+<br><br>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/jquery/jquery-latest.js"></script>
+<script language="JavaScript" type="text/javascript" src="../../../../../javascript/xmodify/xmodify-jquery.js"></script>
+
+Change the value of the input field and click the clone button.
+<br><br>
+
+<div style="border:1px solid #aaa;margin:10px;padding:10px;" id="replace-contents">
+ <div><b>Please login!</b></div><br>
+ <div><input id="username" type="text" value="janesmith"></div><br>
+ <div id="inputContainer">
+ </div>
+ <input style="width:150px" type="button" value="Clone the Input" onclick="$.xmodify({url:'../../../operations/variable.xml'});"/>
+</div>
+<br>
+<p><b>variable.xml</b></p>
+<p>This file uses the variable xModify instruction create a copy of the input field. Then inside of the
+ append tag the value-of tag is used to refer to the variable tag.
+</p>
+<pre>
+<xal xmlns:xm="http://openxal.org/core/xmodify">
+ <xm:modifications document="html">
+ <xm:variable name="variableName" select="#username"/>
+ <xm:append select="#inputContainer">
+ <xm:value-of name="variableName"/>
+ </xm:append>
+ </xm:modifications>
+</xal>
+</pre>
+
+
+]]></xsd:documentation>
+ </xsd:annotation>
+ <xsd:extension base="base-directive-element-type" ref="base-directive-element-type.xml">
+ <attributes>
+ <attribute name="clone" type="boolean">
+ <xsd:document lang="en">
+Whether or not the result of the XPath query should be cloned before binding it
+to the variable.
+</xsd:document>
+ <xsd:briefDocument lang="en">
+Whether or not the result of the XPath query should be cloned before binding it
+to the variable.</xsd:briefDocument>
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+Whether or not the result of the XPath query should be cloned before binding it
+to the variable.
+]]></xsd:documentation>
+ <xsd:appinfo>
+ <meta:property category="Basic" display-name="Clone"/>
+ </xsd:appinfo>
+ </xsd:annotation>
+ </attribute>
+ <attribute name="name" type="string">
+ <xsd:document lang="en">
+The name of the variable.
+ </xsd:document>
+ <xsd:briefDocument lang="en">
+The name of the variable.</xsd:briefDocument>
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+The name of the variable.
+ ]]></xsd:documentation>
+ <xsd:appinfo>
+ <meta:property category="Basic" display-name="Name"/>
+ </xsd:appinfo>
+ </xsd:annotation>
+ </attribute>
+ <attribute name="select" type="select-attribute-type" ref="select-attribute-type.xml">
+ <xsd:document lang="en">
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on. <p>
+Shown below is a valid xModify command set containing just 1 command: remove-element.<br><br>
+
+<pre>
+ &lt;xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="mydocument"&gt;
+ &lt;xm:remove-element select="/ui/rootPane/freePane[1]/button"/&gt;
+ &lt;/xm:modifications&gt;
+</pre>
+<br>
+The 'select' attribute of this command contains the following XPath query:
+"/ui/rootPane/freePane[1]/button". This query selects all buttons in the document "mydocument"
+that are children of the first child freePane of the rootPane element. All of these buttons
+are then removed from the document by the remove-element command.
+
+<br><br>
+When selecting elements in the HTML document be sure to capitalize the element names. This is
+a result of the way the are store in the browser. The following example will append a row to the table
+with an id of &quot;myTable&quot;. Notice on the XPath statement also contains the TBODY which is
+standard on all tables.
+<br>
+<pre>
+ &lt;xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="html"&gt;
+ &lt;xm:append select="TABLE[@id='myTable']/TBODY"&gt;
+ &lt;![CDATA[ &lt;tr&gt;&lt;td&gt;New Person&lt/td&gt;&lt;/tr&gt;
+ ]]&gt;
+ &lt;/xm:append&gt;<br>
+ &lt;/xm:modifications&gt;<br>
+</pre>
+
+</xsd:document>
+ <xsd:briefDocument lang="en">
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on.</xsd:briefDocument>
+ <xsd:annotation>
+ <xsd:documentation xml:lang="en"><![CDATA[
+The value of this attribute is any valid XPath query which returns a result
+set (usually a set of elements or attributes) on which the enclosing xModify
+command then operates on. <p>
+Shown below is a valid xModify command set containing just 1 command: remove-element.<br><br>
+
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="mydocument">
+ <xm:remove-element select="/ui/rootPane/freePane[1]/button"/>
+ </xm:modifications>
+</pre>
+<br>
+The 'select' attribute of this command contains the following XPath query:
+"/ui/rootPane/freePane[1]/button". This query selects all buttons in the document "mydocument"
+that are children of the first child freePane of the rootPane element. All of these buttons
+are then removed from the document by the remove-element command.
+
+<br><br>
+When selecting elements in the HTML document be sure to capitalize the element names. This is
+a result of the way the are store in the browser. The following example will append a row to the table
+with an id of "myTable". Notice on the XPath statement also contains the TBODY which is
+standard on all tables.
+<br>
+<pre>
+ <xm:modifications version="1.0" xmlns:xm="http://openxal.org/core/xmodify"
+ document="html">
+ <xm:append select="TABLE[@id='myTable']/TBODY">
+ <![CDATA[ <tr><td>New Person</td></tr>
+ ]]>
+ </xm:append><br>
+ </xm:modifications><br>
+</pre>
+
+]]></xsd:documentation>
+ <xsd:appinfo>
+ <meta:property category="Basic" display-name="Select"/>
+ </xsd:appinfo>
+ </xsd:annotation>
+ </attribute>
+ </attributes>
+ </xsd:extension>
+</complexType>
Added: incubator/xap/site/docs/xmodify/doc/overview/html/overview.html
URL: http://svn.apache.org/viewvc/incubator/xap/site/docs/xmodify/doc/overview/html/overview.html?view=auto&rev=550329
==============================================================================
--- incubator/xap/site/docs/xmodify/doc/overview/html/overview.html (added)
+++ incubator/xap/site/docs/xmodify/doc/overview/html/overview.html Sun Jun 24 20:05:18 2007
@@ -0,0 +1,74 @@
+<html xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:event="http://openxal.org/ui/java/event">
+<head>
+<link rel="stylesheet" type="text/css" href="../../../css/stylesheet.css"/>
+</head>
+<body>
+<script src="../../../js/myJS.js" language="javascript" type="text/javascript"> </script>
+<div style="display:block;" class="leftLabel" onclick="JavaScript:openSubCat('insideSubCategory')">
+<font class="FrameTitleFont">
+<b>Complex Types</b>
+</font>
+<br/>
+</div>
+<div id="insideSubCategory" class="leftDetail" style="display:none;">
+<br/>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/append-element-type.html" target="mainframe">append</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/attribute-element-type.html" target="mainframe">attribute</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/clone-element-type.html" target="mainframe">clone</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/create-document-element-type.html" target="mainframe">create-document</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/embed-xal-element-type.html" target="mainframe">embed-xal</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/insert-after-element-type.html" target="mainframe">insert-after</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/insert-at-element-type.html" target="mainframe">insert-at</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/insert-before-element-type.html" target="mainframe">insert-before</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/modifications-element-type.html" target="mainframe">modifications</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/remove-attribute-element-type.html" target="mainframe">remove-attribute</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/remove-element-element-type.html" target="mainframe">remove</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/replace-children-element-type.html" target="mainframe">replace-children</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/replace-element-type.html" target="mainframe">replace</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/set-attribute-element-type.html" target="mainframe">set-attribute</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/set-innerhtml-element-type.html" target="mainframe">set-innerhtml</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/set-style-element-type.html" target="mainframe">set-style</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/style-element-type.html" target="mainframe">style</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/value-of-element-type.html" target="mainframe">value-of</a>
+</div>
+<div style="display:block; padding-left:3px; padding-bottom:3px;">
+<a href="../../complexTypes/html/variable-element-type.html" target="mainframe">variable</a>
+</div>
+</div>
+</body>
+</html>