Primitive Types
blob
-
< blob > toString ( string encoding ) ( string )
Converts blob to a string
Parameter Name Data Type Description encoding string Encoding to used in blob conversion to string Return Variable Data Type Description string
datatable
-
< datatable > close ( )
Releases the database connection.
-
< datatable > getNext ( ) ( any )
Retrives the current row and return a struct with the data in the columns
Return Variable Data Type Description any -
< datatable > hasNext ( ) ( boolean )
Checks for a new row in the given datatable. If a new row is found, moves the cursor to it.
Return Variable Data Type Description boolean
json
-
< json > getKeys ( ) ( string[] )
Returns an array of keys contained in the specified JSON.
Return Variable Data Type Description string[] -
< json > remove ( string key )
Removes each element that matches the given key.
Parameter Name Data Type Description key string Key of the field to remove -
< json > toString ( ) ( string )
Converts a JSON object to a string representation
Return Variable Data Type Description string -
< json > toXML ( jsonOptions options ) ( xml , TypeConversionError )
Converts a JSON object to a XML representation
Parameter Name Data Type Description options jsonOptions jsonOptions struct for JSON to XML conversion properties Return Variable Data Type Description xml TypeConversionError
string
-
< string > contains ( string subString ) ( boolean )
Returns a Boolean value indicating whether a string contains the specified substring
Parameter Name Data Type Description subString string The substring to be compared Return Variable Data Type Description boolean -
< string > equalsIgnoreCase ( string anotherString ) ( boolean )
Compares two strings, ignoring the case of the strings
Parameter Name Data Type Description anotherString string The string to be compared Return Variable Data Type Description boolean -
< string > findAllWithRegex ( Regex reg ) ( string[] , error )
Finds all the strings matching the regular expression
Parameter Name Data Type Description reg Regex Regular expression Return Variable Data Type Description string[] error -
< string > hasPrefix ( string prefix ) ( boolean )
Returns a Boolean value indicating whether a string starts with the specified prefix
Parameter Name Data Type Description prefix string The prefix to be compared Return Variable Data Type Description boolean -
< string > hasSuffix ( string suffix ) ( boolean )
Returns a Boolean value indicating whether the string ends with specified suffix
Parameter Name Data Type Description suffix string The suffix to be compared Return Variable Data Type Description boolean -
< string > indexOf ( string subString ) ( int )
Returns the first index of the first occurence of the substring within the specified string
Parameter Name Data Type Description subString string The substring to search for Return Variable Data Type Description int -
< string > lastIndexOf ( string subString ) ( int )
Returns the first index of the last occurence of the substring within the specified string
Parameter Name Data Type Description subString string The substring to search for Return Variable Data Type Description int -
< string > length ( ) ( int )
Returns the length of the specified string
Return Variable Data Type Description int -
< string > matchesWithRegex ( Regex reg ) ( boolean , error )
Returns a Boolean value indicating whether the string matches the regular expression
Parameter Name Data Type Description reg Regex Regular expression Return Variable Data Type Description boolean error -
< string > replace ( string replacePattern , string replaceWith ) ( string )
Replaces all instances of the replacePattern string with the replaceWith string and returns the result
Parameter Name Data Type Description replacePattern string The pattern to search for replaceWith string The replacement string Return Variable Data Type Description string -
< string > replaceAll ( string replacePattern , string replaceWith ) ( string )
Replaces each substring of the mainString that matches the given regular expression with the given replacement
Parameter Name Data Type Description replacePattern string The regular expression to search for replaceWith string The replacement string Return Variable Data Type Description string -
< string > replaceAllWithRegex ( Regex reg , string replaceWith ) ( string , error )
Replaces the mainString with the replacement of occurrences that matches the given regular expression
Parameter Name Data Type Description reg Regex Regular expression replaceWith string The replacement string Return Variable Data Type Description string error -
< string > replaceFirst ( string replacePattern , string replaceWith ) ( string )
Replaces the first instance of the replacePattern with the replaceWith string and returns the result
Parameter Name Data Type Description replacePattern string The pattern to search for replaceWith string The replacement string Return Variable Data Type Description string -
< string > replaceFirstWithRegex ( Regex reg , string replaceWith ) ( string , error )
Replaces the first instance of the regular expression matching area with the replaceWith string and returns the result
Parameter Name Data Type Description reg Regex Regular expression replaceWith string The replacement string Return Variable Data Type Description string error -
< string > split ( string regex ) ( string[] )
Splits the string with the given regular expression to produce a string array.
Parameter Name Data Type Description regex string The regex to split the string Return Variable Data Type Description string[] -
< string > subString ( int from , int to ) ( string )
Returns a new string that is the substring of the specified string
Parameter Name Data Type Description from int The starting index to int The ending index Return Variable Data Type Description string -
< string > toBlob ( string encoding ) ( blob )
Converts string to a blob
Parameter Name Data Type Description encoding string Encoding to used in the conversion Return Variable Data Type Description blob -
< string > toLowerCase ( ) ( string )
Returns a string with all the characters converted to lowercase
Return Variable Data Type Description string -
< string > toUpperCase ( ) ( string )
Returns a string with all the characters converted to uppercase
Return Variable Data Type Description string -
< string > trim ( ) ( string )
Returns a trimmed string by omitting the leading and trailing whitespaces of the original string
Return Variable Data Type Description string -
< string > unescape ( ) ( string )
Returns an unescaped string by omitting the escape characters of the original string
Return Variable Data Type Description string
map
-
< map > clear ( )
Clear the items from given map
-
< map > hasKey ( string key ) ( boolean )
Check whether specific key exists from the given map
Parameter Name Data Type Description key string The key to be find existence Return Variable Data Type Description boolean -
< map > keys ( ) ( string[] )
Returns an array of keys contained in the specified map
Return Variable Data Type Description string[] -
< map > remove ( string key )
Removes the specified element from the map
Parameter Name Data Type Description key string The key to be removed -
< map > values ( ) ( any[] )
Returns an array of values contained in the specified map
Return Variable Data Type Description any[]
xml
-
< xml > children ( ) ( xml )
Selects all the children of the elements in an XML, and return as a sequence.
Return Variable Data Type Description xml -
< xml > copy ( ) ( xml )
Make a deep copy of an XML.
Return Variable Data Type Description xml -
< xml > elements ( ) ( xml )
Get all the items that are of element type in an XML sequence.
Return Variable Data Type Description xml -
< xml > getElementName ( ) ( string )
Get the fully qualified name of the element as a string. Returns an empty string if the XML is not a singleton.
Return Variable Data Type Description string -
< xml > getItemType ( ) ( string )
Get the type of a XML as a string. If the XML is singleton, type can be one of 'element', 'text', 'comment' or 'pi'. Returns an empty string if the XML is not a singleton.
Return Variable Data Type Description string -
< xml > getTextValue ( ) ( string )
Get the text value of a XML. If the XML is a sequence, concatenation of the text values of the members of the sequence is returned. If the XML is an element, then the text value of the sequence of children is returned. If the XML is a text item, then the text is returned. Otherwise, an empty string is returned.
Return Variable Data Type Description string -
< xml > isEmpty ( ) ( boolean )
Check whether the XML sequence is empty.
Return Variable Data Type Description boolean -
< xml > isSingleton ( ) ( boolean )
Check whether the XML sequence contains only a single element.
Return Variable Data Type Description boolean -
< xml > removeAttribute ( string qname )
Remove an attribute from an XML.
Parameter Name Data Type Description qname string Qualified name of the attribute -
< xml > select ( string qname ) ( xml )
Get all the items that are of element type, and matches the given qualified name, in an XML sequence.
Parameter Name Data Type Description qname string Qualified name of the element Return Variable Data Type Description xml -
< xml > selectChildren ( string qname ) ( xml )
Selects all the children of the elements in this sequence that matches the given qualified name.
Parameter Name Data Type Description qname string Qualified name of the element Return Variable Data Type Description xml -
< xml > selectDescendants ( string qname ) ( xml )
Searches in children recursively for elements matching the qualified name and returns a sequence containing them all. Does not search within a matched result.
Parameter Name Data Type Description qname string Qualified name of the element Return Variable Data Type Description xml -
< xml > setAttributes ( map attributes )
Sets the attributes to the provided attributes map.
Parameter Name Data Type Description attributes map Attributes map -
< xml > setChildren ( xml children )
Set the children of an XML if its a singleton. An Error otherwise. Any existing children will be removed.
Parameter Name Data Type Description children xml -
< xml > slice ( int startIndex , int endIndex ) ( xml )
Slice and return a subsequence of the an XML sequence.
Parameter Name Data Type Description startIndex int Start index, inclusive endIndex int End index, exclusive Return Variable Data Type Description xml -
< xml > strip ( ) ( xml )
Strips any text items from an XML sequence that are all whitespace.
Return Variable Data Type Description xml -
< xml > toJSON ( xmlOptions options ) ( json )
Converts a XML object to a JSON representation
Parameter Name Data Type Description options xmlOptions xmlOptions struct for XML to JSON conversion properties Return Variable Data Type Description json