Enum borsh::schema::Fields[][src]

pub enum Fields {
    NamedFields(Vec<(FieldName, Declaration)>),
    UnnamedFields(Vec<Declaration>),
    Empty,
}

The collection representing the fields of a struct.

Variants

NamedFields(Vec<(FieldName, Declaration)>)

The struct with named fields.

UnnamedFields(Vec<Declaration>)

The struct with unnamed fields, structurally identical to a tuple.

Empty

The struct with no fields.

Trait Implementations

impl BorshDeserialize for Fields where
    Vec<(FieldName, Declaration)>: BorshDeserialize,
    Vec<Declaration>: BorshDeserialize
[src]

impl BorshSchema for Fields[src]

impl BorshSerialize for Fields where
    Vec<(FieldName, Declaration)>: BorshSerialize,
    Vec<Declaration>: BorshSerialize
[src]

impl Debug for Fields[src]

impl PartialEq<Fields> for Fields[src]

impl StructuralPartialEq for Fields[src]

Auto Trait Implementations

impl RefUnwindSafe for Fields

impl Send for Fields

impl Sync for Fields

impl Unpin for Fields

impl UnwindSafe for Fields

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.