Type Alias hedera::EthereumTransaction

source ·
pub type EthereumTransaction = Transaction<EthereumTransactionData>;
Expand description

Submit an Ethereum transaction.

Aliased Type§

struct EthereumTransaction { /* private fields */ }

Implementations§

source§

impl EthereumTransaction

source

pub fn get_ethereum_data(&self) -> &[u8]

Returns the raw Ethereum transaction (RLP encoded type 0, 1, and 2).

source

pub fn ethereum_data(&mut self, data: Vec<u8>) -> &mut Self

Sets the raw Ethereum transaction (RLP encoded type 0, 1, and 2).

source

pub fn get_call_data_file_id(&self) -> Option<FileId>

Returns the file ID to find the raw Ethereum transaction (RLP encoded type 0, 1, and 2).

source

pub fn call_data_file_id(&mut self, id: FileId) -> &mut Self

Sets a file ID to find the raw Ethereum transaction (RLP encoded type 0, 1, and 2).

For large transactions (for example contract create) this should be used to set the FileId of an HFS file containing the call_data of the ethereum_data. The data in the ethereum_data will be re-written with the call_data element as a zero length string with the original contents in the referenced file at time of execution. The ethereum_data will need to be “rehydrated” with the call_data for signature validation to pass.

source

pub fn get_max_gas_allowance_hbar(&self) -> Hbar

Returns the maximum amount that the payer of the hedera transaction is willing to pay to complete the transaction.

source

pub fn max_gas_allowance_hbar(&mut self, allowance: Hbar) -> &mut Self

Sets the maximum amount that the payer of the hedera transaction is willing to pay to complete the transaction.