[][src]Struct bundled_crypto::token::paseto::token::Data

pub struct Data<M, F> {
    pub msg: M,
    pub footer: Option<F>,
}

Hold the pre-protocol data.

Fields

msg: M

The message to be serialized and sent.

footer: Option<F>

The footer to be serialized and sent.

Methods

impl<M: Serialize, F: Serialize> Data<M, F>[src]

pub fn serialize(self) -> Result<SerializedData, Error>[src]

Serialize Data into the SerializedData form.

Trait Implementations

impl<M: Eq, F: Eq> Eq for Data<M, F>[src]

impl<M: Clone, F: Clone> Clone for Data<M, F>[src]

impl<M: PartialEq, F: PartialEq> PartialEq<Data<M, F>> for Data<M, F>[src]

impl<M: Debug, F: Debug> Debug for Data<M, F>[src]

impl<M: DeserializeOwned, F: DeserializeOwned> TryFrom<SerializedData> for Data<M, F>[src]

type Error = DeserializeError

The type returned in the event of a conversion error.

impl<M: Serialize, F: Serialize> TryFrom<Data<M, F>> for SerializedData[src]

type Error = Error

The type returned in the event of a conversion error.

Auto Trait Implementations

impl<M, F> Send for Data<M, F> where
    F: Send,
    M: Send

impl<M, F> Unpin for Data<M, F> where
    F: Unpin,
    M: Unpin

impl<M, F> Sync for Data<M, F> where
    F: Sync,
    M: Sync

impl<M, F> UnwindSafe for Data<M, F> where
    F: UnwindSafe,
    M: UnwindSafe

impl<M, F> RefUnwindSafe for Data<M, F> where
    F: RefUnwindSafe,
    M: RefUnwindSafe

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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

impl<T> From<T> for 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.

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

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

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

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,