Top
NetCOBOL V11.0 ISAPI Subroutines User's Guide
FUJITSU Software

3.11.3 COBW3_SET_SESSION_DATA

This subroutine registers the session data to be used in the current session. The registered session data is shared in the same session.

Note

Call this subroutine while a session is open. If this subroutine is called before a session is started or after a session is terminated, session data cannot be registered.

The format of session data cannot be changed while a session is open. Register session data matching the format of the session data set when "COBW3_START_SESSION" was called.

How to write

CALL "COBW3_SET_SESSION_DATA" USING COBW3 session data.

Data setting for calling

COBW3-SESSION-DATA-SIZE

Specify the session data length (byte length). This specification is valid only if COBW3-SESSION-DATA-GROUPITEM is set as the format of session data when a session is started.

Value

Meaning

1 to 999999999

Registers session data with the specified data length.

Session data

Specify the session data to be registered. Specify the group item or object reference item matching the format of the session data when a session was started.

Note

When specifying a group item as the session data, a group item containing an object reference item or pointer data item as a subordinate basic item cannot be specified.

When specifying an object reference item as the session data, the class of the object pointed by the object reference item must have inherited the COBW3-SESSION-ADAPTER class.

If an object reference item is specified as the session data, be sure to assign a NULL object to the object reference item before the thread terminates. If the NULL object is not assigned, an object that is referenced from nowhere may remain in memory after the session terminates, leading to memory shortage.

When the session data is registered, the actual contents of the registered data are held if the data is a group item. If session data is an object reference item, objects are held.

If the session data to be registered is in a different format from that set when a session was opened, operations of Web applications cannot be guaranteed.

Processing result data

None