Documentation
¶
Index ¶
- func GetBoolFromJPath(r io.Reader, path []interface{}) (bool, error)
- func GetIntFromJPath(r io.Reader, path []interface{}) (float64, error)
- func GetStringFromJPath(r io.Reader, path []interface{}) (string, error)
- func IsJSONValid(s string) bool
- func ToJSONByte(v interface{}) []byte
- func ToJSONString(v interface{}) string
- type JSON
- func GetJSONArrayFromJPath(r io.Reader, path []interface{}) ([]JSON, error)
- func GetJSONFromJPath(r io.Reader, path []interface{}) (JSON, error)
- func New() (newObject JSON)
- func NewFrom(m map[string]interface{}) (newObject JSON)
- func NewFromStruct(s interface{}) JSON
- func Parse(data []byte) (parsed JSON)
- func ParseJSONArrayInterface(data interface{}) []JSON
- func ParseReadCloser(rc io.ReadCloser) JSON
- func ParseString(data string) JSON
- func (jobj *JSON) Get(k string) interface{}
- func (jobj *JSON) GetAsIntArray(k string) []int
- func (jobj *JSON) GetAsStringArray(k string) []string
- func (jobj *JSON) GetBool(k string) bool
- func (jobj *JSON) GetInt(k string) int
- func (j *JSON) GetJSON(k string) JSON
- func (j *JSON) GetJSONArray(k string) []JSON
- func (j *JSON) GetJSONArrayForInfluxDB(k string) []JSON
- func (jobj *JSON) GetKeyList() []string
- func (jobj *JSON) GetString(k string) string
- func (jobj *JSON) HasKey(k string) bool
- func (json *JSON) IsJSON(key string) bool
- func (json *JSON) IsJSONArray(key string) bool
- func (jobj *JSON) Put(k string, v interface{})
- func (jobj *JSON) ToString() string
- type JSONArray
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetBoolFromJPath ¶
Get Bool
func GetIntFromJPath ¶
Get Int
func GetStringFromJPath ¶
Get String
func IsJSONValid ¶
func ToJSONByte ¶
func ToJSONByte(v interface{}) []byte
func ToJSONString ¶
func ToJSONString(v interface{}) string
Types ¶
type JSON ¶
type JSON struct {
// contains filtered or unexported fields
}
func GetJSONArrayFromJPath ¶
Get RawJSONArray
func GetJSONFromJPath ¶
Get RawJSON
func NewFromStruct ¶
func NewFromStruct(s interface{}) JSON
func ParseJSONArrayInterface ¶
func ParseJSONArrayInterface(data interface{}) []JSON
func ParseReadCloser ¶
func ParseReadCloser(rc io.ReadCloser) JSON
func ParseString ¶
func (*JSON) GetAsIntArray ¶
func (*JSON) GetAsStringArray ¶
func (*JSON) GetJSONArray ¶
func (*JSON) GetJSONArrayForInfluxDB ¶
func (*JSON) GetKeyList ¶
func (*JSON) IsJSONArray ¶
type JSONArray ¶
type JSONArray struct {
// contains filtered or unexported fields
}
func NewArrayFrom ¶
func ParseJSONArray ¶
func ParseJSONArrayReadCloser ¶
func ParseJSONArrayReadCloser(rc io.ReadCloser) JSONArray
func ParseJSONArrayString ¶
Click to show internal directories.
Click to hide internal directories.