toBytes static method
Decodes v as hex if it looks like a hex string, otherwise UTF-8 encodes it.
Implementation
static BuBytes toBytes(String v) {
if (isHexBytes(v)) {
return BytesUtils.fromHexString(v);
} else {
return encode(v);
}
}