org.nuxeo.ecm.platform.contentview.json
Class JSONContentViewState
java.lang.Object
org.nuxeo.ecm.platform.contentview.json.JSONContentViewState
public class JSONContentViewState
- extends Object
Exporter/importer in JSON format of a ContentViewState
.
- Since:
- 5.4.2
ENCODED_VALUES_ENCODING
public static final String ENCODED_VALUES_ENCODING
- See Also:
- Constant Field Values
JSONContentViewState
public JSONContentViewState()
toJSON
public static String toJSON(ContentViewState state,
boolean encode)
throws ClientException,
UnsupportedEncodingException
- Returns the String serialization in JSON format of a content view state.
- Parameters:
state
- the state to serializeencode
- if true, the resulting String will be zipped and encoded
in Base-64 format.
- Throws:
ClientException
UnsupportedEncodingException
fromJSON
public static ContentViewState fromJSON(String json,
boolean decode)
throws UnsupportedEncodingException,
ClientException
- Returns the content view state from its String serialization in JSON
format.
- Parameters:
json
- the state to de-serializedecode
- if true, the input String is decoded from Base-64 format
and unzipped.
- Throws:
ClientException
UnsupportedEncodingException
Copyright © 2011 Nuxeo SAS. All Rights Reserved.