public final class VariableMap extends Object
VariableName
s as input parameters.Modifier and Type | Class and Description |
---|---|
static class |
VariableMap.Builder
Builder for a VariableMap instance.
|
Modifier and Type | Method and Description |
---|---|
static VariableMap.Builder |
builder()
Creates a builder for a new VariableMap instance.
|
static VariableMap.Builder |
builder(VariableMap template)
Creates a builder for a new VariableMap instance and applies the given template.
|
Map<String,Object> |
getVariables()
Returns the held variables represented as key/value pairs.
|
static VariableMap |
of()
Creates an empty VariableMap.
|
static VariableMap |
of(Map<String,Object> variables)
Creates a VariableMap based on the specified map of variables.
|
static VariableMap |
of(String name,
Object value)
Creates a new VariableMap with a single entry based on the given name and value.
|
static VariableMap |
of(String name1,
Object value1,
String name2,
Object value2)
Creates a new VariableMap with two entries based on the given sequence of name/value.
|
static VariableMap |
of(String name1,
Object value1,
String name2,
Object value2,
String name3,
Object value3)
Creates a new VariableMap with three entries based on the given sequence of name/value.
|
static <V> VariableMap |
of(VariableName<V,?> name,
V value)
Creates a new VariableMap with a single entry based on the given name and value.
|
static <V1,V2> VariableMap |
of(VariableName<V1,?> name1,
V1 value1,
VariableName<V2,?> name2,
V2 value2)
Creates a new VariableMap with two entries based on the given sequence of name/value.
|
static <V1,V2,V3> VariableMap |
of(VariableName<V1,?> name1,
V1 value1,
VariableName<V2,?> name2,
V2 value2,
VariableName<V3,?> name3,
V3 value3)
Creates a new VariableMap with three entries based on the given sequence of name/value.
|
public Map<String,Object> getVariables()
public static VariableMap of()
public static VariableMap of(Map<String,Object> variables)
variables
- the map of variables to addpublic static <V> VariableMap of(VariableName<V,?> name, V value)
V
- the expected transient type of the variablename
- the name of the variablevalue
- the value of the variablepublic static <V1,V2> VariableMap of(VariableName<V1,?> name1, V1 value1, VariableName<V2,?> name2, V2 value2)
V1
- the expected transient type of the first variableV2
- the expected transient type of the second variablename1
- the name of the first variablevalue1
- the value of the first variablename2
- the name of the second variablevalue2
- the value of the second variablepublic static <V1,V2,V3> VariableMap of(VariableName<V1,?> name1, V1 value1, VariableName<V2,?> name2, V2 value2, VariableName<V3,?> name3, V3 value3)
V1
- the expected transient type of the first variableV2
- the expected transient type of the second variableV3
- the expected transient type of the third variablename1
- the name of the first variablevalue1
- the value of the first variablename2
- the name of the second variablevalue2
- the value of the second variablename3
- the name of the third variablevalue3
- the value of the third variablepublic static VariableMap of(String name, Object value)
name
- the name of the variablevalue
- the value of the variablepublic static VariableMap of(String name1, Object value1, String name2, Object value2)
name1
- the name of the first variablevalue1
- the value of the first variablename2
- the name of the second variablevalue2
- the value of the second variablepublic static VariableMap of(String name1, Object value1, String name2, Object value2, String name3, Object value3)
name1
- the name of the first variablevalue1
- the value of the first variablename2
- the name of the second variablevalue2
- the value of the second variablename3
- the name of the third variablevalue3
- the value of the third variablepublic static VariableMap.Builder builder()
public static VariableMap.Builder builder(VariableMap template)
template
- the variable map templateCopyright © 2010 - 2018 edorasware ag. All Rights Reserved.