pub struct TransactionMetadatum(_);
Implementations
sourceimpl TransactionMetadatum
impl TransactionMetadatum
pub fn from_bytes(
bytes: Vec<u8>
) -> Result<TransactionMetadatum, DeserializeError>
sourceimpl TransactionMetadatum
impl TransactionMetadatum
pub fn new_map(map: &MetadataMap) -> Self
pub fn new_list(list: &MetadataList) -> Self
pub fn new_int(int: &Int) -> Self
pub fn new_bytes(bytes: Vec<u8>) -> Result<TransactionMetadatum, JsError>
pub fn new_text(text: String) -> Result<TransactionMetadatum, JsError>
pub fn kind(&self) -> TransactionMetadatumKind
pub fn as_map(&self) -> Result<MetadataMap, JsError>
pub fn as_list(&self) -> Result<MetadataList, JsError>
pub fn as_int(&self) -> Result<Int, JsError>
pub fn as_bytes(&self) -> Result<Vec<u8>, JsError>
pub fn as_text(&self) -> Result<String, JsError>
Trait Implementations
sourceimpl Clone for TransactionMetadatum
impl Clone for TransactionMetadatum
sourcefn clone(&self) -> TransactionMetadatum
fn clone(&self) -> TransactionMetadatum
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for TransactionMetadatum
impl Debug for TransactionMetadatum
sourceimpl<'de> Deserialize<'de> for TransactionMetadatum
impl<'de> Deserialize<'de> for TransactionMetadatum
sourcefn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl Deserialize for TransactionMetadatum
impl Deserialize for TransactionMetadatum
fn deserialize<R: BufRead + Seek>(
raw: &mut Deserializer<R>
) -> Result<Self, DeserializeError>
sourceimpl Hash for TransactionMetadatum
impl Hash for TransactionMetadatum
sourceimpl JsonSchema for TransactionMetadatum
impl JsonSchema for TransactionMetadatum
sourcefn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
sourcefn json_schema(gen: &mut SchemaGenerator) -> Schema
fn json_schema(gen: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
sourcefn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the $ref
keyword. Read more
sourceimpl Ord for TransactionMetadatum
impl Ord for TransactionMetadatum
sourcefn cmp(&self, other: &TransactionMetadatum) -> Ordering
fn cmp(&self, other: &TransactionMetadatum) -> Ordering
1.21.0 · sourcefn max(self, other: Self) -> Self
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
1.21.0 · sourcefn min(self, other: Self) -> Self
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
1.50.0 · sourcefn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
Restrict a value to a certain interval. Read more
sourceimpl PartialEq<TransactionMetadatum> for TransactionMetadatum
impl PartialEq<TransactionMetadatum> for TransactionMetadatum
sourcefn eq(&self, other: &TransactionMetadatum) -> bool
fn eq(&self, other: &TransactionMetadatum) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourceimpl PartialOrd<TransactionMetadatum> for TransactionMetadatum
impl PartialOrd<TransactionMetadatum> for TransactionMetadatum
sourcefn partial_cmp(&self, other: &TransactionMetadatum) -> Option<Ordering>
fn partial_cmp(&self, other: &TransactionMetadatum) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
sourceimpl Serialize for TransactionMetadatum
impl Serialize for TransactionMetadatum
sourceimpl Serialize for TransactionMetadatum
impl Serialize for TransactionMetadatum
fn serialize<'se, W: Write>(
&self,
serializer: &'se mut Serializer<W>
) -> Result<&'se mut Serializer<W>>
impl Eq for TransactionMetadatum
impl StructuralEq for TransactionMetadatum
impl StructuralPartialEq for TransactionMetadatum
Auto Trait Implementations
impl RefUnwindSafe for TransactionMetadatum
impl Send for TransactionMetadatum
impl Sync for TransactionMetadatum
impl Unpin for TransactionMetadatum
impl UnwindSafe for TransactionMetadatum
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more