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 interface
VariableStore.VariablesProvider<T extends CoreVariableInstance>
static interface
VariableStore.VariableStoreObserver<T extends CoreVariableInstance>
-
Field Summary
Fields Modifier and Type Field Description protected java.util.List<VariableStore.VariableStoreObserver<T>>
observers
protected java.util.Map<java.lang.String,T>
removedVariables
protected java.util.Map<java.lang.String,T>
variables
protected 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 void
addObserver(VariableStore.VariableStoreObserver<T> observer)
void
addVariable(T value)
boolean
containsKey(java.lang.String key)
boolean
containsValue(T value)
void
forceInitialization()
java.util.Set<java.lang.String>
getKeys()
T
getRemovedVariable(java.lang.String name)
T
getVariable(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)
boolean
isEmpty()
boolean
isInitialized()
boolean
isRemoved(java.lang.String variableName)
void
removeObserver(VariableStore.VariableStoreObserver<T> observer)
T
removeVariable(java.lang.String variableName)
void
removeVariables()
void
setVariablesProvider(VariableStore.VariablesProvider<T> variablesProvider)
The variables provider can be exchanged as long as the variables are not yet initializedvoid
updateVariable(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)
-
-