1
# [doc = r" A known address (sub)format/network ID for SS58."] # [non_exhaustive] # [repr (u16)] # [derive (Copy , Clone , PartialEq , Eq , Debug)] pub enum Ss58AddressFormatRegistry { # [doc = "Bare 32-bit Ed25519 public key."] BareEd25519Account = 3u16 , # [doc = "Bare 32-bit ECDSA SECP-256k1 public key."] BareSecp256K1Account = 43u16 , # [doc = "Bare 32-bit Schnorr/Ristretto (S/R 25519) public key."] BareSr25519Account = 1u16 , # [doc = "Acala - <https://acala.network/>"] AcalaAccount = 10u16 , # [doc = "Altair - <https://centrifuge.io/>"] AltairAccount = 136u16 , # [doc = "Ares Protocol - <https://www.aresprotocol.com/>"] AresAccount = 34u16 , # [doc = "AvN Mainnet - <https://aventus.io>"] AventusAccount = 65u16 , # [doc = "Basilisk - <https://bsx.fi>"] BasiliskAccount = 10041u16 , # [doc = "Bifrost - <https://bifrost.finance/>"] BifrostAccount = 6u16 , # [doc = "Calamari: Manta Canary Network - <https://manta.network>"] CalamariAccount = 78u16 , # [doc = "Centrifuge Chain - <https://centrifuge.io/>"] CentrifugeAccount = 36u16 , # [doc = "CESS - <https://cess.cloud>"] CessAccount = 11331u16 , # [doc = "CESS Testnet - <https://cess.cloud>"] CessTestnetAccount = 11330u16 , # [doc = "ChainX - <https://chainx.org/>"] ChainxAccount = 44u16 , # [doc = "Clover Finance - <https://clover.finance>"] CloverAccount = 128u16 , # [doc = "Composable - <https://composable.finance>"] ComposableAccount = 50u16 , # [doc = "Automata ContextFree - <https://ata.network>"] ContextfreeAccount = 11820u16 , # [doc = "CORD Network - <https://cord.network/>"] CordAccount = 29u16 , # [doc = "Crust Network - <https://crust.network>"] CrustAccount = 66u16 , # [doc = "Dark Mainnet"] DarkAccount = 17u16 , # [doc = "Darwinia Network - <https://darwinia.network/>"] DarwiniaAccount = 18u16 , # [doc = "DataHighway"] DatahighwayAccount = 33u16 , # [doc = "Dock Mainnet - <https://dock.io>"] DockMainnetAccount = 22u16 , # [doc = "Dock Testnet - <https://dock.io>"] DockTestnetAccount = 21u16 , # [doc = "Edgeware - <https://edgewa.re>"] EdgewareAccount = 7u16 , # [doc = "Efinity - <https://efinity.io/>"] EfinityAccount = 1110u16 , # [doc = "Equilibrium Network - <https://equilibrium.io>"] EquilibriumAccount = 68u16 , # [doc = "GeekCash - <https://geekcash.org>"] GeekAccount = 19u16 , # [doc = "Genshiro Network - <https://genshiro.equilibrium.io>"] GenshiroAccount = 67u16 , # [doc = "Heiko - <https://parallel.fi/>"] HeikoAccount = 110u16 , # [doc = "HydraDX - <https://hydradx.io>"] HydradxAccount = 63u16 , # [doc = "Integritee - <https://integritee.network>"] IntegriteeAccount = 13u16 , # [doc = "Integritee Incognito - <https://integritee.network>"] IntegriteeIncognitoAccount = 113u16 , # [doc = "Interlay - <https://interlay.io/>"] InterlayAccount = 2032u16 , # [doc = "Jupiter - <https://jupiter.patract.io>"] JupiterAccount = 26u16 , # [doc = "Kapex - <https://totemaccounting.com>"] KapexAccount = 2007u16 , # [doc = "Karura - <https://karura.network/>"] KaruraAccount = 8u16 , # [doc = "Katal Chain"] KatalchainAccount = 4u16 , # [doc = "KILT Chain - <https://kilt.io/>"] KiltAccount = 38u16 , # [doc = "Kintsugi - <https://interlay.io/>"] KintsugiAccount = 2092u16 , # [doc = "Kulupu - <https://kulupu.network/>"] KulupuAccount = 16u16 , # [doc = "Kusama Relay Chain - <https://kusama.network>"] KusamaAccount = 2u16 , # [doc = "Laminar - <http://laminar.network/>"] LaminarAccount = 11u16 , # [doc = "Litentry Network - <https://litentry.com/>"] LitentryAccount = 31u16 , # [doc = "Manta network - <https://manta.network>"] MantaAccount = 77u16 , # [doc = "MathChain mainnet - <https://mathwallet.org>"] MathchainAccount = 39u16 , # [doc = "MathChain testnet - <https://mathwallet.org>"] MathchainTestnetAccount = 40u16 , # [doc = "Moonbeam - <https://moonbeam.network>"] MoonbeamAccount = 1284u16 , # [doc = "Moonriver - <https://moonbeam.network>"] MoonriverAccount = 1285u16 , # [doc = "Neatcoin Mainnet - <https://neatcoin.org>"] NeatcoinAccount = 48u16 , # [doc = "Nodle Chain - <https://nodle.io/>"] NodleAccount = 37u16 , # [doc = "OriginTrail Parachain - <https://origintrail.io>"] OrigintrailParachainAccount = 101u16 , # [doc = "Parallel - <https://parallel.fi/>"] ParallelAccount = 172u16 , # [doc = "Phala Network - <https://phala.network>"] PhalaAccount = 30u16 , # [doc = "Picasso - <https://picasso.composable.finance>"] PicassoAccount = 49u16 , # [doc = "Pioneer Network by Bit.Country - <https://bit.country>"] PioneerNetworkAccount = 268u16 , # [doc = "Plasm Network - <https://plasmnet.io>"] PlasmAccount = 5u16 , # [doc = "Polimec Chain - <https://polimec.io/>"] PoliAccount = 41u16 , # [doc = "Polkadex Mainnet - <https://polkadex.trade>"] PolkadexAccount = 88u16 , # [doc = "Polkadot Relay Chain - <https://polkadot.network>"] PolkadotAccount = 0u16 , # [doc = "PolkaFoundry Network - <https://polkafoundry.com>"] PolkafoundryAccount = 99u16 , # [doc = "PolkaSmith Canary Network - <https://polkafoundry.com>"] PolkasmithAccount = 98u16 , # [doc = "Polymesh - <https://polymath.network/>"] PolymeshAccount = 12u16 , # [doc = "Pontem Network - <https://pontem.network>"] PontemNetworkAccount = 105u16 , # [doc = "QUARTZ by UNIQUE - <https://unique.network>"] QuartzMainnetAccount = 255u16 , # [doc = "This prefix is reserved."] Reserved46Account = 46u16 , # [doc = "This prefix is reserved."] Reserved47Account = 47u16 , # [doc = "Laminar Reynolds Canary - <http://laminar.network/>"] ReynoldsAccount = 9u16 , # [doc = "Robonomics - <https://robonomics.network>"] RobonomicsAccount = 32u16 , # [doc = "ShiftNrg"] ShiftAccount = 23u16 , # [doc = "Social Network - <https://social.network>"] SocialNetworkAccount = 252u16 , # [doc = "SORA Network - <https://sora.org>"] SoraAccount = 69u16 , # [doc = "Stafi - <https://stafi.io>"] StafiAccount = 20u16 , # [doc = "Subsocial"] SubsocialAccount = 28u16 , # [doc = "Subspace - <https://subspace.network>"] SubspaceAccount = 6094u16 , # [doc = "Subspace testnet - <https://subspace.network>"] SubspaceTestnetAccount = 2254u16 , # [doc = "Substrate - <https://substrate.io/>"] SubstrateAccount = 42u16 , # [doc = "Synesthesia - <https://synesthesia.network/>"] SynesthesiaAccount = 15u16 , # [doc = "Totem - <https://totemaccounting.com>"] TotemAccount = 14u16 , # [doc = "UniArts Network - <https://uniarts.me>"] UniartsAccount = 45u16 , # [doc = "Valiu Liquidity Network - <https://valiu.com/>"] VlnAccount = 35u16 , # [doc = "xx network - <https://xx.network>"] XxnetworkAccount = 55u16 , # [doc = "Zeitgeist - <https://zeitgeist.pm>"] ZeitgeistAccount = 73u16 , # [doc = "ZERO - <https://zero.io>"] ZeroAccount = 24u16 , # [doc = "ZERO Alphaville - <https://zero.io>"] ZeroAlphavilleAccount = 25u16 , } # [doc = r" All non-custom address formats (Sorted by network)"] static ALL_SS58_ADDRESS_FORMATS : [Ss58AddressFormatRegistry ; 85usize] = [Ss58AddressFormatRegistry :: BareEd25519Account , Ss58AddressFormatRegistry :: BareSecp256K1Account , Ss58AddressFormatRegistry :: BareSr25519Account , Ss58AddressFormatRegistry :: AcalaAccount , Ss58AddressFormatRegistry :: AltairAccount , Ss58AddressFormatRegistry :: AresAccount , Ss58AddressFormatRegistry :: AventusAccount , Ss58AddressFormatRegistry :: BasiliskAccount , Ss58AddressFormatRegistry :: BifrostAccount , Ss58AddressFormatRegistry :: CalamariAccount , Ss58AddressFormatRegistry :: CentrifugeAccount , Ss58AddressFormatRegistry :: CessAccount , Ss58AddressFormatRegistry :: CessTestnetAccount , Ss58AddressFormatRegistry :: ChainxAccount , Ss58AddressFormatRegistry :: CloverAccount , Ss58AddressFormatRegistry :: ComposableAccount , Ss58AddressFormatRegistry :: ContextfreeAccount , Ss58AddressFormatRegistry :: CordAccount , Ss58AddressFormatRegistry :: CrustAccount , Ss58AddressFormatRegistry :: DarkAccount , Ss58AddressFormatRegistry :: DarwiniaAccount , Ss58AddressFormatRegistry :: DatahighwayAccount , Ss58AddressFormatRegistry :: DockMainnetAccount , Ss58AddressFormatRegistry :: DockTestnetAccount , Ss58AddressFormatRegistry :: EdgewareAccount , Ss58AddressFormatRegistry :: EfinityAccount , Ss58AddressFormatRegistry :: EquilibriumAccount , Ss58AddressFormatRegistry :: GeekAccount , Ss58AddressFormatRegistry :: GenshiroAccount , Ss58AddressFormatRegistry :: HeikoAccount , Ss58AddressFormatRegistry :: HydradxAccount , Ss58AddressFormatRegistry :: IntegriteeAccount , Ss58AddressFormatRegistry :: IntegriteeIncognitoAccount , Ss58AddressFormatRegistry :: InterlayAccount , Ss58AddressFormatRegistry :: JupiterAccount , Ss58AddressFormatRegistry :: KapexAccount , Ss58AddressFormatRegistry :: KaruraAccount , Ss58AddressFormatRegistry :: KatalchainAccount , Ss58AddressFormatRegistry :: KiltAccount , Ss58AddressFormatRegistry :: KintsugiAccount , Ss58AddressFormatRegistry :: KulupuAccount , Ss58AddressFormatRegistry :: KusamaAccount , Ss58AddressFormatRegistry :: LaminarAccount , Ss58AddressFormatRegistry :: LitentryAccount , Ss58AddressFormatRegistry :: MantaAccount , Ss58AddressFormatRegistry :: MathchainAccount , Ss58AddressFormatRegistry :: MathchainTestnetAccount , Ss58AddressFormatRegistry :: MoonbeamAccount , Ss58AddressFormatRegistry :: MoonriverAccount , Ss58AddressFormatRegistry :: NeatcoinAccount , Ss58AddressFormatRegistry :: NodleAccount , Ss58AddressFormatRegistry :: OrigintrailParachainAccount , Ss58AddressFormatRegistry :: ParallelAccount , Ss58AddressFormatRegistry :: PhalaAccount , Ss58AddressFormatRegistry :: PicassoAccount , Ss58AddressFormatRegistry :: PioneerNetworkAccount , Ss58AddressFormatRegistry :: PlasmAccount , Ss58AddressFormatRegistry :: PoliAccount , Ss58AddressFormatRegistry :: PolkadexAccount , Ss58AddressFormatRegistry :: PolkadotAccount , Ss58AddressFormatRegistry :: PolkafoundryAccount , Ss58AddressFormatRegistry :: PolkasmithAccount , Ss58AddressFormatRegistry :: PolymeshAccount , Ss58AddressFormatRegistry :: PontemNetworkAccount , Ss58AddressFormatRegistry :: QuartzMainnetAccount , Ss58AddressFormatRegistry :: Reserved46Account , Ss58AddressFormatRegistry :: Reserved47Account , Ss58AddressFormatRegistry :: ReynoldsAccount , Ss58AddressFormatRegistry :: RobonomicsAccount , Ss58AddressFormatRegistry :: ShiftAccount , Ss58AddressFormatRegistry :: SocialNetworkAccount , Ss58AddressFormatRegistry :: SoraAccount , Ss58AddressFormatRegistry :: StafiAccount , Ss58AddressFormatRegistry :: SubsocialAccount , Ss58AddressFormatRegistry :: SubspaceAccount , Ss58AddressFormatRegistry :: SubspaceTestnetAccount , Ss58AddressFormatRegistry :: SubstrateAccount , Ss58AddressFormatRegistry :: SynesthesiaAccount , Ss58AddressFormatRegistry :: TotemAccount , Ss58AddressFormatRegistry :: UniartsAccount , Ss58AddressFormatRegistry :: VlnAccount , Ss58AddressFormatRegistry :: XxnetworkAccount , Ss58AddressFormatRegistry :: ZeitgeistAccount , Ss58AddressFormatRegistry :: ZeroAccount , Ss58AddressFormatRegistry :: ZeroAlphavilleAccount ,] ; # [doc = r" Names of all address formats (Sorted by network)"] static ALL_SS58_ADDRESS_FORMAT_NAMES : [& str ; 85usize] = ["BareEd25519" , "BareSecp256k1" , "BareSr25519" , "acala" , "altair" , "ares" , "aventus" , "basilisk" , "bifrost" , "calamari" , "centrifuge" , "cess" , "cess-testnet" , "chainx" , "clover" , "composable" , "contextfree" , "cord" , "crust" , "dark" , "darwinia" , "datahighway" , "dock-mainnet" , "dock-testnet" , "edgeware" , "efinity" , "equilibrium" , "geek" , "genshiro" , "heiko" , "hydradx" , "integritee" , "integritee-incognito" , "interlay" , "jupiter" , "kapex" , "karura" , "katalchain" , "kilt" , "kintsugi" , "kulupu" , "kusama" , "laminar" , "litentry" , "manta" , "mathchain" , "mathchain-testnet" , "moonbeam" , "moonriver" , "neatcoin" , "nodle" , "origintrail-parachain" , "parallel" , "phala" , "picasso" , "pioneer_network" , "plasm" , "poli" , "polkadex" , "polkadot" , "polkafoundry" , "polkasmith" , "polymesh" , "pontem-network" , "quartz_mainnet" , "reserved46" , "reserved47" , "reynolds" , "robonomics" , "shift" , "social-network" , "sora" , "stafi" , "subsocial" , "subspace" , "subspace_testnet" , "substrate" , "synesthesia" , "totem" , "uniarts" , "vln" , "xxnetwork" , "zeitgeist" , "zero" , "zero-alphaville" ,] ; # [doc = r" (Sorted) prefixes to index of ALL_SS58_ADDRESS_FORMATS"] static PREFIX_TO_INDEX : [(u16 , usize) ; 85usize] = [(0u16 , 59usize) , (1u16 , 2usize) , (2u16 , 41usize) , (3u16 , 0usize) , (4u16 , 37usize) , (5u16 , 56usize) , (6u16 , 8usize) , (7u16 , 24usize) , (8u16 , 36usize) , (9u16 , 67usize) , (10u16 , 3usize) , (11u16 , 42usize) , (12u16 , 62usize) , (13u16 , 31usize) , (14u16 , 78usize) , (15u16 , 77usize) , (16u16 , 40usize) , (17u16 , 19usize) , (18u16 , 20usize) , (19u16 , 27usize) , (20u16 , 72usize) , (21u16 , 23usize) , (22u16 , 22usize) , (23u16 , 69usize) , (24u16 , 83usize) , (25u16 , 84usize) , (26u16 , 34usize) , (28u16 , 73usize) , (29u16 , 17usize) , (30u16 , 53usize) , (31u16 , 43usize) , (32u16 , 68usize) , (33u16 , 21usize) , (34u16 , 5usize) , (35u16 , 80usize) , (36u16 , 10usize) , (37u16 , 50usize) , (38u16 , 38usize) , (39u16 , 45usize) , (40u16 , 46usize) , (41u16 , 57usize) , (42u16 , 76usize) , (43u16 , 1usize) , (44u16 , 13usize) , (45u16 , 79usize) , (46u16 , 65usize) , (47u16 , 66usize) , (48u16 , 49usize) , (49u16 , 54usize) , (50u16 , 15usize) , (55u16 , 81usize) , (63u16 , 30usize) , (65u16 , 6usize) , (66u16 , 18usize) , (67u16 , 28usize) , (68u16 , 26usize) , (69u16 , 71usize) , (73u16 , 82usize) , (77u16 , 44usize) , (78u16 , 9usize) , (88u16 , 58usize) , (98u16 , 61usize) , (99u16 , 60usize) , (101u16 , 51usize) , (105u16 , 63usize) , (110u16 , 29usize) , (113u16 , 32usize) , (128u16 , 14usize) , (136u16 , 4usize) , (172u16 , 52usize) , (252u16 , 70usize) , (255u16 , 64usize) , (268u16 , 55usize) , (1110u16 , 25usize) , (1284u16 , 47usize) , (1285u16 , 48usize) , (2007u16 , 35usize) , (2032u16 , 33usize) , (2092u16 , 39usize) , (2254u16 , 75usize) , (6094u16 , 74usize) , (10041u16 , 7usize) , (11330u16 , 12usize) , (11331u16 , 11usize) , (11820u16 , 16usize) ,] ; impl Ss58AddressFormat { # [doc = r" Network/AddressType is reserved for future use."] pub fn is_reserved (& self) -> bool { self . prefix > 16384 || matches ! (self . prefix , 46u16 | 47u16) } # [doc = r" A custom format is one that is not already known."] pub fn is_custom (& self) -> bool { ! matches ! (self . prefix , 0u16 ..= 26u16 | 28u16 ..= 50u16 | 55u16 ..= 55u16 | 63u16 ..= 63u16 | 65u16 ..= 69u16 | 73u16 ..= 73u16 | 77u16 ..= 78u16 | 88u16 ..= 88u16 | 98u16 ..= 99u16 | 101u16 ..= 101u16 | 105u16 ..= 105u16 | 110u16 ..= 110u16 | 113u16 ..= 113u16 | 128u16 ..= 128u16 | 136u16 ..= 136u16 | 172u16 ..= 172u16 | 252u16 ..= 252u16 | 255u16 ..= 255u16 | 268u16 ..= 268u16 | 1110u16 ..= 1110u16 | 1284u16 ..= 1285u16 | 2007u16 ..= 2007u16 | 2032u16 ..= 2032u16 | 2092u16 ..= 2092u16 | 2254u16 ..= 2254u16 | 6094u16 ..= 6094u16 | 10041u16 ..= 10041u16 | 11330u16 ..= 11331u16 | 11820u16 ..= 11820u16) } }