public class HexStringByteTranslator extends ByteTranslator
In the adapter configuration file this class is aliased as hex-string-byte-translator which is the preferred alternative to the fully qualified classname when building your configuration.
Constructor and Description |
---|
HexStringByteTranslator() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
translate(byte[] bytes)
Translate a byte array into a String.
|
byte[] |
translate(java.lang.String s)
Translate a string into a byte array.
|
public byte[] translate(java.lang.String s) throws java.io.IOException
ByteTranslator
translate
in class ByteTranslator
s
- the string.java.io.IOException
- wrapping any underlying exceptionpublic java.lang.String translate(byte[] bytes) throws java.io.IOException
ByteTranslator
translate
in class ByteTranslator
bytes
- the byte array.java.io.IOException
- wrapping any underlying exception