values

package
v0.7.14 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AsMap

func AsMap(vs *Values) map[string]any

AsMap returns a flat map of all resolved values across all sections. It wraps vs.GetDataMap().

func DecodeInto

func DecodeInto(v *SectionValues, dst any) error

DecodeInto decodes resolved values from a single section into the destination struct. It wraps v.InitializeStruct(dst).

func DecodeSectionInto

func DecodeSectionInto(vs *Values, sectionSlug string, dst any) error

DecodeSectionInto decodes resolved values from a specific section (by slug) into the destination struct. It wraps vs.InitializeStruct(sectionSlug, dst).

Types

type SectionValues

type SectionValues = layers.ParsedLayer

SectionValues is a type alias for layers.ParsedLayer. SectionValues contains resolved values for a single schema section.

type Values

type Values = layers.ParsedLayers

Values is a type alias for layers.ParsedLayers. Values contains resolved values for all schema sections.

func New

func New(options ...ValuesOption) *Values

New creates a new collection of resolved values. It wraps layers.NewParsedLayers.

type ValuesOption

type ValuesOption = layers.ParsedLayersOption

ValuesOption is a type alias for layers.ParsedLayersOption. ValuesOption configures a Values collection during construction.

func WithSectionValues

func WithSectionValues(slug string, v *SectionValues) ValuesOption

WithSectionValues returns a ValuesOption that adds a section's values to a Values collection. It wraps layers.WithParsedLayer.

Jump to

Keyboard shortcuts

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