001
014
015 package com.liferay.portal.kernel.json;
016
017 import java.util.List;
018
019
022 public interface JSONFactory {
023
024 public String convertJSONMLArrayToXML(String jsonml);
025
026 public String convertJSONMLObjectToXML(String jsonml);
027
028 public String convertXMLtoJSONMLArray(String xml);
029
030 public String convertXMLtoJSONMLObject(String xml);
031
032 public JSONTransformer createJavaScriptNormalizerJSONTransformer(
033 List<String> javaScriptAttributes);
034
035 public JSONArray createJSONArray();
036
037 public JSONArray createJSONArray(String json) throws JSONException;
038
039 public <T> JSONDeserializer<T> createJSONDeserializer();
040
041 public JSONObject createJSONObject();
042
043 public JSONObject createJSONObject(String json) throws JSONException;
044
045 public JSONSerializer createJSONSerializer();
046
047 public Object deserialize(JSONObject jsonObj);
048
049 public Object deserialize(String json);
050
051 public String getNullJSON();
052
053 public Object looseDeserialize(String json);
054
055 public <T> T looseDeserialize(String json, Class<T> clazz);
056
057 public String looseSerialize(Object object);
058
059 public String looseSerialize(
060 Object object, JSONTransformer jsonTransformer, Class<?> clazz);
061
062 public String looseSerialize(Object object, String... includes);
063
064 public String looseSerializeDeep(Object object);
065
066 public String looseSerializeDeep(
067 Object object, JSONTransformer jsonTransformer, Class<?> clazz);
068
069 public String serialize(Object object);
070
071 public String serializeException(Exception exception);
072
073 }