Struct ledger_ethereum::EthApp
source · pub struct EthApp<E: Exchange> { /* private fields */ }
Implementations§
source§impl<E> EthApp<E>where
E: Exchange + Send + Sync,
E::Error: Error,
impl<E> EthApp<E>where E: Exchange + Send + Sync, E::Error: Error,
sourcepub async fn configuration(
&self
) -> Result<AppConfiguration, EthError<E::Error>>
pub async fn configuration( &self ) -> Result<AppConfiguration, EthError<E::Error>>
Retrieves the app configuration
source§impl<E> EthApp<E>where
E: Exchange + Send + Sync,
E::Error: Error,
impl<E> EthApp<E>where E: Exchange + Send + Sync, E::Error: Error,
sourcepub async fn provide_erc20_token_info(
&self,
data: &[u8]
) -> Result<(), EthError<E::Error>>
pub async fn provide_erc20_token_info( &self, data: &[u8] ) -> Result<(), EthError<E::Error>>
This command provides a trusted description of an ERC 20 token to associate a contract address with a ticker and number of decimals. It shall be run immediately before performing a transaction involving a contract calling this contract address to display the proper token information to the user if necessary, as marked in GET APP CONFIGURATION flags. The signature is computed on ticker || address || number of decimals (uint4be) || chainId (uint4be) signed by the following secp256k1 public key 0482bbf2f34f367b2e5bc21847b6566f21f0976b22d3388a9a5e446ac62d25cf725b62a2555b2dd464a4da0ab2f4d506820543af1d242470b1b1a969a27578f353