Type Alias hedera::ContractCallQuery

source ·
pub type ContractCallQuery = Query<ContractCallQueryData>;
Expand description

Call a function of the given smart contract instance. It will consume the entire given amount of gas.

This is performed locally on the particular node that the client is communicating with. It cannot change the state of the contract instance (and so, cannot spend anything from the instance’s cryptocurrency account).

Aliased Type§

struct ContractCallQuery { /* private fields */ }

Implementations§

source§

impl ContractCallQuery

source

pub fn get_contract_id(&self) -> Option<ContractId>

Gets the contract instance to call.

source

pub fn contract_id(&mut self, contract_id: ContractId) -> &mut Self

Sets the contract to make a static call against.

source

pub fn get_gas(&self) -> u64

Gets the amount of gas to use for the call.

source

pub fn gas(&mut self, gas: u64) -> &mut Self

Sets the amount of gas to use for the call.

source

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

Gets the function parameters as their raw bytes.

source

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

Sets the function parameters as their raw bytes.

source

pub fn function(&mut self, name: &str) -> &mut Self

Sets the function with no parameters.

source

pub fn function_with_parameters( &mut self, name: &str, parameters: &ContractFunctionParameters ) -> &mut Self

Sets the function with parameters.

source

pub fn get_sender_account_id(&self) -> Option<AccountId>

Gets the sender for this transaction.

source

pub fn sender_account_id(&mut self, sender_account_id: AccountId) -> &mut Self

Sets the sender for this transaction.