Documentation
¶
Index ¶
- func NewDecoder(r io.Reader) grows.Decoder
- func Open(v any, filename string) error
- func OpenFS(v any, fsys fs.FS, filename string) error
- func OpenFiles(v any, filenames []string) error
- func OpenFilesFS(v any, fsys fs.FS, filenames []string) error
- func OpenFromPaths(obj any, file string, paths []string) error
- func Read(v any, reader io.Reader) error
- func ReadBytes(v any, data []byte) error
- func Save(v any, filename string) error
- func Write(v any, writer io.Writer) error
- func WriteBytes(v any) ([]byte, error)
- type Decoder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func OpenFS ¶
OpenFS reads the given object from the given filename using TOML encoding, using the given fs.FS filesystem (e.g., for embed files)
func OpenFiles ¶ added in v0.3.1
OpenFiles reads the given object from the given filenames using TOML encoding
func OpenFilesFS ¶ added in v0.3.1
OpenFilesFS reads the given object from the given filenames using TOML encoding, using the given fs.FS filesystem (e.g., for embed files)
func OpenFromPaths ¶ added in v0.3.20
OpenFromPaths reads object from given TOML file, looking on paths for the file.
func WriteBytes ¶
WriteBytes writes the given object, returning bytes of the encoding, using TOML encoding
Types ¶
type Decoder ¶
Decoder is needed to return a standard Decode function signature for toml. Just wraps toml.Decoder to satisfy our grows.Decoder interface. Should not need to use in your code.