Module utils

Module utils 

Source

Functionsยง

bytes_to_hex_string
Convert a byte array into a hex string
felt_to_bytes32
Convert a FieldElement into a FixedBytes<32>
fixed_bytes_str_to_utf8_str
Convert a FixedBytes<32> which originally encoded from utf8 string into original utf8 string value
hex_string_to_bytes
Convert a hex string into a byte array
hex_string_to_uint
Convert a hex string into integer
last_byte_to_u8
Get the last byte of a byte array as a u8
tx_index_to_tx_key
Convert a transaction index to a transaction key
utf8_str_to_fixed_bytes32
Convert a utf8 string into FixedBytes<32> by padding zero bytes to the end