wotsAddressFromHex static method
Creates a WotsAddress instance from a hexadecimal string. @param wotsHex The hexadecimal string representation of the address. @returns A new WotsAddress instance. Returns a default instance if length is invalid.
Implementation
static WotsAddress wotsAddressFromHex(String wotsHex) {
final bytes = ByteUtils.hexToBytes(wotsHex);
if (bytes.length != TXADDRLEN) {
return WotsAddress(); // Return a default instance if length is not TXADDRLEN
}
return wotsAddressFromBytes(bytes);
}