Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidKind = errors.New("invalid kind")
ErrInvalidKind for marshaller.
View Source
var Module = fx.Options( fx.Provide(NewProto), fx.Provide(NewJSON), fx.Provide(NewTOML), fx.Provide(NewYAML), fx.Provide(NewFactory), )
Module for fx.
Functions ¶
This section is empty.
Types ¶
type Factory ¶ added in v1.79.0
type Factory struct {
// contains filtered or unexported fields
}
Factory of marshaller.
func (*Factory) Create ¶ added in v1.79.0
func (f *Factory) Create(kind string) (Marshaller, error)
Create from kind.
func (*Factory) Register ¶ added in v1.156.0
func (f *Factory) Register(kind string, m Marshaller)
Register kind and marshaller.
type Marshaller ¶
Marshaller allows to have different ways to marshal/unmarshal.
Click to show internal directories.
Click to hide internal directories.