property

package
v0.0.623 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2026 License: Apache-2.0 Imports: 2 Imported by: 61 modules, 1,055 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type List

type List []Property

func BuildList

func BuildList(rawProperties []interface{}) (List, error)

BuildList creates a new property List from an slice of interface{}, erroring if any elements are maps with non-string keys. Slices in the property List are converted to property Lists. Maps in the property List are converted to property Maps.

type Map

type Map map[string]Property

func BuildMap

func BuildMap(rawProperties map[interface{}]interface{}) (Map, error)

BuildMap creates a new string keyed map from an interface{}-keyed map, erroring if a key is not a string

func (*Map) UnmarshalYAML

func (m *Map) UnmarshalYAML(unmarshal func(interface{}) error) error

type Property

type Property interface{}

Property represents a constrained value which can be a Map, a List, or a primitive. If the property is a Map, keys must be strings and values are properties. These constraints are only enforced by the builder functions: Build, BuildMap, and BuildList.

func Build

func Build(val interface{}) (Property, error)

Build creates a generic property that may be a Map, List or primitive. If it is a Map or List it will be built using the appropriate builder and constraints.

Jump to

Keyboard shortcuts

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