Class AbstractAddressAddressAndUserUserRelationMergeHandler

java.lang.Object
ch.tocco.nice2.entityoperation.spi.merge.ToManyRelationMergeHandler
ch.tocco.nice2.optional.address.impl.merge.AbstractAddressAddressAndUserUserRelationMergeHandler
All Implemented Interfaces:
RelationMergeHandler
Direct Known Subclasses:
AddressAddressRelationMergeHandler, UserUserRelationMergeHandler

public abstract class AbstractAddressAddressAndUserUserRelationMergeHandler extends ToManyRelationMergeHandler
Abstract RelationMergeHandler for Address->Address_address and User->User_user relations. This handler removes potential duplicates if multiple source entities have a relation to the same entity. This is necessary to avoid a validation error. If there are duplicates it is important to remove the 'new' value and keep the existing one, because the validator uses a query to compare uniqueness.