pub enum TxType<Fr: PrimeField> {
Transfer {
fee: TokenAmount<Fr>,
outputs: Vec<TxOutput<Fr>>,
},
Deposit {
fee: TokenAmount<Fr>,
deposit_amount: TokenAmount<Fr>,
outputs: Vec<TxOutput<Fr>>,
},
DepositPermittable {
fee: TokenAmount<Fr>,
deposit_amount: TokenAmount<Fr>,
deadline: u64,
holder: Vec<u8>,
outputs: Vec<TxOutput<Fr>>,
},
Withdraw {
fee: TokenAmount<Fr>,
withdraw_amount: TokenAmount<Fr>,
to: Vec<u8>,
native_amount: TokenAmount<Fr>,
energy_amount: TokenAmount<Fr>,
},
}
Variants§
Transfer
Deposit
DepositPermittable
Withdraw
Fields
§
fee: TokenAmount<Fr>
§
withdraw_amount: TokenAmount<Fr>
§
native_amount: TokenAmount<Fr>
§
energy_amount: TokenAmount<Fr>
Trait Implementations§
Source§impl<'de, Fr> Deserialize<'de> for TxType<Fr>where
Fr: Deserialize<'de> + PrimeField,
impl<'de, Fr> Deserialize<'de> for TxType<Fr>where
Fr: Deserialize<'de> + PrimeField,
Source§fn 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
Auto Trait Implementations§
impl<Fr> Freeze for TxType<Fr>where
Fr: Freeze,
impl<Fr> RefUnwindSafe for TxType<Fr>where
Fr: RefUnwindSafe,
impl<Fr> Send for TxType<Fr>where
Fr: Send,
impl<Fr> Sync for TxType<Fr>where
Fr: Sync,
impl<Fr> Unpin for TxType<Fr>where
Fr: Unpin,
impl<Fr> UnwindSafe for TxType<Fr>where
Fr: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Out, S> FromSeed<S> for Outwhere
S: SeedBoxGen<Out>,
impl<Out, S> FromSeed<S> for Outwhere
S: SeedBoxGen<Out>,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more