Class MockSession
- java.lang.Object
-
- de.hybris.platform.servicelayer.session.impl.DefaultSession
-
- de.hybris.platform.servicelayer.session.MockSession
-
- All Implemented Interfaces:
Session,java.io.Serializable
public class MockSession extends DefaultSession
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MockSession()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <T> java.util.Map<java.lang.String,T>getAllAttributes()<T> TgetAttribute(java.lang.String name)Returns for the given session attribute name the valuejava.lang.StringgetSessionId()voidsetAttribute(java.lang.String name, java.lang.Object value)Sets the given value Object to the Session as attribute with the given name-
Methods inherited from class de.hybris.platform.servicelayer.session.impl.DefaultSession
equals, getJaloSession, hashCode, init, removeAttribute, setJaloSession
-
-
-
-
Method Detail
-
getSessionId
public java.lang.String getSessionId()
- Specified by:
getSessionIdin interfaceSession- Overrides:
getSessionIdin classDefaultSession- Returns:
- the id of the session
-
getAllAttributes
public <T> java.util.Map<java.lang.String,T> getAllAttributes()
- Specified by:
getAllAttributesin interfaceSession- Overrides:
getAllAttributesin classDefaultSession- Returns:
- a Map with all session attributes
-
getAttribute
public <T> T getAttribute(java.lang.String name)
Description copied from interface:SessionReturns for the given session attribute name the value- Specified by:
getAttributein interfaceSession- Overrides:
getAttributein classDefaultSession- Parameters:
name- the attribute name- Returns:
nullif no attribute with the given name is stored in the session
-
setAttribute
public void setAttribute(java.lang.String name, java.lang.Object value)Description copied from interface:SessionSets the given value Object to the Session as attribute with the given name- Specified by:
setAttributein interfaceSession- Overrides:
setAttributein classDefaultSession- Parameters:
name- the name of the attributevalue- the value to be set
-
-