language

package
v0.0.0-...-3444db6 Latest Latest
Warning

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

Go to latest
Published: Jul 23, 2020 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Language

type Language struct {
	// contains filtered or unexported fields
}

func New

func New(dir string, def interface{}, defname string) Language

New creates a new language instance and adds all existing language files from a given path

func (*Language) ListNames

func (l *Language) ListNames() []string

ListNames returns a list of all language files

func (*Language) LoadLangFiles

func (l *Language) LoadLangFiles() error

LoadLangFiles adds all existing language files from a given path

func (*Language) SaveLang

func (l *Language) SaveLang(lf interface{}, name string) error

SaveLang saves a language struct as file

func (*Language) SelectLang

func (l *Language) SelectLang(name string, s interface{}) error

SelectLang parses a language file to struct

Jump to

Keyboard shortcuts

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