Class ComparisonResult
- java.lang.Object
-
- com.hybris.cockpitng.compare.model.ComparisonResult
-
public class ComparisonResult extends java.lang.ObjectClass holds information about differences between reference object and particular compared objectsreferenceObjectId.
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.Set<java.lang.String>differentGroupsprotected java.util.Map<CompareAttributeDescriptor,java.util.Collection<ObjectAttributesValueContainer>>differentObjectsForAttributesprotected java.util.Set<java.lang.Object>differentObjectsIdsprotected java.util.Map<java.lang.String,java.util.List<CompareAttributeDescriptor>>groupAttributesByGroupNames
-
Constructor Summary
Constructors Constructor Description ComparisonResult(java.lang.Object referenceObjectId, java.util.Map<ObjectAttributesValueContainer,java.util.Set<CompareAttributeDescriptor>> differences, java.util.Set<GroupDescriptor> groupDescriptors)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.util.Set<CompareAttributeDescriptor>getAttributesWithDifferences()java.util.Set<java.lang.String>getGroupsWithDifferences()java.util.Collection<java.lang.Object>getObjectsIdWithDifferences()java.util.Collection<ObjectAttributesValueContainer>getObjectsIdWithDifferences(CompareAttributeDescriptor attributeDescriptor)java.util.Collection<java.lang.Object>getObjectsWithDifferences()Deprecated, for removal: This API element is subject to removal in a future version.since 1811.java.util.Collection<ObjectAttributesValueContainer>getObjectsWithDifferences(CompareAttributeDescriptor attributeDescriptor)Deprecated, for removal: This API element is subject to removal in a future version.since 1811.java.lang.ObjectgetReferenceObject()Deprecated, for removal: This API element is subject to removal in a future version.since 1811.java.lang.ObjectgetReferenceObjectId()booleanmerge(ComparisonResult addition, java.lang.Object comparedObjectId)protected voidupdateDifferentObjects()protected voidupdateGroupsDifferences(ComparisonResult addition)protected voidupdateObjectsForAttributesDifferences(ComparisonResult addition, java.lang.Object comparedObjectId)
-
-
-
Field Detail
-
differentObjectsIds
protected final java.util.Set<java.lang.Object> differentObjectsIds
-
differentGroups
protected final java.util.Set<java.lang.String> differentGroups
-
differentObjectsForAttributes
protected final java.util.Map<CompareAttributeDescriptor,java.util.Collection<ObjectAttributesValueContainer>> differentObjectsForAttributes
-
groupAttributesByGroupNames
protected final java.util.Map<java.lang.String,java.util.List<CompareAttributeDescriptor>> groupAttributesByGroupNames
-
-
Constructor Detail
-
ComparisonResult
public ComparisonResult(java.lang.Object referenceObjectId, java.util.Map<ObjectAttributesValueContainer,java.util.Set<CompareAttributeDescriptor>> differences, java.util.Set<GroupDescriptor> groupDescriptors)
-
-
Method Detail
-
getObjectsWithDifferences
@Deprecated(since="1811", forRemoval=true) public java.util.Collection<java.lang.Object> getObjectsWithDifferences()Deprecated, for removal: This API element is subject to removal in a future version.since 1811. Please usegetObjectsIdWithDifferences()
-
getObjectsIdWithDifferences
public java.util.Collection<java.lang.Object> getObjectsIdWithDifferences()
- Returns:
- collection of the different object ids for
referenceObjectId, otherwise empty collection
-
getAttributesWithDifferences
public java.util.Set<CompareAttributeDescriptor> getAttributesWithDifferences()
-
getObjectsWithDifferences
@Deprecated(since="1811", forRemoval=true) public java.util.Collection<ObjectAttributesValueContainer> getObjectsWithDifferences(CompareAttributeDescriptor attributeDescriptor)Deprecated, for removal: This API element is subject to removal in a future version.since 1811. Please usegetObjectsIdWithDifferences()
-
getObjectsIdWithDifferences
public java.util.Collection<ObjectAttributesValueContainer> getObjectsIdWithDifferences(CompareAttributeDescriptor attributeDescriptor)
- Parameters:
attributeDescriptor- comparing attribute descriptor- Returns:
- collection of differences
ObjectAttributesValueContainerfor anattributeDescriptor, otherwise empty collection
-
getReferenceObject
@Deprecated(since="1811", forRemoval=true) public java.lang.Object getReferenceObject()Deprecated, for removal: This API element is subject to removal in a future version.since 1811. Please usegetReferenceObjectId()
-
getReferenceObjectId
public java.lang.Object getReferenceObjectId()
-
getGroupsWithDifferences
public java.util.Set<java.lang.String> getGroupsWithDifferences()
- Returns:
- collection of difference group for
referenceObjectId, otherwise empty collection
-
merge
public boolean merge(ComparisonResult addition, java.lang.Object comparedObjectId)
-
updateObjectsForAttributesDifferences
protected void updateObjectsForAttributesDifferences(ComparisonResult addition, java.lang.Object comparedObjectId)
-
updateGroupsDifferences
protected void updateGroupsDifferences(ComparisonResult addition)
-
updateDifferentObjects
protected void updateDifferentObjects()
-
-