-
Notifications
You must be signed in to change notification settings - Fork 188
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/master' into feature/shadow-meta…
…data
- Loading branch information
Showing
64 changed files
with
1,488 additions
and
797 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
73 changes: 73 additions & 0 deletions
73
infra/schema/src/main/java/com/evolveum/midpoint/schema/selector/eval/MatchingContext.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
/* | ||
* Copyright (C) 2010-2023 Evolveum and contributors | ||
* | ||
* This work is dual-licensed under the Apache License 2.0 | ||
* and European Union Public License. See LICENSE file for details. | ||
*/ | ||
|
||
package com.evolveum.midpoint.schema.selector.eval; | ||
|
||
import com.evolveum.midpoint.prism.PrismValue; | ||
import com.evolveum.midpoint.schema.selector.spec.SelectorClause; | ||
import com.evolveum.midpoint.schema.selector.spec.ValueSelector; | ||
|
||
import com.evolveum.midpoint.schema.traces.details.ProcessingTracer; | ||
|
||
import org.jetbrains.annotations.NotNull; | ||
import org.jetbrains.annotations.Nullable; | ||
|
||
import static com.evolveum.midpoint.schema.selector.eval.SubjectedEvaluationContext.*; | ||
|
||
/** | ||
* Context for matching a value against a selector or clause. | ||
* | ||
* @see ValueSelector#matches(PrismValue, MatchingContext) | ||
* @see SelectorClause#matches(PrismValue, MatchingContext) | ||
*/ | ||
public class MatchingContext extends SelectorProcessingContext { | ||
|
||
public MatchingContext( | ||
@Nullable ObjectFilterExpressionEvaluator filterEvaluator, | ||
@NotNull ProcessingTracer<SelectorTraceEvent> tracer, | ||
@NotNull OrgTreeEvaluator orgTreeEvaluator, | ||
@Nullable SubjectedEvaluationContext subjectedEvaluationContext, | ||
@Nullable OwnerResolver ownerResolver, | ||
@Nullable ObjectResolver objectResolver, | ||
@NotNull ClauseProcessingContextDescription description, | ||
@NotNull DelegatorSelection delegatorSelection) { | ||
super( | ||
filterEvaluator, | ||
tracer, | ||
orgTreeEvaluator, | ||
subjectedEvaluationContext, | ||
ownerResolver, | ||
objectResolver, | ||
description, | ||
delegatorSelection); | ||
} | ||
|
||
public @NotNull MatchingContext child( | ||
@NotNull DelegatorSelection delegatorSelection, @NotNull String idDelta, @NotNull String textDelta) { | ||
return new MatchingContext( | ||
filterEvaluator, | ||
tracer, | ||
orgTreeEvaluator, | ||
subjectedEvaluationContext, | ||
ownerResolver, | ||
objectResolver, | ||
description.child(idDelta, textDelta), | ||
delegatorSelection); | ||
} | ||
|
||
public @NotNull MatchingContext child(@NotNull String idDelta, @NotNull String textDelta) { | ||
return new MatchingContext( | ||
filterEvaluator, | ||
tracer, | ||
orgTreeEvaluator, | ||
subjectedEvaluationContext, | ||
ownerResolver, | ||
objectResolver, | ||
description.child(idDelta, textDelta), | ||
delegatorSelection); | ||
} | ||
} |
Oops, something went wrong.