Class MergeManager
java.lang.Object
org.broadleafcommerce.common.extensibility.context.merge.MergeManager
This class manages all xml merge interactions with callers. It is responsible for
not only loading the handler configurations, but also for cycling through the handlers
in a prioritized fashion and exporting the final merged document.
- Author:
- jfischer
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringAdditional merge points may be added by the caller. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionmerge(ResourceInputStream stream1, ResourceInputStream stream2) Merge 2 xml document streams together into a final resulting stream.serialize(InputStream in)
-
Field Details
-
MERGE_DEFINITION_SYSTEM_PROPERTY
Additional merge points may be added by the caller. Also default merge points may be overriden to change their current behavior. This is accomplished by specifying the system property denoted by the key MergeManager.MERGE_DEFINITION_SYSTEM_PROPERTY with a value stating the fully qualified path of user-created property file. Please refer to the default properties file located at org/broadleafcommerce/profile/extensibility/context/merge/default.properties for more details.- See Also:
-
-
Constructor Details
-
MergeManager
- Throws:
MergeManagerSetupException
-
-
Method Details
-
merge
public ResourceInputStream merge(ResourceInputStream stream1, ResourceInputStream stream2) throws MergeException Merge 2 xml document streams together into a final resulting stream. During the merge, various merge business rules are followed based on configuration defined for various merge points.- Parameters:
stream1-stream2-- Returns:
- the stream representing the merged document
- Throws:
MergeException
-
serialize
-