Module subxt_core::utils
source · Expand description
Miscellaneous utility helpers.
Modules§
- Generic
scale_bits
overbitvec
-likeBitOrder
andBitFormat
types.
Structs§
- A 32-byte cryptographic identifier. This is a simplified version of Substrate’s
sp_core::crypto::AccountId32
. To obtain more functionality, convert this into that type. - Wraps an already encoded byte vector, prevents being encoded as a raw byte vector as part of the transaction payload
- Fixed-size uninterpreted hash type with 20 bytes (160 bits) size.
- Fixed-size uninterpreted hash type with 32 bytes (256 bits) size.
- Fixed-size uninterpreted hash type with 64 bytes (512 bits) size.
- If the type inside this implements
Encode
, this will implementscale_encode::EncodeAsType
. If the type inside this implementsDecode
, this will implementscale_decode::DecodeAsType
. - The unchecked extrinsic from substrate.
- A wrapper for any type
T
which implement encode/decode in a way compatible withVec<u8>
.WrapperKeepOpaque
stores the type only in its opaque format, aka as aVec<u8>
. To access the real typeT
Self::try_decode
needs to be used. - A unit marker struct.
Enums§
- An era to describe the longevity of a transaction.
- A multi-format address wrapper for on-chain accounts. This is a simplified version of Substrate’s
sp_runtime::MultiAddress
. To obtain more functionality, convert this into that type (this conversion functionality is provided viaFrom
impls if thesubstrate-compat
feature is enabled). - Signature container that can store known signature types. This is a simplified version of
sp_runtime::MultiSignature
. To obtain more functionality, convert this into that type.
Functions§
- Decodes a compact encoded value from the beginning of the provided bytes, returning the value and any remaining bytes.
- A quick helper to encode some bytes to hex.
Type Aliases§
- This represents a key-value collection and is SCALE compatible with collections like BTreeMap. This has the same type params as
BTreeMap
which allows us to easily swap the two during codegen.