Class DefaultCloneProductRelationshipsManager<P extends Product,R extends CloneProductRequest>
java.lang.Object
com.broadleafcommerce.catalog.clone.product.DefaultCloneProductRelationshipsManager<P,R>
- All Implemented Interfaces:
CloneProductRelationshipsManager<P,
R>
public class DefaultCloneProductRelationshipsManager<P extends Product,R extends CloneProductRequest>
extends Object
implements CloneProductRelationshipsManager<P,R>
Default implementation for
CloneProductRelationshipsManager
.- Author:
- Dima Myroniuk (dmyroniuk)
-
Constructor Summary
ConstructorDescriptionDefaultCloneProductRelationshipsManager
(List<CloneProductRelationshipsService<P, R>> cloneProductRelationshipsServices) -
Method Summary
Modifier and TypeMethodDescriptionvoid
cloneRelationships
(R request, P original, P cloned, com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Clone theProduct
relationships.protected List<CloneProductRelationshipsService<P,
R>> protected void
initializeChangeContainerIfNecessary
(com.broadleafcommerce.data.tracking.core.context.ContextInfo context, Product cloned)
-
Constructor Details
-
DefaultCloneProductRelationshipsManager
public DefaultCloneProductRelationshipsManager(List<CloneProductRelationshipsService<P, R>> cloneProductRelationshipsServices)
-
-
Method Details
-
cloneRelationships
public void cloneRelationships(R request, P original, P cloned, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Description copied from interface:CloneProductRelationshipsManager
Clone theProduct
relationships.- Specified by:
cloneRelationships
in interfaceCloneProductRelationshipsManager<P extends Product,
R extends CloneProductRequest> - Parameters:
request
- the request to perform the clone operationoriginal
- the originalProduct
cloned
- theProduct
for which to clone relationships. The cloned relationships will be assigned to this Product.context
- context information surrounding sandboxing and multitenant state
-
initializeChangeContainerIfNecessary
protected void initializeChangeContainerIfNecessary(@Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context, Product cloned) -
getCloneProductRelationshipsServices
-