decode_octet_string
The
decode_octet_string
operation decodes a STRING or a BLOB
field into other values based upon different encoding schemes.
The entire name of the input field is used as the
<prefix>
and must be a
STRING or a BLOB. If an output field is not defined in the MDC, the associated
conversion is skipped. If an input value cannot be converted, the associated output
field is not set. decode_octet_string Decoded Output Fields lists the decoded output fields. Field | Description |
---|---|
<prefix>FromAscii
|
Must be an INT64. This is the input field decoded as an ASCII decimal value. For example, "1234" would be decoded as 1234. |
<prefix>FromBcd
|
Must be a UINT64. This is the input field decoded as an encoded binary coded decimal value. For example, 0x1234 would be decoded as 1234. |
<prefix>FromHex
|
Must be a UINT64. This is the input field decoded as an encoded hexadecimal value. For example, 0x04D2 would be decoded as 1234. |
<prefix>FromTbcd
|
Must be a STRING. This is the input field decoded as a Telephone Binary Coded Decimal value. For example, 0x1234 would be decoded as 1234. |
<prefix>AsString
|
Must be a STRING. This is the input field decoded as a null-terminated string. |
<prefix>FromHexAscii
|
Must be an INT64. This treats the input field as an encoded ASCII hexadecimal value. For example, "04D2" would be decoded as 1234. |
For example, if the input field is a BLOB
ServiceParameterValue
, the following output is
generated.
1 ServiceParameterValue BLOB 0 0 0 1 36 0 (size=4, data=7308)
2 ServiceParameterValueFromAscii INT64 0 0 0 1 4 8 7308
3 ServiceParameterValueFromBcd UINT64 0 0 0 1 12 8 37333038
4 ServiceParameterValueFromHex UINT64 0 0 0 1 20 8 926101560
5 ServiceParameterValueFromTbcd STRING 0 0 0 1 49 0 (size=9, data=73330383)
6 ServiceParameterValueAsString STRING 0 0 0 1 42 0 (size=5, data=7308)
7 ServiceParameterValueFromHexAscii INT64 0 0 0 1 28 8 29448