pub trait SignedTransactionIntoRecoveredExt: SignedTransaction {
// Provided methods
fn try_ecrecovered(&self) -> Option<RecoveredTx<Self>> { ... }
fn try_into_ecrecovered(self) -> Result<RecoveredTx<Self>, Self> { ... }
fn into_ecrecovered_unchecked(self) -> Option<RecoveredTx<Self>> { ... }
fn with_signer(self, signer: Address) -> RecoveredTx<Self> { ... }
}
Expand description
Extension trait for [SignedTransaction
] to convert it into RecoveredTx
.
Provided Methods§
Sourcefn try_ecrecovered(&self) -> Option<RecoveredTx<Self>>
fn try_ecrecovered(&self) -> Option<RecoveredTx<Self>>
Tries to recover signer and return RecoveredTx
by cloning the type.
Sourcefn try_into_ecrecovered(self) -> Result<RecoveredTx<Self>, Self>
fn try_into_ecrecovered(self) -> Result<RecoveredTx<Self>, Self>
Tries to recover signer and return RecoveredTx
.
Returns Err(Self)
if the transaction’s signature is invalid, see also
[SignedTransaction::recover_signer
].
Sourcefn into_ecrecovered_unchecked(self) -> Option<RecoveredTx<Self>>
fn into_ecrecovered_unchecked(self) -> Option<RecoveredTx<Self>>
Consumes the type, recover signer and return RecoveredTx
without
ensuring that the signature has a low s
value (EIP-2).
Returns None
if the transaction’s signature is invalid.
Sourcefn with_signer(self, signer: Address) -> RecoveredTx<Self>
fn with_signer(self, signer: Address) -> RecoveredTx<Self>
Returns the RecoveredTx
transaction with the given sender.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.