|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ObjectSession
public class Session
Utility functions to store and access variables in the user's session. Also provides functions that can be called to check whether session tracking is enabled, and map URLs.
Constructor Summary | |
---|---|
Session()
|
Method Summary | |
---|---|
static String |
encodeURL(XPathContext context,
String origURL)
Function to encode a URL, adding session ID if necessary. |
static Value |
getData(XPathContext context,
String name)
Function to get a data from a session variable. |
static String |
getID()
Function to get the current session's identifier |
static String |
getString(XPathContext context,
Value value)
Gets a proper string for the value. |
private static Value |
getValue(XPathContext context,
String str)
Checks if the input string is actually an XML document. |
static boolean |
isEnabled(XPathContext context)
Checks whether session tracking was enabled in the servlet config |
static boolean |
noCookie()
Function to detect if cookies are turned off |
static void |
setData(XPathContext context,
String name,
String value)
Function to put data into a session variable. |
static void |
setData(XPathContext context,
String name,
Value value)
Function to put structured data into a session variable. |
Methods inherited from class Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Session()
Method Detail |
---|
public static boolean isEnabled(XPathContext context)
public static Value getData(XPathContext context, String name) throws XPathException
XPathException
public static void setData(XPathContext context, String name, Value value) throws XPathException
XPathException
public static void setData(XPathContext context, String name, String value)
public static String encodeURL(XPathContext context, String origURL)
public static String getID()
public static boolean noCookie()
public static String getString(XPathContext context, Value value) throws XPathException
context
- Context for the evaluation
XPathException
private static Value getValue(XPathContext context, String str) throws XPathException
str
- The string to check.
XPathException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |