options

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2024 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Database

type Database struct {
	Cache            *bool   `hcl:"cache"`
	CacheMaxTtl      *int    `hcl:"cache_max_ttl"`
	CacheMaxSizeMb   *int    `hcl:"cache_max_size_mb"`
	Listen           *string `hcl:"listen"`
	Port             *int    `hcl:"port"`
	SearchPath       *string `hcl:"search_path"`
	SearchPathPrefix *string `hcl:"search_path_prefix"`
	StartTimeout     *int    `hcl:"start_timeout"`
}

func (*Database) ConfigMap

func (d *Database) ConfigMap() map[string]interface{}

ConfigMap creates a config map that can be merged with viper

func (*Database) Merge

func (d *Database) Merge(otherOptions options.Options)

Merge :: merge other options over the the top of this options object i.e. if a property is set in otherOptions, it takes precedence

func (*Database) String

func (d *Database) String() string

type General

type General struct {
	UpdateCheck *string `hcl:"update_check" cty:"update_check"`
	MaxParallel *int    `hcl:"max_parallel" cty:"max_parallel"`
	Telemetry   *string `hcl:"telemetry" cty:"telemetry"`
	LogLevel    *string `hcl:"log_level" cty:"log_level"`
	MemoryMaxMb *int    `hcl:"memory_max_mb" cty:"memory_max_mb"`
}

func (*General) ConfigMap

func (g *General) ConfigMap() map[string]interface{}

ConfigMap creates a config map that can be merged with viper

func (*General) Merge

func (g *General) Merge(otherOptions options.Options)

Merge merges other options over the top of this options object i.e. if a property is set in otherOptions, it takes precedence

func (*General) SetBaseProperties

func (g *General) SetBaseProperties(otherOptions options.Options)

TODO KAI what is the difference between merge and SetBaseProperties

func (*General) String

func (g *General) String() string

type Plugin

type Plugin struct {
	MemoryMaxMb  *int `hcl:"memory_max_mb"`
	StartTimeout *int `hcl:"start_timeout"`
}

func (*Plugin) ConfigMap

func (t *Plugin) ConfigMap() map[string]interface{}

ConfigMap creates a config map that can be merged with viper

func (*Plugin) Merge

func (t *Plugin) Merge(otherOptions options.Options)

Merge merges other options over the top of this options object i.e. if a property is set in otherOptions, it takes precedence

func (*Plugin) String

func (t *Plugin) String() string

Jump to

Keyboard shortcuts

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