Software: Apache/2.0.54 (Fedora). PHP/5.0.4 uname -a: Linux mina-info.me 2.6.17-1.2142_FC4smp #1 SMP Tue Jul 11 22:57:02 EDT 2006 i686 uid=48(apache) gid=48(apache) groups=48(apache) Safe-mode: OFF (not secure) /usr/share/gtk-doc/html/glib/ drwxr-xr-x |
Viewing file: Select action/file-type:
Synopsis#include <glib.h> #define G_LOG_DOMAIN #define G_LOG_FATAL_MASK #define G_LOG_LEVEL_USER_SHIFT void (*GLogFunc) (const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer user_data); enum GLogLevelFlags; void g_log (const gchar *log_domain, GLogLevelFlags log_level, const gchar *format, ...); void g_logv (const gchar *log_domain, GLogLevelFlags log_level, const gchar *format, va_list args); #define g_message (...) #define g_warning (...) #define g_critical (...) #define g_error (...) #define g_debug (...) guint g_log_set_handler (const gchar *log_domain, GLogLevelFlags log_levels, GLogFunc log_func, gpointer user_data); void g_log_remove_handler (const gchar *log_domain, guint handler_id); GLogLevelFlags g_log_set_always_fatal (GLogLevelFlags fatal_mask); GLogLevelFlags g_log_set_fatal_mask (const gchar *log_domain, GLogLevelFlags fatal_mask); void g_log_default_handler (const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer unused_data); GLogFunc g_log_set_default_handler (GLogFunc log_func, gpointer user_data); DescriptionThese functions provide support for logging error messages or messages used for debugging. There are several built-in levels of messages, defined in GLogLevelFlags. These can be extended with user-defined levels. DetailsG_LOG_DOMAIN#define G_LOG_DOMAIN ((gchar*) 0)
Defines the log domain.
For applications, this is typically left as the default For example, GTK+ uses this in its Makefile.am: INCLUDES = -DG_LOG_DOMAIN=\"Gtk\" G_LOG_FATAL_MASK#define G_LOG_FATAL_MASK (G_LOG_FLAG_RECURSION | G_LOG_LEVEL_ERROR) GLib log levels that are considered fatal by default. G_LOG_LEVEL_USER_SHIFT#define G_LOG_LEVEL_USER_SHIFT (8) Log level shift offset for user defined log levels (0-7 are used by GLib). GLogFunc ()void (*GLogFunc) (const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer user_data); Specifies the prototype of log handler functions.
enum GLogLevelFlagstypedef enum { /* log flags */ G_LOG_FLAG_RECURSION = 1 << 0, G_LOG_FLAG_FATAL = 1 << 1, /* GLib log levels */ G_LOG_LEVEL_ERROR = 1 << 2, /* always fatal */ G_LOG_LEVEL_CRITICAL = 1 << 3, G_LOG_LEVEL_WARNING = 1 << 4, G_LOG_LEVEL_MESSAGE = 1 << 5, G_LOG_LEVEL_INFO = 1 << 6, G_LOG_LEVEL_DEBUG = 1 << 7, G_LOG_LEVEL_MASK = ~(G_LOG_FLAG_RECURSION | G_LOG_FLAG_FATAL) } GLogLevelFlags; Flags specifying the level of log messages. g_log ()void g_log (const gchar *log_domain, GLogLevelFlags log_level, const gchar *format, ...);
Logs an error or debugging message.
If the log level has been set as fatal, the
g_logv ()void g_logv (const gchar *log_domain, GLogLevelFlags log_level, const gchar *format, va_list args);
Logs an error or debugging message.
If the log level has been set as fatal, the
g_message()#define g_message(...) A convenience function/macro to log a normal message.
g_warning()#define g_warning(...) A convenience function/macro to log a warning message.
g_critical()#define g_critical(...)
Logs a "critical warning" (G_LOG_LEVEL_CRITICAL). It's more or less
application-defined what constitutes a critical vs. a regular
warning. You could call
g_error()#define g_error(...)
A convenience function/macro to log an error message.
Error messages are always fatal, resulting in a call to
g_debug()#define g_debug(...) A convenience function/macro to log a debug message.
Since 2.6 g_log_set_handler ()guint g_log_set_handler (const gchar *log_domain, GLogLevelFlags log_levels, GLogFunc log_func, gpointer user_data);
Sets the log handler for a domain and a set of log levels.
To handle fatal and recursive messages the Note that since the G_LOG_LEVEL_ERROR log level is always fatal, if you want to set a handler for this log level you must combine it with G_LOG_FLAG_FATAL. Example 13. Adding a log handler for all warning messages in the default (application) domain g_log_set_handler (NULL, G_LOG_LEVEL_WARNING | G_LOG_FLAG_FATAL | G_LOG_FLAG_RECURSION, my_log_handler, NULL); Example 14. Adding a log handler for all critical messages from GTK+ g_log_set_handler ("Gtk", G_LOG_LEVEL_CRITICAL | G_LOG_FLAG_FATAL | G_LOG_FLAG_RECURSION, my_log_handler, NULL); Example 15. Adding a log handler for all messages from GLib g_log_set_handler ("GLib", G_LOG_LEVEL_MASK | G_LOG_FLAG_FATAL | G_LOG_FLAG_RECURSION, my_log_handler, NULL);
g_log_remove_handler ()void g_log_remove_handler (const gchar *log_domain, guint handler_id); Removes the log handler.
g_log_set_always_fatal ()GLogLevelFlags g_log_set_always_fatal (GLogLevelFlags fatal_mask);
Sets the message levels which are always fatal, in any log domain.
When a message with any of these levels is logged the program terminates.
You can only set the levels defined by GLib to be fatal.
g_log_set_fatal_mask ()GLogLevelFlags g_log_set_fatal_mask (const gchar *log_domain, GLogLevelFlags fatal_mask);
Sets the log levels which are fatal in the given domain.
g_log_default_handler ()void g_log_default_handler (const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer unused_data);
The default log handler set up by GLib;
stderr is used for levels
g_log_set_default_handler ()GLogFunc g_log_set_default_handler (GLogFunc log_func, gpointer user_data);
Installs a default log handler which is used is used if no
log handler has been set for the particular log domain
and log level combination. By default, GLib uses
Since 2.6
|
:: Command execute :: | |
--[ c99shell v. 1.0 pre-release build #16 powered by Captain Crunch Security Team | http://ccteam.ru | Generation time: 0.0039 ]-- |