Expand description
§tiders-cast
Type casting and encoding/decoding utilities for Arrow columns and schemas.
Provides batch-level and column-level operations for:
- Type casting: Convert columns between Arrow data types by name or by source type.
- Hex encoding/decoding: Binary columns to/from hex strings (with optional
0xprefix). - Base58 encoding/decoding: Binary columns to/from Base58 strings (Bitcoin alphabet).
- U256 conversion: Between
Decimal256(76,0)and big-endian binary representations.
Functions§
- base58_
decode_ column - Decodes a Base58-encoded string column to binary.
- base58_
encode - Encodes all Binary and LargeBinary columns in the batch to Base58 (Bitcoin alphabet) strings.
- base58_
encode_ column - Encodes a single binary column to Base58 strings.
- cast
- Casts columns according to given (column name, target data type) pairs.
- cast_
by_ type - Casts all columns with from_type to to_type.
- cast_
schema - Casts column types according to given (column name, target data type) pairs.
- cast_
schema_ by_ type - Casts columns with from_type to to_type
- hex_
decode_ column - Decodes a hex-encoded string column to binary.
- hex_
encode - Encodes all Binary and LargeBinary columns in the batch to hex strings.
- hex_
encode_ column - Encodes a single binary column to hex strings.
- schema_
binary_ to_ string - Converts binary fields to string in the schema
- schema_
decimal256_ to_ binary - Converts decimal256 fields to binary in the schema
- u256_
column_ from_ binary - Converts a big-endian binary column (up to 32 bytes) to Decimal256(76,0).
- u256_
column_ to_ binary - Converts a Decimal256(76,0) column to trimmed big-endian binary.
- u256_
to_ binary - Converts all Decimal256 (U256) columns in the batch to big endian binary values