Documentation
¶
Index ¶
- Constants
- func ConvertStructToMap(in interface{}) map[string]interface{}
- func ConvertUint8Slice2String(u8s []uint8) string
- func CopyRequest(req *http.Request) *http.Request
- func CurTimeFormat(layout string) string
- func Decimal(val float64) float64
- func GetTimeDate(t time.Time) time.Time
- func GetTodayDate() time.Time
- func IsJSON(s string) bool
- func LoadJSONConfigFile(filename string, v interface{}) error
- func LoadYamlConfigFile(filename string, v interface{}) error
- func ParseFloat(s string) float64
- func ParseJSON(s string) map[string]interface{}
- func ParseTime(layout, value string) time.Time
- func ParseURLQuery(query string) map[string]interface{}
- func PostForm(URL string, data map[string]interface{}) (map[string]interface{}, error)
- func ToLower(v interface{})
Constants ¶
View Source
const ( // Layout1 = "2006-01-02 15:04:06" Layout1 = "2006-01-02 15:04:06" // Layout2 = "20060102" Layout2 = "20060102" )
Variables ¶
This section is empty.
Functions ¶
func ConvertStructToMap ¶
func ConvertStructToMap(in interface{}) map[string]interface{}
ConvertStructToMap convert struct value into map[string]interface{}
func ConvertUint8Slice2String ¶
ConvertUint8Slice2String ...
func CopyRequest ¶
CopyRequest means to copy a request for another handle-func or else
func CurTimeFormat ¶
CurTimeFormat get current time string format value
func LoadJSONConfigFile ¶
LoadJSONConfigFile filename string
func LoadYamlConfigFile ¶
LoadYamlConfigFile need ?
func ParseFloat ¶
ParseFloat ... parse float64's string into float64 "1.94" tobe 1.94
func ParseJSON ¶
ParseJSON parse json string to map[string]interface{}
json string like: {"a":"a","b":"b"}
func ParseURLQuery ¶
ParseURLQuery parse url query string to map[string]interface{} k=v&a=1&b=2
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.