Eliom_state.Session_admin(3) no description

Module

Module Eliom_state.Session_admin

Documentation

Module Session_admin
 :  sig end

type timeout =
 | TGlobal  (* see global setting *)
 | TNone  (* explicitly set no timeout *)
 | TSome of float
 

Type used to describe session timeouts

type service_session

timeout duration in seconds

type data_session

type persistent_session

val close_service_session : ?close_group:bool -> session:service_session -> unit

val close_volatile_data_session : ?close_group:bool -> session:data_session -> unit

val close_persistent_data_session : ?close_group:bool -> session:persistent_session -> unit Lwt.t

val get_volatile_session_data : session:data_session -> table:'a Eliom_state.volatile_table -> 'a

Raises Not_found if no data in the table for the session.

val get_persistent_session_data : session:persistent_session -> table:'a Eliom_state.persistent_table -> 'a Lwt.t

Fails with lwt exception Not_found if no data in the table for the session.

val remove_volatile_session_data : session:data_session -> table:'a Eliom_state.volatile_table -> unit

val remove_persistent_session_data : session:persistent_session -> table:'a Eliom_state.persistent_table -> unit Lwt.t

val get_service_scope_name : session:service_session -> Eliom_common.scope_name

val get_volatile_data_scope_name : session:data_session -> Eliom_common.scope_name

val get_persistent_data_scope_name : session:persistent_session -> Eliom_common.scope_name

val get_service_session_cookie_scope : session:service_session -> Eliom_common.cookie_scope

val get_volatile_data_session_cookie_scope : session:data_session -> Eliom_common.cookie_scope

val get_persistent_data_session_cookie_scope : session:persistent_session -> Eliom_common.cookie_scope

val set_service_session_timeout : session:service_session -> float option -> unit

val set_volatile_data_session_timeout : session:data_session -> float option -> unit

val set_persistent_data_session_timeout : session:persistent_session -> float option -> unit Lwt.t

val get_service_session_timeout : session:service_session -> timeout

val get_volatile_data_session_timeout : session:data_session -> timeout

val get_persistent_data_session_timeout : session:persistent_session -> timeout

val unset_service_session_timeout : session:service_session -> unit

val unset_volatile_data_session_timeout : session:data_session -> unit

val unset_persistent_data_session_timeout : session:persistent_session -> unit Lwt.t

val iter_service_sessions : (service_session -> unit Lwt.t) -> unit Lwt.t

Iterator on service sessions. Lwt_unix.yield is called automatically after each iteration.

val iter_volatile_data_sessions : (data_session -> unit Lwt.t) -> unit Lwt.t

Iterator on data sessions. Lwt_unix.yield is called automatically after each iteration.

val iter_persistent_data_sessions : (persistent_session -> unit Lwt.t) -> unit Lwt.t

Iterator on persistent sessions. Lwt_unix.yield is called automatically after each iteration.

val fold_service_sessions : (service_session -> 'a -> 'a Lwt.t) -> 'a -> 'a Lwt.t

Iterator on service sessions. Lwt_unix.yield is called automatically after each iteration.

val fold_volatile_data_sessions : (data_session -> 'a -> 'a Lwt.t) -> 'a -> 'a Lwt.t

Iterator on data sessions. Lwt_unix.yield is called automatically after each iteration.

val fold_persistent_data_sessions : (persistent_session -> 'a -> 'a Lwt.t) -> 'a -> 'a Lwt.t

Iterator on persistent sessions. Lwt_unix.yield is called automatically after each iteration.