ml_session_pool, ml_session_args, ml_session_sessionid, ml_session_canonical_path, ml_session_script_name - get monolith per-session information |
#include <monolith.h> pool ml_session_pool (ml_session); cgi ml_session_args (ml_session); const char *ml_session_sessionid (ml_session); const char *ml_session_canonical_path (ml_session); const char *ml_session_script_name (ml_session); |
These functions extract the information from the opaque ml_session object passed to most application functions and callbacks. Each separate user session is tied to a separate ml_session object which contains standard fields. |
ml_session_pool returns the session pool, which is a pool which has the lifetime of the whole session. |
ml_session_args returns the arguments (a cgi object) which were passed to the application when it started running. This is kind of equivalent to argc and argv for a traditional application. |
ml_session_sessionid returns the session ID, a 32 character string of random hex digits which also happens to be the cookie passed by the browser. |
ml_session_canonical_path returns the canonical path of the monolith application, that is, the full path of the application as it appears to the browser. For example /so-bin/app.so. |
ml_session_script_name returns just the name of the application as it appears to the browser. For example app.so. |
Richard Jones <rich@annexia.org> |
GNU LGPL (see http://www.gnu.org/) |
monolith-1.0.0 |
ml_entry_point(3), new_cgi(3). |