public interface Session extends Serializable
Modifier and Type | Method and Description |
---|---|
void |
addEISCookie(org.apache.http.cookie.Cookie cookie)
Adds the cookie to the session.
|
void |
addEISCookie(String name,
String value)
Adds the cookie to the session.
|
void |
addEISCookie(String name,
String value,
String path,
String domain,
boolean secure)
Adds the cookie to the session.
|
void |
addEISCookie(String name,
String value,
String path,
String domain,
boolean secure,
Date expiryDate)
Adds the cookie to the session.
|
void |
addEISCookies(List<org.apache.http.cookie.Cookie> cookieList)
Adds the list of cookies to the session.
|
boolean |
containsKey(String name)
Gets whether an attribute (an Object scoped to this session) exists or not.
|
Object |
getAttribute(String name)
Gets an attribute value, an Object previously stored in the scope of this
session.
|
Enumeration<?> |
getAttributeNames()
Gets name of all the attributes stored in the scope of this session.
|
long |
getCreationTime()
Gets the session creation time.
|
org.apache.http.cookie.Cookie |
getEISCookieByName_Domain_Path(String name,
String domain,
String path)
Gets the cookie with the specified name, domain and path.
|
org.apache.http.cookie.Cookie |
getEISCookieByName(String name)
Gets the cookie with the specified name from the session.
|
List<org.apache.http.cookie.Cookie> |
getEISCookies()
Gets a read-only copy of list of cookies present in this session.
|
String |
getId()
Gets the session Id.
|
long |
getLastAccessedTime()
Gets the time when the session was last accessed.
|
long |
getMaxInactiveInterval()
Gets the maximum time the session can be inactive.
|
void |
invalidate()
Invalidates the session.
|
void |
removeAttribute(String name)
Removes the specified attribute from session, if a attribute by that name
exists.
|
void |
removeEISCookieFromSession(org.apache.http.cookie.Cookie cookie)
Remove the cookie from the session cookies.
|
void |
removeEISCookiesFromSession(List<org.apache.http.cookie.Cookie> cookies)
Removes all the cookies in the list from the session cookies.
|
void |
setAttribute(String name,
Object value)
Sets an attribute value, an Object storied in the scope of this session.
|
void |
setMaxInactiveInterval(int interval)
Sets the maximum inactive interval to the specified value.
|
Object getAttribute(String name)
name
- The attribute namelong getCreationTime()
String getId()
long getLastAccessedTime()
long getMaxInactiveInterval()
void invalidate()
void removeAttribute(String name)
name
- The name of the attribute to removevoid setAttribute(String name, Object value)
name
- The attribute namevalue
- The attribute valuevoid setMaxInactiveInterval(int interval)
interval
- The intervalboolean containsKey(String name)
name
- The attribute namegetAttribute(String)
,
setAttribute(String, Object)
Enumeration<?> getAttributeNames()
List<org.apache.http.cookie.Cookie> getEISCookies()
org.apache.http.cookie.Cookie getEISCookieByName(String name)
name
- The name of the cookie to getorg.apache.http.cookie.Cookie getEISCookieByName_Domain_Path(String name, String domain, String path)
name
- The name of the cookie to getdomain
- The domain of the cookie to getpath
- The path of the cookie to getvoid addEISCookies(List<org.apache.http.cookie.Cookie> cookieList)
cookieList
- The list of cookies to addvoid addEISCookie(org.apache.http.cookie.Cookie cookie)
cookie
- The cookie to addvoid addEISCookie(String name, String value)
name
- The name of the cookie to addvalue
- The value of the cookie to addvoid addEISCookie(String name, String value, String path, String domain, boolean secure)
name
- The name of the cookie to addvalue
- The value of the cookie to addpath
- The path of the cookie to adddomain
- The domain of the cookie to addsecure
- Whether the cookie is secure or notvoid addEISCookie(String name, String value, String path, String domain, boolean secure, Date expiryDate)
name
- The name of the cookie to addvalue
- The value of the cookie to addpath
- The path of the cookie to adddomain
- The domain of the cookie to addsecure
- Whether the cookie is secure or notexpiryDate
- The expiry date of the cookie to addvoid removeEISCookieFromSession(org.apache.http.cookie.Cookie cookie)
cookie
- The cookie to removevoid removeEISCookiesFromSession(List<org.apache.http.cookie.Cookie> cookies)
cookies
- The list of cookies to removeCopyright © 2019. All rights reserved.