Documentation ¶
Index ¶
- type Localizer
- type PoeditorSource
- type SimpleLocalizer
- func (l *SimpleLocalizer) LoadBucketFromFile(bucket string, path string, append bool)
- func (l *SimpleLocalizer) LoadBucketFromMap(bucket string, pairs map[string]string, append bool)
- func (l *SimpleLocalizer) Localize(bucket string, key string) (string, error)
- func (l *SimpleLocalizer) PullBucketFromSource(bucket string, append bool) (err error)
- func (l *SimpleLocalizer) PushBucketToSource(bucket string) (err error)
- func (l *SimpleLocalizer) SaveBucketToFile(bucket string, path string)
- type Source
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Localizer ¶
type Localizer interface { Localize(bucket string, key string) (string, error) LoadBucketFromFile(bucket string, path string, append bool) LoadBucketFromMap(bucket string, pairs map[string]string, append bool) SaveBucketToFile(bucket string, path string) PushBucketToSource(bucket string) (err error) PullBucketFromSource(bucket string, append bool) (err error) }
type PoeditorSource ¶
type PoeditorSource struct {
// contains filtered or unexported fields
}
func NewPoeditorSource ¶
func NewPoeditorSource(apiKey string, projectId string, language string) *PoeditorSource
func (*PoeditorSource) Push ¶
func (l *PoeditorSource) Push(terms []string) (err error)
type SimpleLocalizer ¶
type SimpleLocalizer struct {
// contains filtered or unexported fields
}
func NewSimpleLocalizer ¶
func NewSimpleLocalizer(source *PoeditorSource) *SimpleLocalizer
func (*SimpleLocalizer) LoadBucketFromFile ¶
func (l *SimpleLocalizer) LoadBucketFromFile(bucket string, path string, append bool)
func (*SimpleLocalizer) LoadBucketFromMap ¶
func (l *SimpleLocalizer) LoadBucketFromMap(bucket string, pairs map[string]string, append bool)
func (*SimpleLocalizer) Localize ¶
func (l *SimpleLocalizer) Localize(bucket string, key string) (string, error)
func (*SimpleLocalizer) PullBucketFromSource ¶
func (l *SimpleLocalizer) PullBucketFromSource(bucket string, append bool) (err error)
func (*SimpleLocalizer) PushBucketToSource ¶
func (l *SimpleLocalizer) PushBucketToSource(bucket string) (err error)
func (*SimpleLocalizer) SaveBucketToFile ¶
func (l *SimpleLocalizer) SaveBucketToFile(bucket string, path string)
Click to show internal directories.
Click to hide internal directories.