jodd.servlet
Class HttpSessionMap
java.lang.Object
java.util.AbstractMap<java.lang.String,java.lang.Object>
jodd.util.collection.StringKeyedMapAdapter
jodd.servlet.HttpSessionMap
- All Implemented Interfaces:
- java.util.Map<java.lang.String,java.lang.Object>
public class HttpSessionMap
- extends StringKeyedMapAdapter
Map backed by the Servlet session for accessing session scoped attributes.
| Nested classes/interfaces inherited from interface java.util.Map |
java.util.Map.Entry<K,V> |
|
Method Summary |
protected java.lang.Object |
getAttribute(java.lang.String key)
Hooks method that needs to be implemented by concrete subclasses. |
protected java.util.Iterator<java.lang.String> |
getAttributeNames()
Hook method that needs to be implemented by concrete subclasses. |
protected void |
removeAttribute(java.lang.String key)
Hooks method that needs to be implemented by concrete subclasses. |
protected void |
setAttribute(java.lang.String key,
java.lang.Object value)
Hooks method that needs to be implemented by concrete subclasses. |
| Methods inherited from class java.util.AbstractMap |
clone, containsKey, containsValue, equals, hashCode, isEmpty, keySet, putAll, size, toString, values |
| Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
HttpSessionMap
public HttpSessionMap(javax.servlet.http.HttpSession session)
HttpSessionMap
public HttpSessionMap(javax.servlet.http.HttpServletRequest request)
getAttribute
protected java.lang.Object getAttribute(java.lang.String key)
- Description copied from class:
StringKeyedMapAdapter
- Hooks method that needs to be implemented by concrete subclasses.
Gets a value associated with a key.
- Specified by:
getAttribute in class StringKeyedMapAdapter
setAttribute
protected void setAttribute(java.lang.String key,
java.lang.Object value)
- Description copied from class:
StringKeyedMapAdapter
- Hooks method that needs to be implemented by concrete subclasses.
Puts a key-value pair in the map, overwriting
any possible earlier value associated with the same key.
- Specified by:
setAttribute in class StringKeyedMapAdapter
removeAttribute
protected void removeAttribute(java.lang.String key)
- Description copied from class:
StringKeyedMapAdapter
- Hooks method that needs to be implemented by concrete subclasses.
Removes a key and its associated value from the
map.
- Specified by:
removeAttribute in class StringKeyedMapAdapter
getAttributeNames
protected java.util.Iterator<java.lang.String> getAttributeNames()
- Description copied from class:
StringKeyedMapAdapter
- Hook method that needs to be implemented by concrete subclasses.
Returns an enumeration listing all keys known to the map.
- Specified by:
getAttributeNames in class StringKeyedMapAdapter
Copyright © 2003-2012 Jodd Team