pub enum SpanBatchTransactionData {
Legacy(SpanBatchLegacyTransactionData),
Eip2930(SpanBatchEip2930TransactionData),
Eip1559(SpanBatchEip1559TransactionData),
}
Expand description
The typed transaction data for a transaction within a span batch.
Variants§
Legacy(SpanBatchLegacyTransactionData)
Legacy transaction data.
Eip2930(SpanBatchEip2930TransactionData)
EIP-2930 transaction data.
Eip1559(SpanBatchEip1559TransactionData)
EIP-1559 transaction data.
Implementations§
Source§impl SpanBatchTransactionData
impl SpanBatchTransactionData
Sourcepub const fn tx_type(&self) -> TxType
pub const fn tx_type(&self) -> TxType
Returns the transaction type of the SpanBatchTransactionData.
Sourcepub fn decode_typed(b: &[u8]) -> Result<Self, Error>
pub fn decode_typed(b: &[u8]) -> Result<Self, Error>
Decodes a typed transaction into a SpanBatchTransactionData from a byte slice.
Sourcepub fn to_enveloped_tx(
&self,
nonce: u64,
gas: u64,
to: Option<Address>,
chain_id: u64,
signature: Signature,
is_protected: bool,
) -> Result<OpTxEnvelope, SpanBatchError>
pub fn to_enveloped_tx( &self, nonce: u64, gas: u64, to: Option<Address>, chain_id: u64, signature: Signature, is_protected: bool, ) -> Result<OpTxEnvelope, SpanBatchError>
Converts the SpanBatchTransactionData into a OpTxEnvelope.
Trait Implementations§
Source§impl Clone for SpanBatchTransactionData
impl Clone for SpanBatchTransactionData
Source§fn clone(&self) -> SpanBatchTransactionData
fn clone(&self) -> SpanBatchTransactionData
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 SpanBatchTransactionData
impl Debug for SpanBatchTransactionData
Source§impl Decodable for SpanBatchTransactionData
impl Decodable for SpanBatchTransactionData
Source§impl Encodable for SpanBatchTransactionData
impl Encodable for SpanBatchTransactionData
Source§impl PartialEq for SpanBatchTransactionData
impl PartialEq for SpanBatchTransactionData
Source§impl TryFrom<&TxEnvelope> for SpanBatchTransactionData
impl TryFrom<&TxEnvelope> for SpanBatchTransactionData
Source§type Error = SpanBatchError
type Error = SpanBatchError
The type returned in the event of a conversion error.
impl Eq for SpanBatchTransactionData
impl StructuralPartialEq for SpanBatchTransactionData
Auto Trait Implementations§
impl !Freeze for SpanBatchTransactionData
impl RefUnwindSafe for SpanBatchTransactionData
impl Send for SpanBatchTransactionData
impl Sync for SpanBatchTransactionData
impl Unpin for SpanBatchTransactionData
impl UnwindSafe for SpanBatchTransactionData
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)