config

package
v1.5.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 7, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IAddress

type IAddress interface {
	GetInterface() string
	GetIncoming() string
}

type IConfig

type IConfig interface {
	GetAddress() IAddress
	GetLogging() logger.ILogging
	GetConnection() IConnection
	GetStorageKey() string
}

func BuildConfig added in v1.5.6

func BuildConfig(pFilepath string, pCfg *SConfig) (IConfig, error)

func InitConfig added in v1.5.8

func InitConfig(cfgPath string, initCfg *SConfig) (IConfig, error)

func LoadConfig

func LoadConfig(pFilepath string) (IConfig, error)

type IConnection

type IConnection interface {
	GetService() string
	GetTraffic() string
}

type SAddress

type SAddress struct {
	FInterface string `json:"interface"`
	FIncoming  string `json:"incoming"`
}

func (*SAddress) GetIncoming added in v1.5.6

func (p *SAddress) GetIncoming() string

func (*SAddress) GetInterface added in v1.5.6

func (p *SAddress) GetInterface() string

type SConfig

type SConfig struct {
	FLogging    []string     `json:"logging,omitempty"`
	FAddress    *SAddress    `json:"address"`
	FConnection *SConnection `json:"connection"`
	FStorageKey string       `json:"storage_key,omitempty"`
	// contains filtered or unexported fields
}

func (*SConfig) GetAddress added in v1.5.6

func (p *SConfig) GetAddress() IAddress

func (*SConfig) GetConnection added in v1.5.6

func (p *SConfig) GetConnection() IConnection

func (*SConfig) GetLogging added in v1.5.6

func (p *SConfig) GetLogging() logger.ILogging

func (*SConfig) GetStorageKey added in v1.5.6

func (p *SConfig) GetStorageKey() string

type SConnection

type SConnection struct {
	FService string `json:"service"`
	FTraffic string `json:"traffic,omitempty"`
}

func (*SConnection) GetService added in v1.5.6

func (p *SConnection) GetService() string

func (*SConnection) GetTraffic added in v1.5.6

func (p *SConnection) GetTraffic() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL