Roxen.git / server / base_server / module.pike

version» Context lines:

Roxen.git/server/base_server/module.pike:1:   // This file is part of Roxen WebServer.   // Copyright © 1996 - 2004, Roxen IS. - // $Id: module.pike,v 1.222 2005/10/06 12:43:31 wellhard Exp $ + // $Id: module.pike,v 1.223 2006/10/16 15:17:56 mast Exp $      #include <module_constants.h>   #include <module.h>   #include <request_trace.h>      constant __pragma_save_parent__ = 1;      inherit "basic_defvar";   mapping(string:array(int)) error_log=([]);   
Roxen.git/server/base_server/module.pike:39:    * module/configuration. And the reason for that is that if the    * messages are logged from subclasses in the module, the DWIM in    * roxenlib.pike cannot see that they are logged from a module. This    * solution is not really all that beautiful, but it works. :-)    */   void report_fatal( mixed ... args ) { predef::report_fatal( @args ); }   void report_error( mixed ... args ) { predef::report_error( @args ); }   void report_notice( mixed ... args ) { predef::report_notice( @args ); }   void report_debug( mixed ... args ) { predef::report_debug( @args ); }    + void log_event (string facility, string action, string resource, +  void|mapping(string:mixed) info) + //! Log an event. See @[Configuration.log_event] for details. + //! + //! @[facility] may be zero. The local module identifier as returned + //! by @[module_local_id] is used as facility in that case. + { +  _my_configuration->log_event (facility || _module_local_identifier, +  action, resource, info); + }      string module_identifier()   //! Returns a string that uniquely identifies this module instance   //! within the server. The identifier is the same as   //! @[Roxen.get_module] and @[Roxen.get_modname] handles.   {   #if 1    return _module_identifier;   #else    if (!_module_identifier) {