Wiki source for FunctionsXS

Show raw source

======XS Functions======

The following functions are built in to xmlsh, but need to be [[CommandImport imported]]. They are not imported by default because of possible name collisions using these functions with no prefix. The intent of these functions is to provide convenient and efficient access to core "XDM" data types without having to use the [[XMLExpressions XML Expression Syntax]].

To use the XS commands you need to [[CommandImport import]] them into either the global namespace or a local namespace.
Its recommended that you use a local namespace so that there is less chance of name collisions.

To import into the xs namespace prefix
import commands xs=xs

To import into the global namespace
import commands xs

Functions are invoked using the [[SyntaxFunctionCall Function Call Syntax]]

||[[FunctionXSdecimal decimal]]||Casts argument as an xs:decimal||
||[[FunctionXSinteger integer]]||Casts argument as an xs:integer||
||[[FunctionXSstring string]]||Casts argument(s) as an xs:string||
||[[FunctionXSattribute attribute]]||Create an attribute node||
||[[FunctionXSelement element]]||Create an element node||
||[[FunctionXSdocument document]]||Create a document node||

See Also [[Functions]]
See Also [[FunctionsStAX StAX Functions]]
See Also [[Commands]]
See Also [[JavaObjects Java Objects]]
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki