localize

package
Version: v0.0.0-...-4500e45 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2014 License: BSD-2-Clause-Views Imports: 9 Imported by: 0

Documentation

Overview

Package localize : en-US.go provides the localized messages for English in the United States

Package localize : messages.go package provides support for handling different languages and cultures

Index

Constants

This section is empty.

Variables

View Source
var EnUS = `` /* 269-byte string literal not displayed */

EnUS contains english United States translations.

View Source
var (
	// T is the translate function for the default locale
	T i18n.TranslateFunc
)

Functions

func Init

func Init(defaultLocale string) error

Init initializes the local environment

func LoadFiles

func LoadFiles(userLocale string, defaultLocal string) error

LoadFiles looks for i18n folders inside the current directory and the GOPATH to find translation files to load

func LoadJSON

func LoadJSON(userLocale string, translationDocument string) error

LoadJSON takes a json document of translations and manually loads them into the system

func NewTranslation

func NewTranslation(userLocale string, defaultLocale string) (i18n.TranslateFunc, error)

NewTranslation obtains a translation function object for the specified locales

Types

This section is empty.

Jump to

Keyboard shortcuts

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