Enum snarkvm_wasm::program::ValueType
pub enum ValueType<N>where
N: Network,{
Constant(PlaintextType<N>),
Public(PlaintextType<N>),
Private(PlaintextType<N>),
Record(Identifier<N>),
ExternalRecord(Locator<N>),
}Variants§
Constant(PlaintextType<N>)
A constant type.
Public(PlaintextType<N>)
A publicly-visible type.
Private(PlaintextType<N>)
A private type decrypted with the account owner’s address.
Record(Identifier<N>)
A record type inherits its visibility from the record definition.
ExternalRecord(Locator<N>)
An external record type inherits its visibility from its record definition.
Trait Implementations§
§impl<'de, N> Deserialize<'de> for ValueType<N>where
N: Network,
impl<'de, N> Deserialize<'de> for ValueType<N>where
N: Network,
§fn deserialize<D>(
deserializer: D
) -> Result<ValueType<N>, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D
) -> Result<ValueType<N>, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Deserializes the value type from a string or bytes.
§impl<N> From<ValueType<N>> for RegisterType<N>where
N: Network,
impl<N> From<ValueType<N>> for RegisterType<N>where
N: Network,
§fn from(value: ValueType<N>) -> RegisterType<N>
fn from(value: ValueType<N>) -> RegisterType<N>
Converts a value type to a register type.
§impl<N> PartialEq<ValueType<N>> for ValueType<N>where
N: PartialEq<N> + Network,
impl<N> PartialEq<ValueType<N>> for ValueType<N>where
N: PartialEq<N> + Network,
§impl<N> Serialize for ValueType<N>where
N: Network,
impl<N> Serialize for ValueType<N>where
N: Network,
§fn serialize<S>(
&self,
serializer: S
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>(
&self,
serializer: S
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
Serializes the value type into string or bytes.
impl<N> Copy for ValueType<N>where
N: Copy + Network,
impl<N> Eq for ValueType<N>where
N: Eq + Network,
impl<N> StructuralEq for ValueType<N>where
N: Network,
impl<N> StructuralPartialEq for ValueType<N>where
N: Network,
Auto Trait Implementations§
impl<N> RefUnwindSafe for ValueType<N>where
<N as Environment>::Field: RefUnwindSafe,
impl<N> Send for ValueType<N>
impl<N> Sync for ValueType<N>
impl<N> Unpin for ValueType<N>where
<N as Environment>::Field: Unpin,
impl<N> UnwindSafe for ValueType<N>where
<N as Environment>::Field: UnwindSafe,
Blanket Implementations§
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more