Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( SConfig Sconfig DefaultToken = "PTN" // DefaultToken = "ABC+10A4QIWCI46V8MZJ2UO" DagConfig = DefaultConfig )
View Source
var DefaultConfig = Config{ DbPath: "./leveldb", UtxoIndex: true, MemoryUnitSize: 1280, IrreversibleHeight: 1, WhetherValidateUnitSignature: false, GenesisHash: "0xeb5f66d0289ea0af68860fd5a4d1a0b38389f598ae01008433a5ca9949fcf55c", PartitionForkUnitHeight: 0, AddrTxsIndex: false, Token721TxIndex: true, TextFileHashIndex: false, GasToken: DefaultToken, }
Functions ¶
func DefaultDataDir ¶
func DefaultDataDir() string
DefaultDataDir is the default data directory to use for the databases and other persistence requirements.
Types ¶
type Config ¶
type Config struct { DbPath string DbCache int DbHandles int // cache CacheSource string //redis RedisAddr string RedisPwd string RedisPrefix string RedisDb int // utxo UtxoIndex bool // memory unit size, unit number MemoryUnitSize uint // Irreversible height IrreversibleHeight int // Validate unit signature, just for debug version WhetherValidateUnitSignature bool // genesis hash‘s hex GenesisHash string PartitionForkUnitHeight int AddrTxsIndex bool Token721TxIndex bool TextFileHashIndex bool //当前节点选择的平台币,燃料币,必须为Asset全名 GasToken string SyncPartitionTokens []string // contains filtered or unexported fields }
global configuration of dag modules
func (*Config) GeSyncPartitionTokens ¶
func (c *Config) GetMainToken() modules.AssetId { if c.mainToken == modules.ZeroIdType16() { token, _, err := modules.String2AssetId(c.MainToken) { if err != nil { return modules.PTNCOIN } } c.mainToken = token } return c.mainToken }
func (*Config) GetGasToken ¶
Click to show internal directories.
Click to hide internal directories.