PreviousNext

The session Parameter

A session identifies the DUA and the suite of DSAs to which a particular directory operation is sent. It contains some DirectoryBindArguments, such as the distinguished name of the requestor. The session parameter is passed as the first parameter to most interface functions.

A session is described by an OM object of OM class DS_C_SESSION. It is created and appropriate parameter values can be set using the OM functions. A directory session then starts with ds_bind( ) and later terminates with ds_unbind( ). A session with default parameters can be started by passing the constant DS_DEFAULT_SESSION as the DS_C_SESSION parameter to ds_bind( ).

The ds_bind( ) function must be called before DS_C_SESSION can be used as a parameter to any other function in this interface. After ds_unbind( ) is called, ds_bind( ) must be called again if another session is to be started.

The interface supports multiple concurrent sessions so that an application implemented as a single process, such as a server in a client/server model, can interact with the directory by using several identities, and a process can interact directly and concurrently with different parts of the directory.

Details of the OM class DS_C_SESSION are given in XDS Class Definitions.