public class SceneEncoder extends Encoder
Scene object serializer.
Used to serialize the XML string that identifies the scenario into an XML format.
| Modifier and Type | Field and Description |
|---|---|
protected ResourceManager |
message |
| Constructor and Description |
|---|
SceneEncoder() |
| Modifier and Type | Method and Description |
|---|---|
protected java.util.List<MediaType> |
createSupportedMediaTypes()
Creates a supported media type, here is the XML type.
|
protected java.lang.String |
getSceneXML(java.lang.Object content) |
Representation |
toRepresentation(MediaType mediaType, java.lang.Object content)
Serializes XML strings into DOM-based XML representations.
|
getSupportedMediaTypes, isEncodeAllowprotected java.util.List<MediaType> createSupportedMediaTypes()
Creates a supported media type, here is the XML type.
That is, SceneEncoder supports the conversion of the formatted object to the media type.
createSupportedMediaTypes in class Encoder
public Representation toRepresentation(MediaType mediaType,
java.lang.Object content)
Serializes XML strings into DOM-based XML representations.
toRepresentation in class EncodermediaType - The target media type to be serialized.content - The source XML string to be serialized.protected java.lang.String getSceneXML(java.lang.Object content)