Revision [245]
This is an old revision of Variables made by DavidLee on 2008-07-04 11:25:27.
Variables
xmlsh variables can be either strings or XML types (infoset, including sequences).There is no limit to the size of variables besides JVM memory.
Variables are created using variable assignment (CommandAssignVariable). The type of the expression determins
if a variable is a string or XML variable. Variables can be re-assigned and this can change their type.
Example of string assignments
A=string A="string" A='string' B="another $A" C=${B} D=$(echo yet more strings) E=$(ls)
Example of XML assignments
A=<[<foo/>]> A=<[1,2,3,<foo>bar</foo>]> A=$<(xls) DOC=<[<foo><bar>text</bar></foo>]> T=<[<spam>{$DOC//bar}</spam>]>
See Also BasicSyntax