Class JSONReader
java.lang.Object
org.springframework.extensions.webscripts.json.JSONReader
- All Implemented Interfaces:
FormatReader<Object>
Convert application/json to org.json.JSONObject or org.json.JSONArray
- Author:
- Roy Wetherall
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionCreate script parameters specific to source mimetypeGets the Java Class to convert toGets the source mimetype to convert fromread(WebScriptRequest req) Converts mimetype to Java Object
-
Constructor Details
-
JSONReader
public JSONReader()
-
-
Method Details
-
getDestinationClass
Description copied from interface:FormatReaderGets the Java Class to convert to- Specified by:
getDestinationClassin interfaceFormatReader<Object>- Returns:
- Java Clas
- See Also:
-
getSourceMimetype
Description copied from interface:FormatReaderGets the source mimetype to convert from- Specified by:
getSourceMimetypein interfaceFormatReader<Object>- Returns:
- mimetype
- See Also:
-
read
Description copied from interface:FormatReaderConverts mimetype to Java Object- Specified by:
readin interfaceFormatReader<Object>- Parameters:
req- web script request- Returns:
- Java Object
- See Also:
-
createScriptParameters
Description copied from interface:FormatReaderCreate script parameters specific to source mimetype- Specified by:
createScriptParametersin interfaceFormatReader<Object>- Parameters:
req- web script requestres- web script response- Returns:
- map of script objects indexed by name
- See Also:
-