configuration

package
v0.0.46 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2025 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

This package provides functions to interact with configuration files.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetValueForInlineYAML added in v0.0.6

func GetValueForInlineYAML(key string, configData []byte, configStruct interface{}) (interface{}, string, error)

GetValueForInlineYAML returns the value for a key in a nested map for the provided key

func MergeWithDefault

func MergeWithDefault(defaultMap map[interface{}]interface{}, userMap map[interface{}]interface{}) map[interface{}]interface{}
MergeWithDefault merges a provided configuration with a provided default configuration.

If you have a user/app provided configuration that does not contain the full configuration, you can use this function to merge the user/app provided configuration with the default configuration.

func YAMLInlineToConfig added in v0.0.6

func YAMLInlineToConfig(configStoreKeyList, configStoreKeyTypeList []string) ([]byte, error)

YAMLInlineToConfig converts an array of strings to a usable YAML formatted []byte

func YAMLInlineToStruct added in v0.0.6

func YAMLInlineToStruct(structName string, configStoreKeyList, configStoreKeyTypeList []string) (string, error)

YAMLInlineToMap converts an array of strings to a usable struct

Types

This section is empty.

Jump to

Keyboard shortcuts

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