Trait NetworkConstants
pub trait NetworkConstants: Clone {
// Required methods
fn coin_type(&self) -> u32;
fn hrp_sapling_extended_spending_key(&self) -> &'static str;
fn hrp_sapling_extended_full_viewing_key(&self) -> &'static str;
fn hrp_sapling_payment_address(&self) -> &'static str;
fn b58_sprout_address_prefix(&self) -> [u8; 2];
fn b58_pubkey_address_prefix(&self) -> [u8; 2];
fn b58_script_address_prefix(&self) -> [u8; 2];
fn hrp_tex_address(&self) -> &'static str;
fn hrp_unified_address(&self) -> &'static str;
fn hrp_unified_fvk(&self) -> &'static str;
fn hrp_unified_ivk(&self) -> &'static str;
}
Expand description
Constants associated with a given Zcash network.
Required Methods§
fn hrp_sapling_extended_spending_key(&self) -> &'static str
fn hrp_sapling_extended_spending_key(&self) -> &'static str
Returns the human-readable prefix for Bech32-encoded Sapling extended spending keys for the network to which this NetworkConstants value applies.
Defined in ZIP 32.
fn hrp_sapling_extended_full_viewing_key(&self) -> &'static str
fn hrp_sapling_extended_full_viewing_key(&self) -> &'static str
Returns the human-readable prefix for Bech32-encoded Sapling extended full viewing keys for the network to which this NetworkConstants value applies.
Defined in ZIP 32.
fn hrp_sapling_payment_address(&self) -> &'static str
fn hrp_sapling_payment_address(&self) -> &'static str
Returns the Bech32-encoded human-readable prefix for Sapling payment addresses for the network to which this NetworkConstants value applies.
Defined in section 5.6.4 of the Zcash Protocol Specification.
fn b58_sprout_address_prefix(&self) -> [u8; 2]
fn b58_sprout_address_prefix(&self) -> [u8; 2]
Returns the human-readable prefix for Base58Check-encoded Sprout payment addresses for the network to which this NetworkConstants value applies.
Defined in the Zcash Protocol Specification section 5.6.3.
fn b58_pubkey_address_prefix(&self) -> [u8; 2]
fn b58_pubkey_address_prefix(&self) -> [u8; 2]
Returns the human-readable prefix for Base58Check-encoded transparent pay-to-public-key-hash payment addresses for the network to which this NetworkConstants value applies.
fn b58_script_address_prefix(&self) -> [u8; 2]
fn b58_script_address_prefix(&self) -> [u8; 2]
Returns the human-readable prefix for Base58Check-encoded transparent pay-to-script-hash payment addresses for the network to which this NetworkConstants value applies.
fn hrp_tex_address(&self) -> &'static str
fn hrp_tex_address(&self) -> &'static str
Returns the Bech32-encoded human-readable prefix for TEX addresses, for the
network to which this NetworkConstants
value applies.
Defined in ZIP 320.
fn hrp_unified_address(&self) -> &'static str
fn hrp_unified_address(&self) -> &'static str
The HRP for a Bech32m-encoded mainnet Unified Address.
Defined in ZIP 316.
fn hrp_unified_fvk(&self) -> &'static str
fn hrp_unified_fvk(&self) -> &'static str
The HRP for a Bech32m-encoded mainnet Unified FVK.
Defined in ZIP 316.
fn hrp_unified_ivk(&self) -> &'static str
fn hrp_unified_ivk(&self) -> &'static str
The HRP for a Bech32m-encoded mainnet Unified IVK.
Defined in ZIP 316.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.