public class

EditorAttachmentResourceIdentifierMarshallerAndUnmarshaller

extends Object
implements StaxStreamMarshaller<T> Unmarshaller<T>
java.lang.Object
   ↳ com.atlassian.confluence.content.render.xhtml.editor.resource.identifiers.EditorAttachmentResourceIdentifierMarshallerAndUnmarshaller

Summary

Public Constructors
EditorAttachmentResourceIdentifierMarshallerAndUnmarshaller(EditorPageResourceIdentifierMarshallerAndUnmarshaller pageResourceIdentifierMarshallerAndUnmarshaller, EditorBlogPostResourceIdentifierMarshallerAndUnmarshaller blogPostResourceIdentifierMarshallerAndUnmarshaller)
Public Methods
boolean handles(StartElement startElementEvent, ConversionContext conversionContext)
Determines whether or not this unmarshaller should be applied to a fragment with the specified start element.
void marshal(AttachmentResourceIdentifier attachmentResourceIdentifier, XMLStreamWriter xmlStreamWriter, ConversionContext context)
ResourceIdentifier unmarshal(XMLEventReader xmlEventReader, FragmentTransformer mainFragmentTransformer, ConversionContext conversionContext)
Unmarshalls a StAX event stream to an object.
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.atlassian.confluence.content.render.xhtml.StaxStreamMarshaller
From interface com.atlassian.confluence.content.render.xhtml.Unmarshaller

Public Constructors

public EditorAttachmentResourceIdentifierMarshallerAndUnmarshaller (EditorPageResourceIdentifierMarshallerAndUnmarshaller pageResourceIdentifierMarshallerAndUnmarshaller, EditorBlogPostResourceIdentifierMarshallerAndUnmarshaller blogPostResourceIdentifierMarshallerAndUnmarshaller)

Public Methods

public boolean handles (StartElement startElementEvent, ConversionContext conversionContext)

Determines whether or not this unmarshaller should be applied to a fragment with the specified start element.

Parameters
startElementEvent start element
conversionContext the conversion context
Returns
  • true if this unmarshaller can be applied, false otherwise

public void marshal (AttachmentResourceIdentifier attachmentResourceIdentifier, XMLStreamWriter xmlStreamWriter, ConversionContext context)

Throws
XMLStreamException

public ResourceIdentifier unmarshal (XMLEventReader xmlEventReader, FragmentTransformer mainFragmentTransformer, ConversionContext conversionContext)

Unmarshalls a StAX event stream to an object.

Parameters
xmlEventReader a reader over the fragment to unmarshall
mainFragmentTransformer TODO
conversionContext the conversion context
Returns
  • the unmarshalled object