pub struct IconService { /* private fields */ }Implementations§
Source§impl IconService
impl IconService
pub fn new(icon_service_url: Option<String>) -> Self
pub async fn get_last_block(&self) -> Result<Value, Box<dyn Error>>
pub async fn get_block_by_height( &self, block_height: &str, ) -> Result<Value, Box<dyn Error>>
pub async fn get_block_by_hash( &self, block_hash: &str, ) -> Result<Value, Box<dyn Error>>
pub async fn get_balance(&self, address: &str) -> Result<Value, Box<dyn Error>>
pub async fn get_transaction_result( &self, tx_hash: &str, ) -> Result<Value, Box<dyn Error>>
pub async fn get_transaction_by_hash( &self, tx_hash: &str, ) -> Result<Value, Box<dyn Error>>
pub async fn call( &self, score: &str, params: Value, ) -> Result<Value, Box<dyn Error>>
pub async fn send_transaction( &self, wallet: Wallet, to: &str, value: &str, version: &str, nid: &str, nonce: &str, step_limit: &str, ) -> Result<Value, Box<dyn Error>>
pub async fn send_transaction_with_message( &self, wallet: Wallet, to: &str, value: &str, version: &str, nid: &str, nonce: &str, step_limit: &str, message: &str, ) -> Result<Value, Box<dyn Error>>
Trait Implementations§
Source§impl Default for IconService
impl Default for IconService
Source§fn default() -> IconService
fn default() -> IconService
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for IconService
impl<'de> Deserialize<'de> for IconService
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for IconService
impl RefUnwindSafe for IconService
impl Send for IconService
impl Sync for IconService
impl Unpin for IconService
impl UnwindSafe for IconService
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more