Documentation
¶
Index ¶
- func JSONDecode(content []byte, destinations ...interface{}) (interface{}, error)
- func JSONEncode(source interface{}, unescape bool) ([]byte, error)
- func JSONFormatToReadable(source []byte) ([]byte, error)
- func StringToTime(timeString, format string) (time.Time, error)
- func StringToUnixInt(timeString, format string) int
- func TimeToString(timeValue time.Time, format string) string
- func YAMLDecode(content []byte, destinations ...interface{}) (interface{}, error)
- func YAMLEncode(source interface{}) ([]byte, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func JSONDecode ¶
JSONDecode decode given json byte slice to corresponding struct.
func JSONEncode ¶
JSONEncode encode given interface to json byte slice.
func JSONFormatToReadable ¶
JSONFormatToReadable formats given json byte slice prettily.
func StringToTime ¶
StringToTime transforms given string to time.
func StringToUnixInt ¶
StringToUnixInt transforms given string to unix time int.
func TimeToString ¶
TimeToString transforms given time to string.
func YAMLDecode ¶
YAMLDecode decode given yaml byte slice to corresponding struct.
func YAMLEncode ¶
YAMLEncode encode given interface to yaml byte slice.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.