pub struct NativeTransaction {
pub nonce: U256,
pub gas_price: U256,
pub gas: U256,
pub action: Action,
pub value: U256,
pub storage_limit: u64,
pub epoch_height: u64,
pub chain_id: u32,
pub data: Bytes,
}
Fields§
§nonce: U256
Nonce.
gas_price: U256
Gas price.
gas: U256
Gas paid up front for transaction execution.
action: Action
Action, can be either call or contract create.
value: U256
Transferred value.
storage_limit: u64
Maximum storage increasement in this execution.
epoch_height: u64
The epoch height of the transaction. A transaction can only be packed between the epochs of [epoch_height - TRANSACTION_EPOCH_BOUND, epoch_height + TRANSACTION_EPOCH_BOUND]
chain_id: u32
The chain id of the transaction
data: Bytes
Transaction data.
Implementations§
source§impl NativeTransaction
impl NativeTransaction
sourcepub fn fake_sign(self, from: AddressWithSpace) -> SignedTransaction
pub fn fake_sign(self, from: AddressWithSpace) -> SignedTransaction
Specify the sender; this won’t survive the serialize/deserialize process, but can be cloned.
Trait Implementations§
source§impl Clone for NativeTransaction
impl Clone for NativeTransaction
source§fn clone(&self) -> NativeTransaction
fn clone(&self) -> NativeTransaction
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for NativeTransaction
impl Debug for NativeTransaction
source§impl Decodable for NativeTransaction
impl Decodable for NativeTransaction
source§impl Default for NativeTransaction
impl Default for NativeTransaction
source§fn default() -> NativeTransaction
fn default() -> NativeTransaction
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for NativeTransaction
impl<'de> Deserialize<'de> for NativeTransaction
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
source§impl Encodable for NativeTransaction
impl Encodable for NativeTransaction
source§impl From<NativeTransaction> for Transaction
impl From<NativeTransaction> for Transaction
source§fn from(tx: NativeTransaction) -> Self
fn from(tx: NativeTransaction) -> Self
Converts to this type from the input type.
source§impl PartialEq for NativeTransaction
impl PartialEq for NativeTransaction
source§fn eq(&self, other: &NativeTransaction) -> bool
fn eq(&self, other: &NativeTransaction) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for NativeTransaction
impl Serialize for NativeTransaction
impl Eq for NativeTransaction
impl StructuralPartialEq for NativeTransaction
Auto Trait Implementations§
impl RefUnwindSafe for NativeTransaction
impl Send for NativeTransaction
impl Sync for NativeTransaction
impl Unpin for NativeTransaction
impl UnwindSafe for NativeTransaction
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