Class VariableStore<T extends CoreVariableInstance>
- java.lang.Object
-
- org.camunda.bpm.engine.impl.core.variable.scope.VariableStore<T>
-
public class VariableStore<T extends CoreVariableInstance> extends java.lang.Object- Author:
- Thorben Lindhauer
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceVariableStore.VariablesProvider<T extends CoreVariableInstance>static interfaceVariableStore.VariableStoreObserver<T extends CoreVariableInstance>
-
Field Summary
Fields Modifier and Type Field Description protected java.util.List<VariableStore.VariableStoreObserver<T>>observersprotected java.util.Map<java.lang.String,T>removedVariablesprotected java.util.Map<java.lang.String,T>variablesprotected VariableStore.VariablesProvider<T>variablesProvider
-
Constructor Summary
Constructors Constructor Description VariableStore()VariableStore(VariableStore.VariablesProvider<T> provider, VariableStore.VariableStoreObserver<T>... observers)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddObserver(VariableStore.VariableStoreObserver<T> observer)voidaddVariable(T value)booleancontainsKey(java.lang.String key)booleancontainsValue(T value)voidforceInitialization()java.util.Set<java.lang.String>getKeys()TgetRemovedVariable(java.lang.String name)TgetVariable(java.lang.String name)java.util.List<T>getVariables()java.util.List<T>getVariables(java.util.Collection<java.lang.String> variableNames)protected java.util.Map<java.lang.String,T>getVariablesMap()protected java.util.Map<java.lang.String,T>getVariablesMap(java.util.Collection<java.lang.String> variableNames)booleanisEmpty()booleanisInitialized()booleanisRemoved(java.lang.String variableName)voidremoveObserver(VariableStore.VariableStoreObserver<T> observer)TremoveVariable(java.lang.String variableName)voidremoveVariables()voidsetVariablesProvider(VariableStore.VariablesProvider<T> variablesProvider)The variables provider can be exchanged as long as the variables are not yet initializedvoidupdateVariable(T value)
-
-
-
Field Detail
-
variablesProvider
protected VariableStore.VariablesProvider<T extends CoreVariableInstance> variablesProvider
-
variables
protected java.util.Map<java.lang.String,T extends CoreVariableInstance> variables
-
removedVariables
protected java.util.Map<java.lang.String,T extends CoreVariableInstance> removedVariables
-
observers
protected java.util.List<VariableStore.VariableStoreObserver<T extends CoreVariableInstance>> observers
-
-
Constructor Detail
-
VariableStore
public VariableStore()
-
VariableStore
public VariableStore(VariableStore.VariablesProvider<T> provider, VariableStore.VariableStoreObserver<T>... observers)
-
-
Method Detail
-
setVariablesProvider
public void setVariablesProvider(VariableStore.VariablesProvider<T> variablesProvider)
The variables provider can be exchanged as long as the variables are not yet initialized
-
getVariablesMap
protected java.util.Map<java.lang.String,T> getVariablesMap()
-
getVariablesMap
protected java.util.Map<java.lang.String,T> getVariablesMap(java.util.Collection<java.lang.String> variableNames)
-
getRemovedVariable
public T getRemovedVariable(java.lang.String name)
-
getVariable
public T getVariable(java.lang.String name)
-
getVariables
public java.util.List<T> getVariables()
-
getVariables
public java.util.List<T> getVariables(java.util.Collection<java.lang.String> variableNames)
-
addVariable
public void addVariable(T value)
-
updateVariable
public void updateVariable(T value)
-
isEmpty
public boolean isEmpty()
-
containsValue
public boolean containsValue(T value)
-
containsKey
public boolean containsKey(java.lang.String key)
-
getKeys
public java.util.Set<java.lang.String> getKeys()
-
isInitialized
public boolean isInitialized()
-
forceInitialization
public void forceInitialization()
-
removeVariable
public T removeVariable(java.lang.String variableName)
-
removeVariables
public void removeVariables()
-
addObserver
public void addObserver(VariableStore.VariableStoreObserver<T> observer)
-
removeObserver
public void removeObserver(VariableStore.VariableStoreObserver<T> observer)
-
isRemoved
public boolean isRemoved(java.lang.String variableName)
-
-