setting

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppSettingS

type AppSettingS struct {
	DefaultPageSize       int
	MaxPageSize           int
	LogSavePath           string
	LogFileName           string
	LogFileExt            string
	UploadSavePath        string
	UploadServerUrl       string
	UploadImageMaxSize    int
	UploadImageAllowExts  []string
	DefaultContextTimeout time.Duration
	HashSalt              string
}

type CacheSettingS

type CacheSettingS struct {
	Host    string
	DBIndex int
}

type ClientSettingS

type ClientSettingS struct {
	RPCHost string
	ConnNum int
}

type DatabaseSettingS

type DatabaseSettingS struct {
	DBType       string
	UserName     string
	Password     string
	Host         string
	DBName       string
	TablePrefix  string
	Charset      string
	ParseTime    bool
	MaxIdleConns int
	MaxOpenConns int
}

type EmailSettingS

type EmailSettingS struct {
	Host     string
	Port     int
	UserName string
	Password string
	IsSSL    bool
	From     string
	To       []string
}

type ServerSettingS

type ServerSettingS struct {
	RunMode      string
	HttpPort     string
	RPCPort      string
	ReadTimeout  time.Duration
	WriteTimeout time.Duration
}

type Setting

type Setting struct {
	// contains filtered or unexported fields
}

func NewSetting

func NewSetting(configs ...string) (*Setting, error)

func (*Setting) ReadSection

func (s *Setting) ReadSection(k string, v interface{}) error

Jump to

Keyboard shortcuts

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