Class ItemPathNaturalKeyImpl
java.lang.Object
com.evolveum.midpoint.schema.merger.key.ItemPathNaturalKeyImpl
- All Implemented Interfaces:
NaturalKey
Natural key consisting of an item path.
Assumptions:
1. the type of the key item is
ItemPathType
2. each container value to be merged must have the key value specified-
Method Summary
Modifier and TypeMethodDescriptionvoid
mergeMatchingKeys
(PrismContainerValue<?> targetValue, PrismContainerValue<?> sourceValue) Source and target paths have to be equivalent here.static ItemPathNaturalKeyImpl
boolean
valuesMatch
(PrismContainerValue<?> targetValue, PrismContainerValue<?> sourceValue) Returns `true` if the target and source container values match on their natural key.
-
Method Details
-
of
-
valuesMatch
public boolean valuesMatch(PrismContainerValue<?> targetValue, PrismContainerValue<?> sourceValue) throws ConfigurationException Description copied from interface:NaturalKey
Returns `true` if the target and source container values match on their natural key. (I.e. they have to be merged together.)- Specified by:
valuesMatch
in interfaceNaturalKey
- Throws:
ConfigurationException
-
mergeMatchingKeys
public void mergeMatchingKeys(PrismContainerValue<?> targetValue, PrismContainerValue<?> sourceValue) throws ConfigurationException Source and target paths have to be equivalent here. We assume the source and target paths are purely name-based. We go through them and construct the resulting path from the "most qualified" segments of these. We intentionally ignore some exotic cases here. (We are not obliged to create a "ideal" merged key, anyway.)- Specified by:
mergeMatchingKeys
in interfaceNaturalKey
- Throws:
ConfigurationException
-