pub struct BlockchainProvider {
pub provider_type: ProviderType,
pub api_key: Option<String>,
pub rpc_url: Option<String>,
}Expand description
Blockchain provider configuration
Fields§
§provider_type: ProviderType§api_key: Option<String>§rpc_url: Option<String>Implementations§
Source§impl BlockchainProvider
impl BlockchainProvider
Sourcepub fn new(provider_type: ProviderType, api_key: Option<String>) -> Self
pub fn new(provider_type: ProviderType, api_key: Option<String>) -> Self
Create new provider with API key
Sourcepub fn with_rpc_url(provider_type: ProviderType, rpc_url: String) -> Self
pub fn with_rpc_url(provider_type: ProviderType, rpc_url: String) -> Self
Create provider with custom RPC URL
Trait Implementations§
Source§impl Clone for BlockchainProvider
impl Clone for BlockchainProvider
Source§fn clone(&self) -> BlockchainProvider
fn clone(&self) -> BlockchainProvider
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BlockchainProvider
impl Debug for BlockchainProvider
Source§impl<'de> Deserialize<'de> for BlockchainProvider
impl<'de> Deserialize<'de> for BlockchainProvider
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 BlockchainProvider
impl RefUnwindSafe for BlockchainProvider
impl Send for BlockchainProvider
impl Sync for BlockchainProvider
impl Unpin for BlockchainProvider
impl UnsafeUnpin for BlockchainProvider
impl UnwindSafe for BlockchainProvider
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