The JSONPackage object provides the ability to merge data in a JSON object or extract data from a JSON object. Merging and extracting can occur at both the client side and the server side. The resulted JSON can be posted from the client to the server via HTTPClient, or retrieved from the server to the client via RESTClient.
For the JSON string that can be loaded by the JSONPackage object, see the section called “Supported JSON formats” in Application Techniques.
Note
It is not supported to use this object to process large data (20 MB or 100,000 data rows can be considered as large data based on our tests), because this object will call a third-party library which is memory intensive.
Note
The data to be merged can be from DataWindow, DataStore, DataWindowChild, or from an existing JSON.
Composite, Crosstab, OLE 2.0, and RichText DataWindows are unsupported.
Note
JSONPackage (as well as HTTPClient, RESTClient, CrypterObject, CoderObject, CompressorObject, DotNetAssembly, JSONGenerator, JSONParser, OAuthClient, PDF Builder objects, SMTPClient, PowerServerLabel, PowerServerResult) does not support multi-threading.
JSONPackage property |
Datatype |
Description |
---|---|---|
Boolean |
A boolean value that specifies whether to ignore the case for key. |
|
ClassDefinition |
PowerObject |
An object of type PowerObject containing information about the class definition of the object or control. |
Boolean |
Specifies whether the getting value function returns a null value when error occurs. |
JSONPackage function |
Datatype returned |
Description |
---|---|---|
String |
Returns the name assigned to the object. |
|
Integer |
Deletes all of the keys. |
|
Boolean |
Checks if the key name exists. |
|
Integer |
Creates a reference to a context-specific instance of the specified service. |
|
Blob |
Gets the JSON blob data. |
|
String |
Gets the JSON string data. |
|
String |
Gets the key name. |
|
PowerObject |
Returns a reference to the name of the parent object. |
|
String |
Gets the value of the key. |
|
Blob |
Gets the blob value of the key. |
|
Boolean |
Gets the boolean value of the key. |
|
Date |
Gets the date value of the key. |
|
DateTime |
Gets the datetime value of the key. |
|
Number |
Gets the number value of the key. |
|
String |
Gets the string value of the key. |
|
Time |
Gets the time value of the key. |
|
Long |
Gets the value of the key and inserts it into a DataWindow control, DataStore object, or DataWindowChild object. |
|
Long |
Gets the total number of keys. |
|
String |
Loads a JSON file. |
|
String |
Loads a JSON string. |
|
Boolean |
Adds an event to the end of the message queue for the object. |
|
Integer |
Removes a key. |
|
Integer |
Saves the JSON data to the local file. |
|
Integer |
Sets the value of the key. |
|
Integer |
Sets the blob value for a key. |
|
Integer |
Sets the boolean value for a key. |
|
Integer |
Sets the value of the key using the data from a DataWindow control, DataStore object, or DataWindowChild object. |
|
Integer |
Sets the date value for a key. |
|
Integer |
Sets the datetime value for a key. |
|
Integer |
Sets the number value for a key. |
|
Integer |
Sets the string value for a key. |
|
Integer |
Sets the time value for a key. |
|
Integer |
Triggers a specific event in the object and executes the script for the event. |
|
Object |
Returns the type of the object. |