jsons

package module
v0.0.0-...-7669540 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2021 License: GPL-3.0 Imports: 9 Imported by: 42

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func JSONDataValidate

func JSONDataValidate(data interface{}) interface{}

JSONDataValidate is convert data interface validate

Types

type JSONArray

type JSONArray struct {
	// contains filtered or unexported fields
}

JSONArray is data struct for JSONArray object

func ArrayFactory

func ArrayFactory() *JSONArray

ArrayFactory is global create a new JSONArray

func ArrayFile

func ArrayFile(pathfile string) (*JSONArray, error)

ArrayFile is load JSONArray object from file

func ArrayNew

func ArrayNew() *JSONArray

ArrayNew is global create a new JSONArray

func ArrayParse

func ArrayParse(v interface{}) (*JSONArray, error)

ArrayParse is parse from slice array to json array object

func ArrayString

func ArrayString(buffer string) (*JSONArray, error)

ArrayString is convert json array string to JSONArray object

func JSONArrayFactory

func JSONArrayFactory() *JSONArray

JSONArrayFactory is global create a new JSONArray

func JSONArrayFile

func JSONArrayFile(pathfile string) (*JSONArray, error)

JSONArrayFile is load JSONArray object from file

func JSONArrayFromFile

func JSONArrayFromFile(pathfile string) (*JSONArray, error)

JSONArrayFromFile is load JSONArray object from file

func JSONArrayFromString

func JSONArrayFromString(buffer string) (*JSONArray, error)

JSONArrayFromString is convert json array string to JSONArray object

func JSONArrayNew

func JSONArrayNew() *JSONArray

JSONArrayNew is global create a new JSONArray

func JSONArrayParse

func JSONArrayParse(v interface{}) (*JSONArray, error)

JSONArrayParse is parse from slice array to json array object

func JSONArrayString

func JSONArrayString(buffer string) (*JSONArray, error)

JSONArrayString is convert json array string to JSONArray object

func (*JSONArray) Clean

func (me *JSONArray) Clean() *JSONArray

Clean is same Clear function

func (*JSONArray) Clear

func (me *JSONArray) Clear() *JSONArray

Clear is remove all item

func (*JSONArray) Clone

func (me *JSONArray) Clone() (*JSONArray, error)

Clone is same Copy function

func (*JSONArray) Copy

func (me *JSONArray) Copy() (*JSONArray, error)

Copy is clone data myseft to a new JSONArray object

func (*JSONArray) Delete

func (me *JSONArray) Delete(index int) *JSONArray

Delete is same Remove function

func (*JSONArray) Equals

func (me *JSONArray) Equals(src *JSONArray) bool

Equals is check JSONArray equal Other JSONArray

func (*JSONArray) Factory

func (me *JSONArray) Factory() *JSONArray

Factory is create a new JSONArray object

func (*JSONArray) Fill

func (me *JSONArray) Fill(src *JSONArray) *JSONArray

Fill is merge json array data from other JSONArray object

func (*JSONArray) FromFile

func (me *JSONArray) FromFile(pathfile string) (*JSONArray, error)

FromFile is load json array data from file

func (*JSONArray) FromString

func (me *JSONArray) FromString(buffer string) (*JSONArray, error)

FromString is load json array data from string buffer

func (*JSONArray) GetArray

func (me *JSONArray) GetArray(index int) *JSONArray

GetArray is get array item from index

func (*JSONArray) GetBool

func (me *JSONArray) GetBool(index int) bool

GetBool is get string item from index

func (*JSONArray) GetDouble

func (me *JSONArray) GetDouble(index int) float64

GetDouble is get double item from index

func (*JSONArray) GetFloat

func (me *JSONArray) GetFloat(index int) float64

GetFloat is same GetDouble

func (*JSONArray) GetInt

func (me *JSONArray) GetInt(index int) int

GetInt is get int item from index

func (*JSONArray) GetNull

func (me *JSONArray) GetNull(index int) interface{}

GetNull is get null item from index

func (*JSONArray) GetObject

func (me *JSONArray) GetObject(index int) *JSONObject

GetObject is get object item from index

func (*JSONArray) GetObjectData

func (me *JSONArray) GetObjectData() *collection.ArrayList

GetObjectData is get raw data

func (*JSONArray) GetString

func (me *JSONArray) GetString(index int) string

GetString is get string item from index

func (*JSONArray) GetType

func (me *JSONArray) GetType(index int) string

GetType is get type data item

func (*JSONArray) Length

func (me *JSONArray) Length() int

Length is get size or count item of JSONArray object

func (*JSONArray) Merge

func (me *JSONArray) Merge(src *JSONArray) *JSONArray

Merge is merge myseft and other JSONArray object to a new JSONArray object

func (*JSONArray) New

func (me *JSONArray) New() *JSONArray

New is create a new JSONArray object

func (*JSONArray) PutArray

func (me *JSONArray) PutArray(value *JSONArray) *JSONArray

PutArray is put array data item

func (*JSONArray) PutBool

func (me *JSONArray) PutBool(value bool) *JSONArray

PutBool is put boolean data item

func (*JSONArray) PutDouble

func (me *JSONArray) PutDouble(value float64) *JSONArray

PutDouble is put double data item

func (*JSONArray) PutFloat

func (me *JSONArray) PutFloat(value float64) *JSONArray

PutFloat is same PutDouble function

func (*JSONArray) PutInt

func (me *JSONArray) PutInt(value int) *JSONArray

PutInt is put int data item

func (*JSONArray) PutNull

func (me *JSONArray) PutNull() *JSONArray

PutNull is put null data item

func (*JSONArray) PutObject

func (me *JSONArray) PutObject(value *JSONObject) *JSONArray

PutObject is put object data item

func (*JSONArray) PutString

func (me *JSONArray) PutString(value string) *JSONArray

PutString is put string data item

func (*JSONArray) ReadFile

func (me *JSONArray) ReadFile(pathfile string) (*JSONArray, error)

ReadFile is same FromFile function

func (*JSONArray) ReadString

func (me *JSONArray) ReadString(buffer string) (*JSONArray, error)

ReadString is same FromString function

func (*JSONArray) Remove

func (me *JSONArray) Remove(index int) *JSONArray

Remove is delete item from index

func (*JSONArray) SetObjectData

func (me *JSONArray) SetObjectData(list *collection.ArrayList) *JSONArray

SetObjectData is set raw data

func (*JSONArray) ToFile

func (me *JSONArray) ToFile(pathfile string) (int, error)

ToFile is write JSON array data to file

func (*JSONArray) ToString

func (me *JSONArray) ToString() string

ToString is convert to json array string

type JSONObject

type JSONObject struct {
	// contains filtered or unexported fields
}

JSONObject is data struct JSONObject object

func JSONObjectFactory

func JSONObjectFactory() *JSONObject

JSONObjectFactory is global create a new JSONObject object

func JSONObjectFile

func JSONObjectFile(pathfile string) (*JSONObject, error)

JSONObjectFile is load JSONObject object from file

func JSONObjectFromFile

func JSONObjectFromFile(pathfile string) (*JSONObject, error)

JSONObjectFromFile is load JSONObject object from file

func JSONObjectFromString

func JSONObjectFromString(buffer string) (*JSONObject, error)

JSONObjectFromString is convert json object string to JSONObject object

func JSONObjectNew

func JSONObjectNew() *JSONObject

JSONObjectNew is global create a new JSONObject object

func JSONObjectParse

func JSONObjectParse(v interface{}) (*JSONObject, error)

JSONObjectParse is parse from mapkey object to json object

func JSONObjectString

func JSONObjectString(buffer string) (*JSONObject, error)

JSONObjectString is convert json object string to JSONObject object

func ObjectFactory

func ObjectFactory() *JSONObject

ObjectFactory is global create a new JSONObject object

func ObjectFile

func ObjectFile(pathfile string) (*JSONObject, error)

ObjectFile is load JSONObject object from file

func ObjectNew

func ObjectNew() *JSONObject

ObjectNew is global create a new JSONObject object

func ObjectParse

func ObjectParse(v interface{}) (*JSONObject, error)

ObjectParse is parse from mapkey object to json object

func ObjectString

func ObjectString(buffer string) (*JSONObject, error)

ObjectString is convert json object string to JSONObject object

func (*JSONObject) CheckKey

func (me *JSONObject) CheckKey(key string) bool

CheckKey is same ContainsKey

func (*JSONObject) Clean

func (me *JSONObject) Clean() *JSONObject

Clean is same Clear function

func (*JSONObject) Clear

func (me *JSONObject) Clear() *JSONObject

Clear is remove all

func (*JSONObject) Clone

func (me *JSONObject) Clone() (*JSONObject, error)

Clone is same Copy function

func (*JSONObject) ContainsKey

func (me *JSONObject) ContainsKey(key string) bool

ContainsKey is check has key

func (*JSONObject) Copy

func (me *JSONObject) Copy() (*JSONObject, error)

Copy is clone data myseft to a new JSONObject object

func (*JSONObject) Delete

func (me *JSONObject) Delete(key string) *JSONObject

Delete is same Remove function

func (*JSONObject) Equals

func (me *JSONObject) Equals(src *JSONObject) bool

Equals is check JSONObject equal Other JSONObject

func (*JSONObject) Factory

func (me *JSONObject) Factory() *JSONObject

Factory is create a new JSONObject object

func (*JSONObject) Fill

func (me *JSONObject) Fill(src *JSONObject) *JSONObject

Fill is merge myseft with other JSONObject object

func (*JSONObject) FromFile

func (me *JSONObject) FromFile(pathfile string) (*JSONObject, error)

FromFile is load json object data from file

func (*JSONObject) FromString

func (me *JSONObject) FromString(buffer string) (*JSONObject, error)

FromString is load json object data from string

func (*JSONObject) GetArray

func (me *JSONObject) GetArray(key string) *JSONArray

GetArray is get array data from key

func (*JSONObject) GetBool

func (me *JSONObject) GetBool(key string) bool

GetBool is get boolean data from key

func (*JSONObject) GetDouble

func (me *JSONObject) GetDouble(key string) float64

GetDouble is get double data from key

func (*JSONObject) GetFloat

func (me *JSONObject) GetFloat(key string) float64

GetFloat is same GetDouble

func (*JSONObject) GetInt

func (me *JSONObject) GetInt(key string) int

GetInt is get int data from key

func (*JSONObject) GetKeys

func (me *JSONObject) GetKeys() []string

GetKeys is get all keys in JSONObject object

func (*JSONObject) GetNull

func (me *JSONObject) GetNull(key string) interface{}

GetNull is get null data from key

func (*JSONObject) GetObject

func (me *JSONObject) GetObject(key string) *JSONObject

GetObject is get object data from key

func (*JSONObject) GetObjectData

func (me *JSONObject) GetObjectData() *collection.MapKey

GetObjectData is get raw data

func (*JSONObject) GetString

func (me *JSONObject) GetString(key string) string

GetString is get string data from key

func (*JSONObject) GetType

func (me *JSONObject) GetType(key string) string

GetType is get data type of key

func (*JSONObject) HasKey

func (me *JSONObject) HasKey(key string) bool

HasKey is same ContainsKey

func (*JSONObject) Length

func (me *JSONObject) Length() int

Length is get size or count key of JSONObject object

func (*JSONObject) Merge

func (me *JSONObject) Merge(src *JSONObject) *JSONObject

Merge is merge myseft and other JSONObject object to a new JSONObject object

func (*JSONObject) New

func (me *JSONObject) New() *JSONObject

New is create a new JSONObject object

func (*JSONObject) PutArray

func (me *JSONObject) PutArray(key string, value *JSONArray) *JSONObject

PutArray is put array data item

func (*JSONObject) PutBool

func (me *JSONObject) PutBool(key string, value bool) *JSONObject

PutBool is put boolean data item

func (*JSONObject) PutDouble

func (me *JSONObject) PutDouble(key string, value float64) *JSONObject

PutDouble is put double data item

func (*JSONObject) PutFloat

func (me *JSONObject) PutFloat(key string, value float64) *JSONObject

PutFloat is same PutDouble function

func (*JSONObject) PutInt

func (me *JSONObject) PutInt(key string, value int) *JSONObject

PutInt is put int data item

func (*JSONObject) PutNull

func (me *JSONObject) PutNull(key string) *JSONObject

PutNull is put null data item

func (*JSONObject) PutObject

func (me *JSONObject) PutObject(key string, value *JSONObject) *JSONObject

PutObject is put object data item

func (*JSONObject) PutString

func (me *JSONObject) PutString(key string, value string) *JSONObject

PutString is put string data item

func (*JSONObject) ReadFile

func (me *JSONObject) ReadFile(pathfile string) (*JSONObject, error)

ReadFile is same FromFile function

func (*JSONObject) ReadString

func (me *JSONObject) ReadString(buffer string) (*JSONObject, error)

ReadString is same FromString function

func (*JSONObject) Remove

func (me *JSONObject) Remove(key string) *JSONObject

Remove is delete data item from key

func (*JSONObject) SetObjectData

func (me *JSONObject) SetObjectData(mapkey *collection.MapKey) *JSONObject

SetObjectData is set raw data

func (*JSONObject) ToFile

func (me *JSONObject) ToFile(pathfile string) (int, error)

ToFile to write json object data to file

func (*JSONObject) ToString

func (me *JSONObject) ToString() string

ToString is convert to json object string

Jump to

Keyboard shortcuts

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