Class XstreamJsonConverter
java.lang.Object
edu.internet2.middleware.grouper.ws.rest.json.XstreamJsonConverter
- All Implemented Interfaces:
JsonConverter
legacy (deprecated) json converter, doesnt always work correctly, sometimes
can unmarshal things that it marshals
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionconvertFromJson
(String json, StringBuilder warnings) convert a json string to an object.convertToJson
(Object object) convert an object to json.void
convertToJson
(Object object, Writer writer) convert an object to json.
-
Constructor Details
-
XstreamJsonConverter
public XstreamJsonConverter()
-
-
Method Details
-
convertFromJson
Description copied from interface:JsonConverter
convert a json string to an object. note that only certain object are allowed to be marshaled from json, the aliases in WsRestClassLookup.getAliasClassMap()- Specified by:
convertFromJson
in interfaceJsonConverter
warnings
- put warnings here- Returns:
- the object
- See Also:
-
convertToJson
Description copied from interface:JsonConverter
convert an object to json. Note, there are only certian aliases which are allowed to be converted from json, so make sure to marshal the container object name somewhere (e.g. in the top level json object)- Specified by:
convertToJson
in interfaceJsonConverter
- Returns:
- the json
- See Also:
-
convertToJson
Description copied from interface:JsonConverter
convert an object to json. Note, there are only certian aliases which are allowed to be converted from json, so make sure to marshal the container object name somewhere (e.g. in the top level json object)- Specified by:
convertToJson
in interfaceJsonConverter
- Parameters:
object
- to convert to jsonwriter
- write the json here- See Also:
-