org.broadleafcommerce.common.extensibility.context.merge
Class MergeManager

java.lang.Object
  extended by org.broadleafcommerce.common.extensibility.context.merge.MergeManager

public class MergeManager
extends Object

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
static String MERGE_DEFINITION_SYSTEM_PROPERTY
          Additional merge points may be added by the caller.
 
Constructor Summary
MergeManager()
           
 
Method Summary
 ResourceInputStream merge(ResourceInputStream stream1, ResourceInputStream stream2)
          Merge 2 xml document streams together into a final resulting stream.
 String serialize(InputStream in)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MERGE_DEFINITION_SYSTEM_PROPERTY

public static final String 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:
Constant Field Values
Constructor Detail

MergeManager

public MergeManager()
             throws MergeManagerSetupException
Throws:
MergeManagerSetupException
Method Detail

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

public String serialize(InputStream in)


Copyright © 2012. All Rights Reserved.