Documentation
¶
Index ¶
- Constants
- type Confile
- func (c *Confile) Parse(fpath string) error
- func (c *Confile) ReadBootnodes() []string
- func (c *Confile) ReadEarningsAcc() string
- func (c *Confile) ReadMnemonic() string
- func (c *Confile) ReadPriorityTeeList() []string
- func (c *Confile) ReadRpcEndpoints() []string
- func (c *Confile) ReadServicePort() int
- func (c *Confile) ReadSignatureAccount() string
- func (c *Confile) ReadSignaturePublickey() []byte
- func (c *Confile) ReadStakingAcc() string
- func (c *Confile) ReadUseCpu() uint8
- func (c *Confile) ReadUseSpace() uint64
- func (c *Confile) ReadWorkspace() string
- func (c *Confile) SetBootNodes(boot []string)
- func (c *Confile) SetEarningsAcc(earningsAcc string) error
- func (c *Confile) SetMnemonic(mnemonic string) error
- func (c *Confile) SetPriorityTeeList(tees []string)
- func (c *Confile) SetRpcAddr(rpc []string)
- func (c *Confile) SetServicePort(port int) error
- func (c *Confile) SetUseSpace(useSpace uint64)
- func (c *Confile) SetWorkspace(workspace string) error
- type Confiler
Constants ¶
View Source
const DefaultProfile = "conf.yaml"
View Source
const TempleteProfile = `` /* 647-byte string literal not displayed */
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Confile ¶
type Confile struct {
Rpc []string `name:"Rpc" toml:"Rpc" yaml:"Rpc"`
Boot []string `name:"Boot" toml:"Boot" yaml:"Boot"`
Mnemonic string `name:"Mnemonic" toml:"Mnemonic" yaml:"Mnemonic"`
StakingAcc string `name:"StakingAcc" toml:"StakingAcc" yaml:"StakingAcc"`
EarningsAcc string `name:"EarningsAcc" toml:"EarningsAcc" yaml:"EarningsAcc"`
Workspace string `name:"Workspace" toml:"Workspace" yaml:"Workspace"`
Port int `name:"Port" toml:"Port" yaml:"Port"`
UseSpace uint64 `name:"UseSpace" toml:"UseSpace" yaml:"UseSpace"`
UseCpu uint8 `name:"UseCpu" toml:"UseCpu" yaml:"UseCpu"`
TeeList []string `name:"TeeList" toml:"TeeList" yaml:"TeeList"`
}
func NewConfigFile ¶
func NewConfigFile() *Confile
func (*Confile) ReadBootnodes ¶
func (*Confile) ReadEarningsAcc ¶
func (*Confile) ReadMnemonic ¶
func (*Confile) ReadPriorityTeeList ¶
func (*Confile) ReadRpcEndpoints ¶
func (*Confile) ReadServicePort ¶
func (*Confile) ReadSignatureAccount ¶
func (*Confile) ReadSignaturePublickey ¶
func (*Confile) ReadStakingAcc ¶
func (*Confile) ReadUseCpu ¶
func (*Confile) ReadUseSpace ¶
func (*Confile) ReadWorkspace ¶
func (*Confile) SetBootNodes ¶
func (*Confile) SetEarningsAcc ¶
func (*Confile) SetMnemonic ¶
func (*Confile) SetPriorityTeeList ¶
func (*Confile) SetRpcAddr ¶
func (*Confile) SetServicePort ¶
func (*Confile) SetUseSpace ¶
func (*Confile) SetWorkspace ¶
type Confiler ¶
type Confiler interface {
Parse(fpath string) error
ReadRpcEndpoints() []string
ReadBootnodes() []string
ReadServicePort() int
ReadWorkspace() string
ReadMnemonic() string
ReadStakingAcc() string
ReadEarningsAcc() string
ReadUseSpace() uint64
ReadSignaturePublickey() []byte
ReadSignatureAccount() string
ReadUseCpu() uint8
ReadPriorityTeeList() []string
}
Click to show internal directories.
Click to hide internal directories.