Search in sources :

Example 1 with ProjectionMergeSituationType

use of com.evolveum.midpoint.xml.ns._public.common.common_3.ProjectionMergeSituationType in project midpoint by Evolveum.

the class ObjectMerger method projectionMatches.

private boolean projectionMatches(ShadowType candidateProjection, List<ShadowType> projectionsLeft, List<ShadowType> projectionsRight, ProjectionMergeConfigurationType projectionMergeConfig) {
    ShadowDiscriminatorType discriminatorType = projectionMergeConfig.getProjectionDiscriminator();
    if (discriminatorType != null && !ShadowUtil.matchesPattern(candidateProjection, discriminatorType)) {
        return false;
    }
    ProjectionMergeSituationType situationPattern = projectionMergeConfig.getSituation();
    if (situationPattern != null) {
        ProjectionMergeSituationType projectionSituation = determineSituation(candidateProjection, projectionsLeft, projectionsRight);
        return situationPattern == projectionSituation;
    } else {
        return true;
    }
}
Also used : ProjectionMergeSituationType(com.evolveum.midpoint.xml.ns._public.common.common_3.ProjectionMergeSituationType) ShadowDiscriminatorType(com.evolveum.midpoint.xml.ns._public.common.common_3.ShadowDiscriminatorType)

Aggregations

ProjectionMergeSituationType (com.evolveum.midpoint.xml.ns._public.common.common_3.ProjectionMergeSituationType)1 ShadowDiscriminatorType (com.evolveum.midpoint.xml.ns._public.common.common_3.ShadowDiscriminatorType)1