Documentation ¶
Index ¶
- Constants
- func CreateCookie(w http.ResponseWriter, localization string, cy core.Cypher) error
- func ReadCookie(req *http.Request, cy core.Cypher) (string, error)
- type Localizer
- type Store
- func (ls Store) CreateCookie(w http.ResponseWriter, localization string) error
- func (ls Store) Get(key, language string) Localizer
- func (ls Store) GetLocalizedError(err core.UseCaseError, req *http.Request) string
- func (ls Store) GetUsingRequest(key string, req *http.Request) Localizer
- func (ls Store) GetUsingRequestWithoutShared(key string, req *http.Request) Localizer
- func (ls Store) GetWithoutShared(key, language string) Localizer
- func (ls Store) LoadIntoField(field **Localizer, key string, language string)
- func (ls Store) LoadIntoFieldUsingRequest(field **Localizer, key string, req *http.Request)
- func (ls Store) ReadCookie(req *http.Request) string
Constants ¶
View Source
const ContextKey string = "phx_localization"
Variables ¶
This section is empty.
Functions ¶
func CreateCookie ¶
Types ¶
type Store ¶ added in v0.5.0
type Store struct {
// contains filtered or unexported fields
}
func NewLocalizerStore ¶
func (Store) CreateCookie ¶ added in v0.5.0
func (ls Store) CreateCookie(w http.ResponseWriter, localization string) error
func (Store) GetLocalizedError ¶ added in v0.5.0
func (Store) GetUsingRequest ¶ added in v0.5.0
func (Store) GetUsingRequestWithoutShared ¶ added in v0.5.0
func (Store) GetWithoutShared ¶ added in v0.5.0
func (Store) LoadIntoField ¶ added in v0.5.0
func (Store) LoadIntoFieldUsingRequest ¶ added in v0.5.0
Click to show internal directories.
Click to hide internal directories.