Struct alloy_rpc_types_eth::transaction::Receipt
source · pub struct Receipt<T = Log> {
pub status: Eip658Value,
pub cumulative_gas_used: u64,
pub logs: Vec<T>,
}
Expand description
Receipt containing result of transaction execution.
Fields§
§status: Eip658Value
If transaction is executed successfully.
This is the statusCode
cumulative_gas_used: u64
Gas used
logs: Vec<T>
Log send from contracts.
Implementations§
source§impl<T> Receipt<T>
impl<T> Receipt<T>
sourcepub fn bloom_slow(&self) -> Bloom
pub fn bloom_slow(&self) -> Bloom
Calculates Log
’s bloom filter. this is slow operation and ReceiptWithBloom can
be used to cache this value.
sourcepub fn with_bloom(self) -> ReceiptWithBloom<Receipt<T>>
pub fn with_bloom(self) -> ReceiptWithBloom<Receipt<T>>
Calculates the bloom filter for the receipt and returns the ReceiptWithBloom container type.
source§impl<T> Receipt<T>where
T: Encodable,
impl<T> Receipt<T>where
T: Encodable,
sourcepub fn rlp_encoded_fields_length_with_bloom(&self, bloom: &Bloom) -> usize
pub fn rlp_encoded_fields_length_with_bloom(&self, bloom: &Bloom) -> usize
Returns length of RLP-encoded receipt fields with the given Bloom
without an RLP header.
sourcepub fn rlp_encode_fields_with_bloom(&self, bloom: &Bloom, out: &mut dyn BufMut)
pub fn rlp_encode_fields_with_bloom(&self, bloom: &Bloom, out: &mut dyn BufMut)
RLP-encodes receipt fields with the given Bloom
without an RLP header.
sourcepub fn rlp_header_with_bloom(&self, bloom: &Bloom) -> Header
pub fn rlp_header_with_bloom(&self, bloom: &Bloom) -> Header
Returns RLP header for this receipt encoding with the given Bloom
.
Trait Implementations§
source§impl<'de, T> Deserialize<'de> for Receipt<T>where
T: Deserialize<'de>,
impl<'de, T> Deserialize<'de> for Receipt<T>where
T: Deserialize<'de>,
source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Receipt<T>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Receipt<T>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<T> PartialEq for Receipt<T>where
T: PartialEq,
impl<T> PartialEq for Receipt<T>where
T: PartialEq,
source§impl<T> RlpDecodableReceipt for Receipt<T>where
T: Decodable,
impl<T> RlpDecodableReceipt for Receipt<T>where
T: Decodable,
source§fn rlp_decode_with_bloom(
buf: &mut &[u8],
) -> Result<ReceiptWithBloom<Receipt<T>>, Error>
fn rlp_decode_with_bloom( buf: &mut &[u8], ) -> Result<ReceiptWithBloom<Receipt<T>>, Error>
RLP decodes receipt and
Bloom
into ReceiptWithBloom
instance.source§impl<T> RlpEncodableReceipt for Receipt<T>where
T: Encodable,
impl<T> RlpEncodableReceipt for Receipt<T>where
T: Encodable,
source§fn rlp_encoded_length_with_bloom(&self, bloom: &Bloom) -> usize
fn rlp_encoded_length_with_bloom(&self, bloom: &Bloom) -> usize
Returns the length of the receipt payload with the provided bloom filter.
source§fn rlp_encode_with_bloom(&self, bloom: &Bloom, out: &mut dyn BufMut)
fn rlp_encode_with_bloom(&self, bloom: &Bloom, out: &mut dyn BufMut)
RLP encodes the receipt with the provided bloom filter.
source§impl<T> Serialize for Receipt<T>where
T: Serialize,
impl<T> Serialize for Receipt<T>where
T: Serialize,
source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
source§impl<T> TxReceipt for Receipt<T>
impl<T> TxReceipt for Receipt<T>
source§fn status_or_post_state(&self) -> Eip658Value
fn status_or_post_state(&self) -> Eip658Value
Returns the status or post state of the transaction. Read more
source§fn bloom(&self) -> Bloom
fn bloom(&self) -> Bloom
Returns the bloom filter for the logs in the receipt. This operation
may be expensive.
source§fn cumulative_gas_used(&self) -> u64
fn cumulative_gas_used(&self) -> u64
Returns the cumulative gas used in the block after this transaction was executed.
source§fn logs(&self) -> &[<Receipt<T> as TxReceipt>::Log]
fn logs(&self) -> &[<Receipt<T> as TxReceipt>::Log]
Returns the logs emitted by this transaction.
source§fn bloom_cheap(&self) -> Option<Bloom>
fn bloom_cheap(&self) -> Option<Bloom>
Returns the bloom filter for the logs in the receipt, if it is cheap to
compute.
source§fn with_bloom_ref(&self) -> ReceiptWithBloom<&Self>
fn with_bloom_ref(&self) -> ReceiptWithBloom<&Self>
Returns
ReceiptWithBloom
with the computed bloom filter Self::bloom
and a reference
to the receipt.source§fn into_with_bloom(self) -> ReceiptWithBloom<Self>
fn into_with_bloom(self) -> ReceiptWithBloom<Self>
Consumes the type and converts it into
ReceiptWithBloom
with the computed bloom filter
Self::bloom
and the receipt.impl<T> Eq for Receipt<T>where
T: Eq,
impl<T> StructuralPartialEq for Receipt<T>
Auto Trait Implementations§
impl<T> Freeze for Receipt<T>
impl<T> RefUnwindSafe for Receipt<T>where
T: RefUnwindSafe,
impl<T> Send for Receipt<T>where
T: Send,
impl<T> Sync for Receipt<T>where
T: Sync,
impl<T> Unpin for Receipt<T>where
T: Unpin,
impl<T> UnwindSafe for Receipt<T>where
T: 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§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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