Class to manage objects that are registered as session data. Objects to be registered as session data need to be created from classes that are inherited from this class. Write the timeout processing in the method obtained by overriding the SWEEP-SESSION method defined in this class by using the OVERRIDE clause.
Note
Timeout processing can be used only if an object reference is registered in the session data.
In timeout processing method, ISAPI Subroutines cannot be called.
Factory method
None
Object method
Method called when the timeout of a session occurs. This method is used to close files or to perform DB commit/rollback processing as required.
Method argument
None
Method return information
None
When the timeout of a session occurs, ISAPI Subroutines call the SWEEP-SESSION method to assign a NULL object to the object reference registered in the session data.
If the SWEEP-SESSION method is not defined by overriding it, the SWEEP-SESSION method performs no processing.
The COBW3-SESSION-ADAPTER class is a class that inherits the FJBASE class.
Example
COBOL program
IDENTIFICATION DIVISION. CLASS-ID. SESSDATA INHERITS COBW3-SESSION-ADAPTER. : IDENTIFICATION DIVISION. OBJECT. : IDENTIFICATION DIVISION. METHOD-ID. SWEEP-SESSION OVERRIDE. DATA DIVISION. : PROCEDURE DIVISION. : * Write the timeout processing as required. : END METHOD SWEEP-SESSION. : END OBJECT. END CLASS SESSDATA.