|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--jasp.buildin.Session
You can use the Session object to store information needed for
a particular user-session. Variables stored in the Session object
are not discarded when the user jumps between pages in the
application; instead, these variables persist for the entire user-session.
The Web server automatically creates a Session object when a Web page
from the application is requested by a user who does not already have a
session. The server destroys the Session object when the session expires
or is abandoned. One common use for the Session object is to store user
preferences. For example, if a user indicates that they prefer not to
view graphics, you could store that information in the Session object.
For more information on using the Session object, see Managing Sessions
in the ASP Applications section.
Note: Session state is only maintained for browsers that support cookies.
Constructor Summary | |
Session()
|
Method Summary | |
static void |
Abandon()
Abandon This method destroys a Session object and releases its resources. |
static IVariantDictionary |
Contents()
Contains the items that you have added to the session with script commands. |
static variant |
Contents(java.lang.String key)
Gets an item from the Contents collection. |
static int |
getCodePage()
Determines the codepage that will be used to display dynamic content. |
static java.lang.String |
getEncode()
Returns the EncodeCharSet |
static variant |
getItem(java.lang.String key)
Adds an item to the Contents collection |
static long |
getLCID()
Determines the location identifier that will be used to display dynamic content. |
static java.lang.String |
getSessionID()
Gets the sessionid |
static int |
getTimeout()
Specifies the timeout period assigned to the Session object for this Application, in minutes. |
static boolean |
isAbandon()
Gets true if the Abandon method is called. |
static boolean |
isTimeout()
Return true if the Session was timeout. |
static jasp.buildin.ASPSession |
session()
Returns a Session object instance |
static void |
setCodePage(int codepage)
|
static void |
setContents(java.lang.String key,
variant obj)
Sets an item to Contents collection. |
static void |
setEncode(java.lang.String str)
Sets the EncodeCharset. |
static void |
setItem(java.lang.String key,
boolean value)
Adds an item to the Contents collection |
static void |
setItem(java.lang.String key,
double value)
Adds an item to the Contents collection |
static void |
setItem(java.lang.String key,
int value)
Adds an item to the Contents collection |
static void |
setItem(java.lang.String key,
java.lang.Object value)
Adds an item to the Contents collection |
static void |
setItem(java.lang.String key,
java.lang.String value)
Adds an item to the Contents collection |
static void |
setLCID(int lcid)
Sets the lcid |
static void |
setObject(java.lang.String key,
java.lang.Object obj)
Adds an item to the Contents collection. Note: The value of the item is an object, for example: set Session("test") = Server.CreateObject("ADODB.REcordset") |
static void |
setTimeout(int timeout)
The Timeout property specifies the timeout period assigned to the Session object for this application, in minutes. |
static IVariantDictionary |
StaticObjects()
Contains the objects created with the <OBJECT> tag and given session scope. |
static variant |
StaticObjects(java.lang.String key)
Gets Gets an item from the StaticObjects collection. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Session()
Method Detail |
public static jasp.buildin.ASPSession session()
public static IVariantDictionary Contents()
public static IVariantDictionary StaticObjects()
public static variant StaticObjects(java.lang.String key)
key
- the name of the memberpublic static variant Contents(java.lang.String key)
key
- the name of the itempublic static void setContents(java.lang.String key, variant obj)
key
- the name of the itemthe
- value of the item.public static void Abandon() throws java.lang.Exception
public static boolean isAbandon()
public static boolean isTimeout()
public static variant getItem(java.lang.String key)
key
- the name of the item.public static void setItem(java.lang.String key, java.lang.Object value) throws java.lang.Exception
public static void setItem(java.lang.String key, int value)
public static void setItem(java.lang.String key, double value)
public static void setItem(java.lang.String key, boolean value)
public static void setItem(java.lang.String key, java.lang.String value)
public static void setObject(java.lang.String key, java.lang.Object obj) throws java.lang.Exception
public static java.lang.String getSessionID()
public static void setEncode(java.lang.String str)
public static java.lang.String getEncode()
public static int getTimeout()
public static void setTimeout(int timeout)
timeout
- the new timeout value.public static int getCodePage()
public static void setCodePage(int codepage)
public static long getLCID()
public static void setLCID(int lcid)
lcid
- the new lcid
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |