StringFunctions class





context Contexts
read / write, inherited
currentFileInfo FileInfo
read / write, inherited
hashCode → int
The hash code for this object.
read-only, inherited
index ↔ int
read / write, inherited
less TreeApi
read / write, inherited
name ↔ String
read / write, inherited
registry ↔ Map<String, FunctionRegistryItem>
Method registry: { 'externalName': {'name': internalName, 'listArguments': false} }
read / write, inherited
runtimeType → Type
A representation of the runtime type of the object.
read-only, inherited


e(Node str) Anonymous
CSS escaping, replaced with ~"value" syntax. It expects string as a parameter and return its content as is, but without quotes. Parameters: string - a string to escape. Returns: string - the escaped string, without quotes. Example: filter: e("ms:alwaysHasItsOwnSyntax.For.Stuff()"); Output: filter: ms:alwaysHasItsOwnSyntax.For.Stuff(); Note: The function accepts also ~"" escaped values and numbers as parameters. Anything else returns an error.
escape(Node str) Anonymous
Applies URL-encoding to special characters found in the input string. These characters are not encoded: ,, /, ?, @, &, +, ', ~, ! and $. Most common encoded characters are: , #, ^, (, ), {, }, |, :, >, <, ;, ], [ and =. [...]
format(List<Node> args) Quoted
% format The function %(string, arguments ...) formats a string. [...]
@DefineMethod(name: '%', listArguments: true)
replace(Node string, Quoted pattern, Node replacement, [ Node flags ]) Quoted
Replaces a text within a string. Parameters: string: The string to search and replace in. pattern: A string or regular expression pattern to search for. replacement: The string to replace the matched pattern with. flags: (Optional) regular expression flags. Returns: a string with the replaced values. Example: replace("Hello, Mars?", "Mars?", "Earth!"); replace("One + one = 4", "one", "2", "gi"); replace('This is a string.', "(string).$", "new $1."); replace(~"bar-1", '1', '2'); Result: "Hello, Earth!"; "2 + 2 = 4"; 'This is a new string.'; bar-2;
call(List<Node> args) → dynamic
Call the last valid name of method
init(Contexts context, int index, FileInfo currentFileInfo) → void
Config functions with the necessarry information for processing
isValid(String name) → bool
Check if name is a method name available
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
toString() → String
Returns a string representation of this object.


operator ==(dynamic other) → bool
The equality operator.