string-to-codepoints function
The fn:string-to-codepoints function returns a sequence of Unicode code points that corresponds to a string value.
Syntax
- source-string
- A string value for which the Unicode code point for each character is to be returned, or the empty sequence.
Returned value
If source-string is not the empty sequence and does not have length 0, the returned value is a sequence of xs:integer values that represent the code points for the characters in source-string.
If source-string is the empty sequence or has length 0, the returned value is the empty sequence.
Example
The following function returns a
sequence of code points that represent the characters in the string
'XQuery'.
fn:string-to-codepoints("XQuery")
The returned value is (88,81,117,101,114,121).