i18n

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type I18N

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

func NewI18N

func NewI18N(defaultTag string, lang map[string]Lang) *I18N

type Lang

type Lang map[string]string

func LoadFileParseLanguage

func LoadFileParseLanguage(filename string) (lang Lang, err error)

type Locale

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

func NewLocale

func NewLocale(bundle *I18N, lang string) (locale *Locale, err error)

func (*Locale) Translate

func (locale *Locale) Translate(id string) string

Jump to

Keyboard shortcuts

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