Versions in this module Expand all Collapse all v0 v0.2.0 Dec 13, 2017 Changes in this version + func Generate(w io.Writer, pkg string, extracted *Locale, trans ...*Locale) (n int, err error) + func Rewrite(w io.Writer, goPackage string) error + type Config struct + Packages []string + SourceLanguage language.Tag + Supported []language.Tag + type Feature struct + Type string + type IDList []string + func (id *IDList) MarshalJSON() ([]byte, error) + func (id *IDList) UnmarshalJSON(b []byte) error + type Locale struct + Language language.Tag + Macros map[string]Text + Messages []Message + func Extract(c *Config) (*Locale, error) + type Message struct + Comment string + ID IDList + Key string + Meaning string + Message Text + Placeholders []Placeholder + Position string + Translation Text + TranslatorComment string + func (m *Message) Placeholder(id string) *Placeholder + func (m *Message) Substitute(msg string) (sub string, err error) + type Placeholder struct + ArgNum int + Comment string + Example string + Expr string + Features []Feature + ID string + String string + Type string + UnderlyingType string + type Select struct + Arg string + Cases map[string]Text + Feature string + type Text struct + Example string + Msg string + Select *Select + Var map[string]Text + func (t *Text) IsEmpty() bool + func (t *Text) MarshalJSON() ([]byte, error) + func (t *Text) UnmarshalJSON(b []byte) error