confgroup

package
v0.57.2 Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2023 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

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

func NewCache

func NewCache() *Cache

func (*Cache) Add

func (c *Cache) Add(group *Group) (added, removed []Config)

type Config

type Config map[string]interface{}

func (Config) Apply

func (c Config) Apply(def Default)

func (Config) AutoDetectionRetry

func (c Config) AutoDetectionRetry() int

func (Config) FullName

func (c Config) FullName() string

func (Config) Hash

func (c Config) Hash() uint64

func (Config) HashIncludeMap

func (c Config) HashIncludeMap(_ string, k, _ interface{}) (bool, error)

func (Config) Labels

func (c Config) Labels() map[any]any

func (Config) Module

func (c Config) Module() string

func (Config) Name

func (c Config) Name() string

func (Config) NameWithHash

func (c Config) NameWithHash() string

func (Config) Priority

func (c Config) Priority() int

func (Config) Provider

func (c Config) Provider() string

func (Config) SetModule

func (c Config) SetModule(v string)

func (Config) SetName

func (c Config) SetName(v string)

func (Config) SetProvider

func (c Config) SetProvider(v string)

func (Config) SetSource

func (c Config) SetSource(v string)

func (Config) Source

func (c Config) Source() string

func (Config) UpdateEvery

func (c Config) UpdateEvery() int

func (Config) Vnode

func (c Config) Vnode() string

type Default

type Default struct {
	MinUpdateEvery     int `yaml:"-"`
	UpdateEvery        int `yaml:"update_every"`
	AutoDetectionRetry int `yaml:"autodetection_retry"`
	Priority           int `yaml:"priority"`
}

type Group

type Group struct {
	Configs []Config
	Source  string
}

type Registry

type Registry map[string]Default

func (Registry) Lookup

func (r Registry) Lookup(name string) (Default, bool)

func (Registry) Register

func (r Registry) Register(name string, def Default)

Jump to

Keyboard shortcuts

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