pub struct Signed<T, Sig = Signature> { /* private fields */ }
Expand description
A transaction with a signature and hash seal.
Implementations§
source§impl<T, Sig> Signed<T, Sig>
impl<T, Sig> Signed<T, Sig>
sourcepub fn into_parts(self) -> (T, Sig, B256)
pub fn into_parts(self) -> (T, Sig, B256)
Splits the transaction into parts.
sourcepub fn strip_signature(self) -> T
pub fn strip_signature(self) -> T
Returns the transaction without signature.
source§impl<T: SignableTransaction<Sig>, Sig> Signed<T, Sig>
impl<T: SignableTransaction<Sig>, Sig> Signed<T, Sig>
sourcepub const fn new_unchecked(tx: T, signature: Sig, hash: B256) -> Self
pub const fn new_unchecked(tx: T, signature: Sig, hash: B256) -> Self
Instantiate from a transaction and signature. Does not verify the signature.
sourcepub fn signature_hash(&self) -> B256
pub fn signature_hash(&self) -> B256
Calculate the signing hash for the transaction.
source§impl<T: SignableTransaction<Signature>> Signed<T, Signature>
impl<T: SignableTransaction<Signature>> Signed<T, Signature>
sourcepub fn recover_signer(&self) -> Result<Address, SignatureError>
Available on crate feature k256
only.
pub fn recover_signer(&self) -> Result<Address, SignatureError>
k256
only.Recover the signer of the transaction
Trait Implementations§
source§impl<'de, T, Sig> Deserialize<'de> for Signed<T, Sig>where
T: Deserialize<'de>,
Sig: Deserialize<'de>,
impl<'de, T, Sig> Deserialize<'de> for Signed<T, Sig>where
T: Deserialize<'de>,
Sig: Deserialize<'de>,
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 From<Signed<TxEip4844Variant>> for TxEnvelope
impl From<Signed<TxEip4844Variant>> for TxEnvelope
source§fn from(v: Signed<TxEip4844Variant>) -> Self
fn from(v: Signed<TxEip4844Variant>) -> Self
Converts to this type from the input type.
source§impl From<Signed<TxEip4844WithSidecar>> for TxEnvelope
impl From<Signed<TxEip4844WithSidecar>> for TxEnvelope
source§fn from(v: Signed<TxEip4844WithSidecar>) -> Self
fn from(v: Signed<TxEip4844WithSidecar>) -> Self
Converts to this type from the input type.
impl<T: Copy, Sig: Copy> Copy for Signed<T, Sig>
impl<T: Eq, Sig: Eq> Eq for Signed<T, Sig>
impl<T, Sig> StructuralPartialEq for Signed<T, Sig>
Auto Trait Implementations§
impl<T, Sig> Freeze for Signed<T, Sig>
impl<T, Sig> RefUnwindSafe for Signed<T, Sig>where
T: RefUnwindSafe,
Sig: RefUnwindSafe,
impl<T, Sig> Send for Signed<T, Sig>
impl<T, Sig> Sync for Signed<T, Sig>
impl<T, Sig> Unpin for Signed<T, Sig>
impl<T, Sig> UnwindSafe for Signed<T, Sig>where
T: UnwindSafe,
Sig: 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§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
)