Trait fuels_core::traits::Tokenizable

source ·
pub trait Tokenizable {
    // Required methods
    fn from_token(token: Token) -> Result<Self>
       where Self: Sized;
    fn into_token(self) -> Token;
}

Required Methods§

source

fn from_token(token: Token) -> Result<Self>
where Self: Sized,

Converts a Token into expected type.

source

fn into_token(self) -> Token

Converts a specified type back into token.

Implementations on Foreign Types§

source§

impl Tokenizable for bool

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl Tokenizable for u8

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl Tokenizable for u16

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl Tokenizable for u32

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl Tokenizable for u64

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl Tokenizable for u128

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl Tokenizable for ()

source§

fn from_token(token: Token) -> Result<Self>
where Self: Sized,

source§

fn into_token(self) -> Token

source§

impl Tokenizable for String

source§

fn from_token(token: Token) -> Result<Self>
where Self: Sized,

source§

fn into_token(self) -> Token

source§

impl<A> Tokenizable for (A,)
where A: Tokenizable,

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B> Tokenizable for (A, B)
where A: Tokenizable, B: Tokenizable,

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C> Tokenizable for (A, B, C)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D> Tokenizable for (A, B, C, D)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E> Tokenizable for (A, B, C, D, E)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F> Tokenizable for (A, B, C, D, E, F)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F, G> Tokenizable for (A, B, C, D, E, F, G)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F, G, H> Tokenizable for (A, B, C, D, E, F, G, H)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F, G, H, I> Tokenizable for (A, B, C, D, E, F, G, H, I)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F, G, H, I, J> Tokenizable for (A, B, C, D, E, F, G, H, I, J)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F, G, H, I, J, K> Tokenizable for (A, B, C, D, E, F, G, H, I, J, K)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F, G, H, I, J, K, L> Tokenizable for (A, B, C, D, E, F, G, H, I, J, K, L)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M> Tokenizable for (A, B, C, D, E, F, G, H, I, J, K, L, M)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N> Tokenizable for (A, B, C, D, E, F, G, H, I, J, K, L, M, N)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O> Tokenizable for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P> Tokenizable for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P)

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<T> Tokenizable for Option<T>

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<T, E> Tokenizable for Result<T, E>

source§

fn from_token(token: Token) -> Result<Self>

source§

fn into_token(self) -> Token

source§

impl<T: Tokenizable> Tokenizable for Vec<T>

source§

fn from_token(token: Token) -> Result<Self>
where Self: Sized,

source§

fn into_token(self) -> Token

source§

impl<const SIZE: usize, T: Tokenizable> Tokenizable for [T; SIZE]

source§

fn from_token(token: Token) -> Result<Self>
where Self: Sized,

source§

fn into_token(self) -> Token

Implementors§