pub enum CLType {
Show 23 variants
Bool,
I32,
I64,
U8,
U32,
U64,
U128,
U256,
U512,
Unit,
String,
Key,
URef,
PublicKey,
Option(Box<CLType>),
List(Box<CLType>),
ByteArray(u32),
Result {
ok: Box<CLType>,
err: Box<CLType>,
},
Map {
key: Box<CLType>,
value: Box<CLType>,
},
Tuple1([Box<CLType>; 1]),
Tuple2([Box<CLType>; 2]),
Tuple3([Box<CLType>; 3]),
Any,
}Expand description
Casper types, i.e. types which can be stored and manipulated by smart contracts.
Provides a description of the underlying data type of a CLValue.
Variants§
Bool
bool primitive.
I32
i32 primitive.
I64
i64 primitive.
U8
u8 primitive.
U32
u32 primitive.
U64
u64 primitive.
U128
U128 large unsigned integer type.
U256
U256 large unsigned integer type.
U512
U512 large unsigned integer type.
Unit
() primitive.
String
String primitive.
Key
Key system type.
URef
URef system type.
PublicKey
PublicKey system type.
Option(Box<CLType>)
Option of a CLType.
List(Box<CLType>)
Variable-length list of a single CLType (comparable to a Vec).
ByteArray(u32)
Fixed-length list of a single CLType (comparable to a Rust array).
Result
Result with Ok and Err variants of CLTypes.
Map
Map with keys of a single CLType and values of a single CLType.
Tuple1([Box<CLType>; 1])
1-ary tuple of a CLType.
Tuple2([Box<CLType>; 2])
2-ary tuple of CLTypes.
Tuple3([Box<CLType>; 3])
3-ary tuple of CLTypes.
Any
Unspecified type.