mtag

package
v0.0.0-...-52c4d39 Latest Latest
Warning

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

Go to latest
Published: May 4, 2016 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetLabelEN

func GetLabelEN(v interface{}, fieldName string) string

GetLabelEN

func GetLabelTag

func GetLabelTag(v interface{}, fieldName string) (string, bool)

GetLabelTag returns field "label" tag value.

func GetLabelZH

func GetLabelZH(v interface{}, fieldName string) string

GetLabelZH

func GetLocaleLabel

func GetLocaleLabel(v interface{}, fieldName string, locale string) string

GetLocaleLabel returns field label by locale. locale format: en en_US / zh zh_CN zh_HK etc.

func GetTag

func GetTag(v interface{}, fieldName string, tag string) (string, bool)

GetTag returns tag string v should be struct, pointer or array(slice) if field not exists, returns "" and false.

func ParseKeyValueMap

func ParseKeyValueMap(value string) map[string]string

parse string to KeyValue map.

Types

This section is empty.

Directories

Path Synopsis
demo

Jump to

Keyboard shortcuts

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