Documentation ¶
Index ¶
- Constants
- func RegisterBech32Prefix()
- func RegisterNativeCoinUnits()
- type BaseConfig
- type Config
- type ConsensusConfig
- type Description
- type GenAccount
- type GenesisUpdater
- type GenesisUpdaters
- type Key
- type KeyStorage
- type NetConfig
- type RPCConfig
- type TxIndexConfig
- type ValNodeConfig
- type Validator
- type ValidatorInfo
- type ValidatorKey
Constants ¶
View Source
const ( DARC = "darc" // 1 (base denom unit) MDARC = "mdarc" // 10^-3 (milli) UDARC = "udarc" // 10^-6 (micro) NDARC = "ndarc" // 10^-9 (nano) PDARC = "pdarc" // 10^-12 (pico) FDARC = "fdarc" // 10^-15 (femto) ADARC = "adarc" // 10^-18 (atto) KNSTL = "knstl" // 1 (base denom unit) MKNSTL = "mknstl" // 10^-3 (milli) UKNSTL = "uknstl" // 10^-6 (micro) NKNSTL = "nknstl" // 10^-9 (nano) PKNSTL = "pknstl" // 10^-12 (pico) FKNSTL = "fknstl" // 10^-15 (femto) AKNSTL = "aknstl" // 10^-18 (atto) DefaultBondDenom = UDARC StakeDenom = UDARC DefaultConsensusPower = 100000 )
View Source
const ( // Bech32PrefixAccAddr defines the Bech32 prefix of an account's address Bech32MainPrefix = "darc" // PrefixValidator is the prefix for validator keys PrefixValidator = "val" // PrefixConsensus is the prefix for consensus keys PrefixConsensus = "cons" // PrefixPublic is the prefix for public keys PrefixPublic = "pub" // PrefixOperator is the prefix for operator keys PrefixOperator = "oper" // Bech32PrefixAccAddr defines the Bech32 prefix of an account's address Bech32PrefixAccAddr = Bech32MainPrefix // Bech32PrefixAccPub defines the Bech32 prefix of an account's public key Bech32PrefixAccPub = Bech32MainPrefix + PrefixPublic // Bech32PrefixValAddr defines the Bech32 prefix of a validator's operator address Bech32PrefixValAddr = Bech32MainPrefix + PrefixValidator + PrefixOperator // Bech32PrefixValPub defines the Bech32 prefix of a validator's operator public key Bech32PrefixValPub = Bech32MainPrefix + PrefixValidator + PrefixOperator + PrefixPublic // Bech32PrefixConsAddr defines the Bech32 prefix of a consensus node address Bech32PrefixConsAddr = Bech32MainPrefix + PrefixValidator + PrefixConsensus // Bech32PrefixConsPub defines the Bech32 prefix of a consensus node public key Bech32PrefixConsPub = Bech32MainPrefix + PrefixValidator + PrefixConsensus + PrefixPublic )
Variables ¶
This section is empty.
Functions ¶
func RegisterBech32Prefix ¶
func RegisterBech32Prefix()
func RegisterNativeCoinUnits ¶
func RegisterNativeCoinUnits()
Types ¶
type BaseConfig ¶
type BaseConfig struct { }
BaseConfig defines the base configuration for a Tendermint node
type Config ¶
type Config struct { // Top level options use an anonymous struct BaseConfig `mapstructure:",squash"` // Options for services RPC *RPCConfig `mapstructure:"rpc" json:"rpc"` Consensus *ConsensusConfig `mapstructure:"consensus" json:"consensus"` TxIndex *TxIndexConfig `mapstructure:"tx_index" json:"tx_index"` }
type ConsensusConfig ¶
type ConsensusConfig struct { TimeoutCommit time.Duration `json:"timeout_commit" mapstructure:"timeout_commit"` // EmptyBlocks mode and possible interval between empty blocks CreateEmptyBlocks bool `json:"create_empty_blocks" mapstructure:"create_empty_blocks"` CreateEmptyBlocksInterval time.Duration `json:"create_empty_blocks_interval" mapstructure:"create_empty_blocks_interval"` }
ConsensusConfig defines the configuration for the Tendermint consensus service, including timeouts and details about the WAL and the block structure.
type Description ¶
type GenAccount ¶
type GenesisUpdater ¶
type GenesisUpdater interface { Name() string UpdateGenesis(cdc codec.JSONMarshaler, appState map[string]json.RawMessage) }
GenesisUpdater is the standard form for an application module
type GenesisUpdaters ¶
type GenesisUpdaters map[string]GenesisUpdater
collections of GenesisUpdater
func NewGenesisUpdaters ¶
func NewGenesisUpdaters(updaters ...GenesisUpdater) GenesisUpdaters
type Key ¶
type Key struct { Name string `json:"name"` Password string `json:"password"` Mnemonic string `json:"mnemonic"` }
func (*Key) GetMnemonic ¶
func (*Key) GetPassword ¶
type KeyStorage ¶
type NetConfig ¶
type NetConfig struct { Type string `json:"type"` // localnet,testnet GlobalConfig *Config `json:"config"` GenAccounts []*GenAccount `json:"gen_accounts"` Validators []*ValidatorInfo `json:"validators"` }
type RPCConfig ¶
type RPCConfig struct { // TCP or UNIX socket address for the RPC server to listen on ListenAddress string `json:"laddr" mapstructure:"laddr"` // A list of origins a cross-domain request can be executed from. // If the special '*' value is present in the list, all origins will be allowed. // An origin may contain a wildcard (*) to replace 0 or more characters (i.e.: http://*.domain.com). // Only one wildcard can be used per origin. CORSAllowedOrigins []string `json:"cors_allowed_origins" mapstructure:"cors_allowed_origins"` }
RPCConfig defines the configuration options for the Tendermint RPC server
type TxIndexConfig ¶
type TxIndexConfig struct { // Comma-separated list of tags to index (by default the only tag is "tx.hash") // // You can also index transactions by height by adding "tx.height" tag here. // // It's recommended to index only a subset of tags due to possible memory // bloat. This is, of course, depends on the indexer's DB and the volume of // transactions. IndexTags string `json:"index_tags" mapstructure:"index_tags"` // When set to true, tells indexer to index all tags (predefined tags: // "tx.hash", "tx.height" and all tags from DeliverTx responses). // // Note this may be not desirable (see the comment above). IndexTags has a // precedence over IndexAllTags (i.e. when given both, IndexTags will be // indexed). IndexAllTags bool `json:"index_all_tags" mapstructure:"index_all_tags"` }
TxIndexConfig defines the configuration for the transaction indexer, including tags to index.
type ValNodeConfig ¶
type Validator ¶
type Validator struct { ValNodeConfig ValNodeConfig Index int ChainID string Moniker string ID string GenFile string GenAccount *authTypes.GenesisAccount Memo string Cors string ValPubKey cryptotypes.PubKey IP string Key ValidatorKey Description Description }
type ValidatorInfo ¶
type ValidatorInfo struct { Name string `json:"name"` IP string `json:"ip"` Index int `json:"index"` Cors string `json:"cors"` Faucet bool `json:"faucet"` Key ValidatorKey `json:"key"` Description Description `json:"description"` Config *Config `json:"config"` }
type ValidatorKey ¶
type ValidatorKey struct { Address string `json:"address"` AccAddr types.AccAddress `json:"-"` PublicKey []byte `json:"-"` CoinDelegate int64 `json:"coin_delegate"` }
Click to show internal directories.
Click to hide internal directories.