Versions in this module Expand all Collapse all v0 v0.0.1 Mar 30, 2024 Changes in this version + var ErrEmptyKeySep = fmt.Errorf("empty key separator") + var ErrEmptySliceSep = fmt.Errorf("empty slice separator") + var ErrorEmptyTag = fmt.Errorf("empty tag name") + func Unmarshal(kv KV, v any) error + func UnmarshalContext(ctx context.Context, kv KV, v any) error + type Decoder struct + func NewDecoder(kv KV, opts ...DecoderOption) (*Decoder, error) + func (d *Decoder) Decode(v any) error + func (d *Decoder) DecodeContext(ctx context.Context, v any) error + type DecoderOption func(*decoderConfig) error + func WithPrefix(prefix string) DecoderOption + func WithSeparator(separator string) DecoderOption + func WithSliceSeparator(separator string) DecoderOption + func WithTag(tag string) DecoderOption + type KV interface + Get func(ctx context.Context, key string) (Value, error) + type MapKV map[string]string + func (m MapKV) Get(ctx context.Context, key string) (Value, error) + type Scanner interface + Scan func(v any) error + type StringValue struct + func NewBytesValue(value []byte) StringValue + func NewStringValue(value string) StringValue + func (v StringValue) UnmarshalTo(out any, opts ValueUnmarshalOpts) error + type Value interface + UnmarshalTo func(out any, opts ValueUnmarshalOpts) error + var NullValue Value = nullValue{} + type ValueUnmarshalOpts struct + SliceSep string