Class UserVariables
- java.lang.Object
-
- java.util.AbstractMap<K,V>
-
- java.util.HashMap<String,Object>
-
- com.opencloud.slee.resources.sis.script.interceptors.UserVariables
-
- All Implemented Interfaces:
Serializable,Cloneable,Map<String,Object>
public final class UserVariables extends HashMap<String,Object>
A collection of user variables, mapping from variable name to variable value.This class is a simple extension of
HashMapthat enforces all keys to begin with the string"user."(case insensitive).- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K extends Object,V extends Object>, AbstractMap.SimpleImmutableEntry<K extends Object,V extends Object>
-
-
Constructor Summary
Constructors Constructor Description UserVariables()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Objectput(String name, Object value)Associates the specified value with the user variable with the specified name in this map.-
Methods inherited from class java.util.HashMap
clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
-
Methods inherited from class java.util.AbstractMap
equals, hashCode, toString
-
-
-
-
Method Detail
-
put
public Object put(String name, Object value)
Associates the specified value with the user variable with the specified name in this map. If the map previously contained a mapping for the name, the old value is replaced.- Specified by:
putin interfaceMap<String,Object>- Overrides:
putin classHashMap<String,Object>- Parameters:
name- user variable name with which the specified value is to be associated. This name cannot benulland must begin with the string"user."(case insensitive).value- value to be associated with the specified user variable name. Cannot benull.- Returns:
- the previous value associated with
name, ornullif there was no previous mapping forname. - Throws:
NullPointerException- if either argument isnull.IllegalArgumentException- ifnamedoes not begin with the string"user."(ignoring case).
-
-