tag

package
v1.2.117 Latest Latest
Warning

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

Go to latest
Published: May 13, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Tag

func Tag(v any, tagHandler func(val reflect.Value, tag reflect.StructTag) error) error

Convert wrapper of convertState

Types

type Tagger

type Tagger interface {
	TagDefault() error
}

Tagger is the interface implemented by types that can marshal themselves into valid JSON.

type TaggerError

type TaggerError struct {
	Type reflect.Type
	Err  error
}

func (*TaggerError) Error

func (e *TaggerError) Error() string

type UnsupportedTypeError

type UnsupportedTypeError struct {
	Type reflect.Type
}

An UnsupportedTypeError is returned by Marshal when attempting to handle an unsupported structTag type.

func (*UnsupportedTypeError) Error

func (e *UnsupportedTypeError) Error() string

type UnsupportedValueError

type UnsupportedValueError struct {
	Value reflect.Value
	Str   string
}

func (*UnsupportedValueError) Error

func (e *UnsupportedValueError) Error() string

Jump to

Keyboard shortcuts

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