Class ImprovedEditorUnknownMacroMarshaller
java.lang.Object
com.atlassian.confluence.content.render.xhtml.editor.macro.ImprovedEditorUnknownMacroMarshaller
- All Implemented Interfaces:
MacroMarshaller
Replaces EditorUnknownMacroMarshaller to handle both body and bodiless macros.
Preserves the content when a macro is disabled and allows editing the disabled macro content and type.
Note the parent class differs from EditorUnknownMacroMarshaller
-
Constructor Summary
ConstructorsConstructorDescriptionImprovedEditorUnknownMacroMarshaller
(CommonMacroAttributeWriter commonAttributeWriter, PlaceholderUrlFactory placeholderUrlFactory, XMLOutputFactory xmlOutputFactory) -
Method Summary
Modifier and TypeMethodDescriptionboolean
marshal
(Macro macro, MacroDefinition macroDefinition, ConversionContext conversionContext) Marshall the supplied macro.
-
Constructor Details
-
ImprovedEditorUnknownMacroMarshaller
public ImprovedEditorUnknownMacroMarshaller(CommonMacroAttributeWriter commonAttributeWriter, PlaceholderUrlFactory placeholderUrlFactory, XMLOutputFactory xmlOutputFactory)
-
-
Method Details
-
handles
- Specified by:
handles
in interfaceMacroMarshaller
- Parameters:
macro
- the macro to check. This may be null.- Returns:
- true if the MacroMarshaller can handle this macro.
-
marshal
public Streamable marshal(Macro macro, MacroDefinition macroDefinition, ConversionContext conversionContext) throws XhtmlException Description copied from interface:MacroMarshaller
Marshall the supplied macro.- Specified by:
marshal
in interfaceMacroMarshaller
- Parameters:
macro
- the macro to be marshalled. It may be null, such as in the case where a Macro has not been identified by the system.- Returns:
- Throws:
XhtmlException
-