pub struct ChainTokenInfo {
pub chain_id: u64,
pub address: &'static str,
pub decimals: u8,
pub name: &'static str,
pub symbol: &'static str,
pub logo_url: Option<&'static str>,
}Expand description
Token info used in chain metadata.
Uses a string address rather than alloy_primitives::Address because
non-EVM chains (Bitcoin, Solana) have non-hex addresses.
Fields§
§chain_id: u64Chain-specific ID.
address: &'static strToken address as a string.
decimals: u8Decimal places.
name: &'static strToken name.
symbol: &'static strToken symbol.
logo_url: Option<&'static str>Logo URL, if available.
Trait Implementations§
Source§impl Clone for ChainTokenInfo
impl Clone for ChainTokenInfo
Source§fn clone(&self) -> ChainTokenInfo
fn clone(&self) -> ChainTokenInfo
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 moreAuto Trait Implementations§
impl Freeze for ChainTokenInfo
impl RefUnwindSafe for ChainTokenInfo
impl Send for ChainTokenInfo
impl Sync for ChainTokenInfo
impl Unpin for ChainTokenInfo
impl UnsafeUnpin for ChainTokenInfo
impl UnwindSafe for ChainTokenInfo
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more