Class AbstractValueTransformationExpressionEvaluator<V extends PrismValue,D extends ItemDefinition<?>,E extends TransformExpressionEvaluatorType>
java.lang.Object
com.evolveum.midpoint.repo.common.expression.evaluator.AbstractExpressionEvaluator<V,D,E>
com.evolveum.midpoint.model.common.expression.evaluator.transformation.AbstractValueTransformationExpressionEvaluator<V,D,E>
- Type Parameters:
V
- Type of output PrismValues.D
- Definition of output values.E
- Type of the configuration (evaluator) bean.
- All Implemented Interfaces:
ExpressionEvaluator<V>
- Direct Known Subclasses:
AbstractSearchExpressionEvaluator
,ScriptExpressionEvaluator
public abstract class AbstractValueTransformationExpressionEvaluator<V extends PrismValue,D extends ItemDefinition<?>,E extends TransformExpressionEvaluatorType>
extends AbstractExpressionEvaluator<V,D,E>
Evaluates transformational expression: one that transforms input values to output values.
Actually, the hard work is delegated to RelativisticEvaluation and AbsoluteEvaluation classes.
- Author:
- Radovan Semancik
-
Field Summary
Modifier and TypeFieldDescriptionprotected final LocalizationService
protected final SecurityContextManager
May be `null` in some low-level tests whereModelCommonBeans
are initialized manually.Fields inherited from class com.evolveum.midpoint.repo.common.expression.evaluator.AbstractExpressionEvaluator
expressionEvaluatorBean, outputDefinition, prismContext, protector
-
Constructor Summary
ModifierConstructorDescriptionprotected
AbstractValueTransformationExpressionEvaluator
(QName elementName, E expressionEvaluatorType, D outputDefinition, Protector protector, LocalizationService localizationService) -
Method Summary
Modifier and TypeMethodDescriptionevaluate
(ExpressionEvaluationContext context, OperationResult parentResult) Executes the evaluation in a given context.protected boolean
protected boolean
transformSingleValue
(VariablesMap variables, PlusMinusZero valueDestination, boolean useNew, ExpressionEvaluationContext context, String contextDescription, Task task, OperationResult result) Transforms single value tuple.Methods inherited from class com.evolveum.midpoint.repo.common.expression.evaluator.AbstractExpressionEvaluator
addInternalOrigin, applyValueMetadata, checkEvaluatorProfile, findInSourcesAndVariables, finishOutputTriple, getElementName, getOutputDefinition, getPrismContext, getProtector
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.evolveum.midpoint.repo.common.expression.ExpressionEvaluator
shortDebugDump
-
Field Details
-
securityContextManager
May be `null` in some low-level tests whereModelCommonBeans
are initialized manually. -
localizationService
-
-
Constructor Details
-
AbstractValueTransformationExpressionEvaluator
protected AbstractValueTransformationExpressionEvaluator(QName elementName, E expressionEvaluatorType, D outputDefinition, Protector protector, LocalizationService localizationService)
-
-
Method Details
-
evaluate
public PrismValueDeltaSetTriple<V> evaluate(ExpressionEvaluationContext context, OperationResult parentResult) throws SchemaException, ExpressionEvaluationException, ObjectNotFoundException, CommunicationException, ConfigurationException, SecurityViolationException Description copied from interface:ExpressionEvaluator
Executes the evaluation in a given context. The context provides necessary data, evaluator provides definition of processing that should be carried out.- Returns:
- Result of the evaluation in the form of delta set triple (i.e. added, deleted, unchanged values).
- Throws:
SchemaException
ExpressionEvaluationException
ObjectNotFoundException
CommunicationException
ConfigurationException
SecurityViolationException
-
isIncludeNullInputs
protected boolean isIncludeNullInputs() -
isRelative
protected boolean isRelative() -
transformSingleValue
@NotNull protected abstract @NotNull List<V> transformSingleValue(VariablesMap variables, PlusMinusZero valueDestination, boolean useNew, ExpressionEvaluationContext context, String contextDescription, Task task, OperationResult result) throws ExpressionEvaluationException, ObjectNotFoundException, SchemaException, CommunicationException, ConfigurationException, SecurityViolationException Transforms single value tuple.- Parameters:
variables
- Variables to be applied. Must not be relativistic! All deltas must be sorted out by now.valueDestination
- Where we are going to put output value(s). Actually it's only supplementary information for the transformer as the actual placement of output values is done in the caller.useNew
- Are we using "new" state of sources/input variables? Again, this is only supplementary information, because the variables should be already non-relativistic. Some scripts need to know the value of "useNew".context
- Caller-specified context of the whole expression evaluation.- Throws:
ExpressionEvaluationException
ObjectNotFoundException
SchemaException
CommunicationException
ConfigurationException
SecurityViolationException
-