pub enum LiteralType {
Show 17 variants
Address,
Boolean,
Field,
Group,
I8,
I16,
I32,
I64,
I128,
U8,
U16,
U32,
U64,
U128,
Scalar,
Signature,
String,
}
Variants§
Address
The Aleo address type.
Boolean
The boolean type.
Field
The field type (base field).
Group
The group type (affine).
I8
The 8-bit signed integer type.
I16
The 16-bit signed integer type.
I32
The 32-bit signed integer type.
I64
The 64-bit signed integer type.
I128
The 128-bit signed integer type.
U8
The 8-bit unsigned integer type.
U16
The 16-bit unsigned integer type.
U32
The 32-bit unsigned integer type.
U64
The 64-bit unsigned integer type.
U128
The 128-bit unsigned integer type.
Scalar
The scalar type (scalar field).
Signature
The signature type.
String
The string type.
Implementations§
Trait Implementations§
source§impl Clone for LiteralType
impl Clone for LiteralType
source§fn clone(&self) -> LiteralType
fn clone(&self) -> LiteralType
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for LiteralType
impl Debug for LiteralType
source§impl<'de> Deserialize<'de> for LiteralType
impl<'de> Deserialize<'de> for LiteralType
source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserializes the literal type from a string or bytes.
source§impl Display for LiteralType
impl Display for LiteralType
source§impl<N: Network> From<LiteralType> for PlaintextType<N>
impl<N: Network> From<LiteralType> for PlaintextType<N>
source§fn from(literal: LiteralType) -> Self
fn from(literal: LiteralType) -> Self
Initializes a plaintext type from a literal type.
source§impl FromBytes for LiteralType
impl FromBytes for LiteralType
source§impl FromPrimitive for LiteralType
impl FromPrimitive for LiteralType
source§fn from_i64(n: i64) -> Option<Self>
fn from_i64(n: i64) -> Option<Self>
Converts an
i64
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned.source§fn from_u64(n: u64) -> Option<Self>
fn from_u64(n: u64) -> Option<Self>
Converts an
u64
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned.source§fn from_isize(n: isize) -> Option<Self>
fn from_isize(n: isize) -> Option<Self>
Converts an
isize
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned.source§fn from_i8(n: i8) -> Option<Self>
fn from_i8(n: i8) -> Option<Self>
Converts an
i8
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned.source§fn from_i16(n: i16) -> Option<Self>
fn from_i16(n: i16) -> Option<Self>
Converts an
i16
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned.source§fn from_i32(n: i32) -> Option<Self>
fn from_i32(n: i32) -> Option<Self>
Converts an
i32
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned.source§fn from_i128(n: i128) -> Option<Self>
fn from_i128(n: i128) -> Option<Self>
Converts an
i128
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_usize(n: usize) -> Option<Self>
fn from_usize(n: usize) -> Option<Self>
Converts a
usize
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned.source§fn from_u8(n: u8) -> Option<Self>
fn from_u8(n: u8) -> Option<Self>
Converts an
u8
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned.source§fn from_u16(n: u16) -> Option<Self>
fn from_u16(n: u16) -> Option<Self>
Converts an
u16
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned.source§fn from_u32(n: u32) -> Option<Self>
fn from_u32(n: u32) -> Option<Self>
Converts an
u32
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned.source§fn from_u128(n: u128) -> Option<Self>
fn from_u128(n: u128) -> Option<Self>
Converts an
u128
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§impl FromStr for LiteralType
impl FromStr for LiteralType
source§impl Hash for LiteralType
impl Hash for LiteralType
source§impl Parser for LiteralType
impl Parser for LiteralType
source§fn parse(string: &str) -> ParserResult<'_, Self>
fn parse(string: &str) -> ParserResult<'_, Self>
Parses a string into a literal type.
source§impl PartialEq for LiteralType
impl PartialEq for LiteralType
source§fn eq(&self, other: &LiteralType) -> bool
fn eq(&self, other: &LiteralType) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for LiteralType
impl Serialize for LiteralType
source§impl ToBytes for LiteralType
impl ToBytes for LiteralType
impl Copy for LiteralType
impl Eq for LiteralType
impl StructuralPartialEq for LiteralType
Auto Trait Implementations§
impl RefUnwindSafe for LiteralType
impl Send for LiteralType
impl Sync for LiteralType
impl Unpin for LiteralType
impl UnwindSafe for LiteralType
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<'de, T> DeserializeExt<'de> for Twhere
T: DeserializeOwned,
impl<'de, T> DeserializeExt<'de> for Twhere
T: DeserializeOwned,
fn take_from_value<D>(
value: &mut Value,
field: &str
) -> Result<T, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.