Returns a defined byte to an array byte.
1 byte.getByteAt
<byte.getByteAt>
<data /> !
<position /> !
</byte.getByteAt>
Arguments | |||||
---|---|---|---|---|---|
Name | Type | Required | Unique | Nullable | Description |
Edata | byte[] | String of bytes. | |||
Eposition | integer | Position, first character position. |
Returns | |
---|---|
Type | Description |
Byte | Returns the required character, in integer format. If the received value is null, immediately it will return null as result. |
Exceptions
requires 2 values, received [...]
It has been specified an incorrect number of values.
Remarks
It is accepted as value any type of convertible data to an array byte: a string, an array of bytes, a node (of a XML or HTML file), a BLOB (Binary Large Object) or a file.
Example
Gets the character 1 of a string.
Copy
<xsql-script name='byte_char_sample1'> <body> <println> <byte.getByteAt> <string>hello world</string> <number>1</number> </byte.getByteAt> </println> </body> </xsql-script>
The showed result should be:
Copy
101