api

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2020 License: Apache-2.0 Imports: 2 Imported by: 8

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Signals = make(chan os.Signal, 1)

Signals is a channel for processing OS signals such as SIGHUP.

Functions

This section is empty.

Types

type PluginStartupContext

type PluginStartupContext struct {
	// nginx-wrapper runtime settings
	Settings Settings
}

PluginStartupContext is a data structure passed to each plugin's Start() function. It provides key data needed for plugins to function and references to functions needed for integration.

type Settings

type Settings interface {
	AllKeys() []string
	AllSettings() map[string]interface{}
	Get(string) interface{}
	GetBool(key string) bool
	GetDuration(key string) time.Duration
	GetFloat64(key string) float64
	GetInt(key string) int
	GetInt32(key string) int32
	GetInt64(key string) int64
	GetIntSlice(key string) []int
	GetSizeInBytes(key string) uint
	GetString(key string) string
	GetStringMap(key string) map[string]interface{}
	GetStringMapString(key string) map[string]string
	GetStringMapStringSlice(key string) map[string][]string
	GetStringSlice(key string) []string
	GetTime(key string) time.Time
	GetUint(key string) uint
	GetUint32(key string) uint32
	GetUint64(key string) uint64
	IsSet(key string) bool
	RegisterAlias(alias string, key string)
	Set(key string, value interface{})
	SetDefault(key string, value interface{})
}

Settings is an interface containing a subset of the methods available in Viper.

Jump to

Keyboard shortcuts

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