Skip to main content

InputsTr

Trait InputsTr 

pub trait InputsTr {
    // Required methods
    fn target_address(&self) -> Address;
    fn bytecode_address(&self) -> Option<&Address>;
    fn caller_address(&self) -> Address;
    fn input(&self) -> &CallInput;
    fn call_value(&self) -> Uint<256, 4>;
    fn depth(&self) -> usize;
}
Expand description

Trait for fetching inputs of the call.

Required Methods§

fn target_address(&self) -> Address

Returns target address of the call.

fn bytecode_address(&self) -> Option<&Address>

Returns bytecode address of the call. For DELEGATECALL this address will be different from target address. And if initcode is called this address will be None.

fn caller_address(&self) -> Address

Returns caller address of the call.

fn input(&self) -> &CallInput

Returns input of the call.

fn call_value(&self) -> Uint<256, 4>

Returns call value of the call.

fn depth(&self) -> usize

Returns the call depth of the frame this interpreter executes (0 for the first frame).

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§