Class ExpressionVariables
- java.lang.Object
-
- com.evolveum.midpoint.schema.expression.VariablesMap
-
- com.evolveum.midpoint.repo.common.expression.ExpressionVariables
-
- All Implemented Interfaces:
DebugDumpable
,Map<String,TypedValue>
public class ExpressionVariables extends VariablesMap
- Author:
- Radovan Semancik
-
-
Field Summary
-
Fields inherited from interface com.evolveum.midpoint.util.DebugDumpable
INDENT_STRING
-
-
Constructor Summary
Constructors Constructor Description ExpressionVariables()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description <D extends ItemDefinition>
voidaddVariableDefinition(String name, Object value, D definition)
void
addVariableDefinitions(VariablesMap extraVariables)
Adds map of extra variables to the expression.void
addVariableDefinitions(VariablesMap extraVariables, Collection<String> exceptFor)
void
addVariableDefinitionsNew(VariablesMap extraVariables)
Adds map of extra variables to the expression.void
addVariableDefinitionsOld(VariablesMap extraVariables)
Adds map of extra variables to the expression.static ExpressionVariables
create(PrismContext prismContext, Object... parameters)
Expects name-value-definition triples.Object
getValue(String name)
<T> T
getValue(String name, Class<T> type)
<O extends ObjectType>
PrismObject<O>getValueNew(String name)
<D extends ItemDefinition>
voidreplaceVariableDefinition(String name, Object value, D definition)
void
setRootNode(ObjectReferenceType objectRef, PrismReferenceDefinition def)
String
toString()
-
Methods inherited from class com.evolveum.midpoint.schema.expression.VariablesMap
clear, containsKey, containsValue, debugDump, dumpSingleLine, emptyMap, entrySet, equals, fillIn, formatVariables, get, hashCode, isEmpty, keySet, put, put, put, putAll, putList, putObject, putObject, remove, size, values
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.evolveum.midpoint.util.DebugDumpable
debugDump, debugDumpLazily, debugDumpLazily
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
-
-
-
Method Detail
-
addVariableDefinitions
public void addVariableDefinitions(VariablesMap extraVariables)
Adds map of extra variables to the expression. If there are variables with deltas (ObjectDeltaObject) the operation fail because it cannot decide which version to use.
-
addVariableDefinitions
public void addVariableDefinitions(VariablesMap extraVariables, @NotNull Collection<String> exceptFor)
-
addVariableDefinitionsOld
public void addVariableDefinitionsOld(VariablesMap extraVariables)
Adds map of extra variables to the expression. If there are variables with deltas (ObjectDeltaObject) it takes the "old" version of the object.
-
addVariableDefinitionsNew
public void addVariableDefinitionsNew(VariablesMap extraVariables)
Adds map of extra variables to the expression. If there are variables with deltas (ObjectDeltaObject) it takes the "new" version of the object.
-
setRootNode
public void setRootNode(ObjectReferenceType objectRef, PrismReferenceDefinition def)
-
addVariableDefinition
public <D extends ItemDefinition> void addVariableDefinition(String name, Object value, D definition)
-
replaceVariableDefinition
public <D extends ItemDefinition> void replaceVariableDefinition(String name, Object value, D definition)
-
getValue
public <T> T getValue(String name, Class<T> type) throws SchemaException
- Throws:
SchemaException
-
getValueNew
public <O extends ObjectType> PrismObject<O> getValueNew(String name) throws SchemaException
- Throws:
SchemaException
-
create
public static ExpressionVariables create(PrismContext prismContext, Object... parameters)
Expects name-value-definition triples. Definition can be just a type QName. E.g. create(var1name, var1value, var1type, var2name, var2value, var2type, ...) Mostly for testing. Use at your own risk.
-
toString
public String toString()
- Overrides:
toString
in classVariablesMap
-
-