pub trait PayloadAttributes:
DeserializeOwned
+ Serialize
+ Debug
+ Clone
+ Send
+ Sync
+ 'static {
// Required methods
fn payload_id(&self, parent_hash: &B256) -> PayloadId;
fn timestamp(&self) -> u64;
fn withdrawals(&self) -> Option<&Vec<Withdrawal>>;
fn parent_beacon_block_root(&self) -> Option<B256>;
fn slot_number(&self) -> Option<u64>;
// Provided methods
fn target_gas_limit(&self) -> Option<u64> { ... }
fn inclusion_list_transactions(&self) -> Option<&[Bytes]> { ... }
}Expand description
Basic attributes required to initiate payload construction.
Defines minimal parameters needed to build a new execution payload. Implementations must be serializable for transmission.
Required Methods§
Sourcefn payload_id(&self, parent_hash: &B256) -> PayloadId
fn payload_id(&self, parent_hash: &B256) -> PayloadId
Computes the unique identifier for this payload build job.
Sourcefn withdrawals(&self) -> Option<&Vec<Withdrawal>>
fn withdrawals(&self) -> Option<&Vec<Withdrawal>>
Returns the withdrawals to be included in the payload.
Some for post-Shanghai blocks, None for earlier blocks.
Sourcefn parent_beacon_block_root(&self) -> Option<B256>
fn parent_beacon_block_root(&self) -> Option<B256>
Returns the parent beacon block root.
Some for post-merge blocks, None for pre-merge blocks.
Sourcefn slot_number(&self) -> Option<u64>
fn slot_number(&self) -> Option<u64>
Returns the slot number for the new payload.
Some for post-Amsterdam blocks, None for earlier blocks.
Provided Methods§
Sourcefn target_gas_limit(&self) -> Option<u64>
fn target_gas_limit(&self) -> Option<u64>
Returns the target gas limit for the new payload.
Some for payload attributes that specify the desired gas limit, None if the builder
should use its configured target.
Sourcefn inclusion_list_transactions(&self) -> Option<&[Bytes]>
fn inclusion_list_transactions(&self) -> Option<&[Bytes]>
Returns the EIP-7805 inclusion-list transactions supplied by the consensus layer.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".