UInt
Composite 318 v393substrate_typenum::uint::UInt
About This Type
Structured type: UInt.
A struct-like type where each field is encoded in declaration order.
Encoding: Fields encoded consecutively in declaration order, no field names or separators.
Fields (2)
SCALE Encoding
- Rule
- 2 fields encoded consecutively in declaration order. No field names or delimiters.
- Size
- sum of field sizes
Examples
Struct with 2 fields = msb: UInt, lsb: B0
0x<field0><field1>field 0 msb: UIntfield 1 lsb: B0Code Examples
import { TypeRegistry } from "@polkadot/types";
const registry = new TypeRegistry();
// Encode UInt
const value = registry.createType("UInt", {
msb: 0,
lsb: 0
});
console.log("Hex:", value.toHex());Type Parameters
U = UInt
B = B0
Referenced By (5)
Type Information
- Type ID
- 318
- Kind
- Composite
- Path
- substrate_typenum::uint::UInt
- Runtime
- v393