Cloud Application Integration (On-Premises) : Integration Server Built-In Services : JSON Folder : pub.json:jsonStringToDocument
pub.json:jsonStringToDocument
WmPublic. Converts a JSON string to a document (an IData object).
Input Parameters
jsonString
String JSON content in a string to convert to a document (IData object).
decodeRealAsDouble
String Optional. Converts real numbers from jsonString to either a Float or Double Java wrapper type. Set to:
*true to convert real numbers to Double Java wrapper types. This is the default.
*false to convert real numbers to Float Java wrapper types.
Note:  
The decodeRealAsDouble parameter overrides the value specified by the watt.server.json.decodeRealAsDouble server configuration parameter. If no value is supplied for decodeRealAsDouble, Integration Serveruses the value set in watt.server.json.decodeRealAsDouble. For more information about watt.server.json.decodeRealAsDouble, see webMethods Integration Server Administrator’s Guide.
decodeIntegerAsLong
String Optional. Converts integers from jsonString to either a Long or Integer Java wrapper type. Set to:
*true to convert integers to Long Java wrapper types. This is the default.
*false to convert integers to Integer Java wrapper types.
Note:  
The decodeRealAsDouble parameter overrides the value specified by the watt.server.json.decodeIntegerAsLong server configuration parameter. If no value is supplied for decodeIntegerAsLong, Integration Server uses the value specified in the watt.server.json.decodeIntegerAsLong property. For more information about watt.server.json.decodeIntegerAsLong, see webMethods Integration Server Administrator’s Guide.
Output Parameters
document
Document Document (IData object) resulting from the conversion of jsonString.
Usage Notes
The JSON standard requires that field names be enclosed in double quotes. However, when parsing legacy JavaScript as JSON text it may be helpful to allow unquoted field names as JavaScript does not require field names to be enclosed in double quotes. The server configuration parameter watt.server.json.allowUnquotedFieldNames specifies whether or not unquoted field names are allowed in JSON text passed to thepub.json:jsonStringToDocument and pub.json:jsonStreamToDocument services. If this parameter is set to true, the pub.json:jsonStringToDocument and pub.json:jsonStreamToDocument services allow unquoted field names in any supplied JSON text. If this parameter is set to false, the services throw a ServiceException when encountering unquoted field names. The default is false.
Copyright © 2015- 2016 Software AG, Darmstadt, Germany.

Product LogoContact Support   |   Community   |   Feedback