Class DelegatingMigrationAwareFragmentTransformer
java.lang.Object
com.atlassian.confluence.content.render.xhtml.migration.DelegatingMigrationAwareFragmentTransformer
- All Implemented Interfaces:
MigrationAware
,FragmentTransformer
public class DelegatingMigrationAwareFragmentTransformer
extends Object
implements MigrationAware, FragmentTransformer
A simple delegating implementation of
MigrationAware
and FragmentTransformer
.- Since:
- 5.3
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.atlassian.confluence.content.render.xhtml.migration.MigrationAware
MigrationAware.MigrationPerformedPredicate
-
Constructor Summary
ConstructorsConstructorDescriptionDelegatingMigrationAwareFragmentTransformer
(FragmentTransformer fragmentTransformer, MigrationAware migrationAware) -
Method Summary
Modifier and TypeMethodDescriptionboolean
handles
(StartElement startElementEvent, ConversionContext conversionContext) transform
(XMLEventReader reader, FragmentTransformer mainFragmentTransformer, ConversionContext conversionContext) boolean
wasMigrationPerformed
(ConversionContext conversionContext) Given aConversionContext
that was previously used to perform a migration, determine if that context contains information that indicates whether a "migration" was performed.
-
Constructor Details
-
DelegatingMigrationAwareFragmentTransformer
public DelegatingMigrationAwareFragmentTransformer(FragmentTransformer fragmentTransformer, MigrationAware migrationAware)
-
-
Method Details
-
wasMigrationPerformed
Description copied from interface:MigrationAware
Given aConversionContext
that was previously used to perform a migration, determine if that context contains information that indicates whether a "migration" was performed. What constitutes a migration is implementation-dependent.- Specified by:
wasMigrationPerformed
in interfaceMigrationAware
- Parameters:
conversionContext
- the context used for the migration- Returns:
- true if migration was performed against the supplied context, false otherwise.
-
handles
- Specified by:
handles
in interfaceFragmentTransformer
-
transform
public Streamable transform(XMLEventReader reader, FragmentTransformer mainFragmentTransformer, ConversionContext conversionContext) throws XhtmlException - Specified by:
transform
in interfaceFragmentTransformer
- Throws:
XhtmlException
-