Class ItemModelCloneCreator

java.lang.Object
de.hybris.platform.servicelayer.internal.model.impl.ItemModelCloneCreator
Direct Known Subclasses:
CMSItemModelCloneCreator

public class ItemModelCloneCreator extends Object
This class creates a deep copy of the given original model by creating a new model instance of the same type, reading all attributes values and stores them into the new instance.

The only exception are part-of attribute values which consists of other models - these are cloned themselves and then used as attribute value in the new model instance.

By providing a ItemModelCloneCreator.CopyContext the caller may even add some preset values or define which types are being used when creating copied of part-of models.