Documentation ¶
Index ¶
- Constants
- func ChangeKey(file string, key string, value string) (err error)
- func LoadYamlConfig(file string, typeName string, elements interface{}) error
- func SaveYamlConfig(file string, elements interface{}) error
- type AccountRepo
- func (r *AccountRepo) AccountExists(name string) (bool, error)
- func (r *AccountRepo) AddAccount(a types.Account) error
- func (r *AccountRepo) GetAccount(name string) (types.Account, error)
- func (r *AccountRepo) GetCurrentAccount() (types.Account, error)
- func (r *AccountRepo) GetNextName() string
- func (r *AccountRepo) ListAccounts() ([]types.Account, error)
- type ChainRepo
- type ContractRepo
- type YamlConfig
Constants ¶
View Source
const (
DefaultAccountFile = ".accounts.yaml"
)
View Source
const DefaultContractFile = ".contracts.yaml"
Variables ¶
This section is empty.
Functions ¶
func LoadYamlConfig ¶
func SaveYamlConfig ¶
Types ¶
type AccountRepo ¶
func NewAccountRepo ¶
func NewAccountRepo(selected string) (*AccountRepo, error)
func (*AccountRepo) AccountExists ¶
func (r *AccountRepo) AccountExists(name string) (bool, error)
func (*AccountRepo) AddAccount ¶
func (r *AccountRepo) AddAccount(a types.Account) error
func (*AccountRepo) GetAccount ¶
func (r *AccountRepo) GetAccount(name string) (types.Account, error)
func (*AccountRepo) GetCurrentAccount ¶
func (r *AccountRepo) GetCurrentAccount() (types.Account, error)
func (*AccountRepo) GetNextName ¶
func (r *AccountRepo) GetNextName() string
func (*AccountRepo) ListAccounts ¶
func (r *AccountRepo) ListAccounts() ([]types.Account, error)
type ChainRepo ¶
type ChainRepo struct { Chains []types.ChainConfig ConfigFile string Selected string }
func NewChainRepo ¶
func (*ChainRepo) GetCurrentChain ¶
func (c *ChainRepo) GetCurrentChain() (types.ChainConfig, error)
func (*ChainRepo) ListChains ¶
func (c *ChainRepo) ListChains() ([]types.ChainConfig, error)
type ContractRepo ¶
func NewContractRepo ¶
func NewContractRepo(selected string, abi string, all bool) (*ContractRepo, error)
func (ContractRepo) AddContract ¶
func (c ContractRepo) AddContract(contract types.Contract) error
func (ContractRepo) GetContract ¶
func (c ContractRepo) GetContract(name string) (types.Contract, error)
func (ContractRepo) GetCurrentContract ¶
func (c ContractRepo) GetCurrentContract() (types.Contract, error)
func (ContractRepo) ListContracts ¶
func (c ContractRepo) ListContracts() ([]*types.Contract, error)
type YamlConfig ¶
type YamlConfig struct {
File string
}
Click to show internal directories.
Click to hide internal directories.