IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 9, 2004, 3:55:34 PM (22 years ago)
Author:
desonia
Message:

more doxygen-related cleanup

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/sysUtils/psLogMsg.h

    r1441 r1448  
    1212 *  @author George Gusciora, MHPCC
    1313 *
    14  *  @version $Revision: 1.15 $ $Name: not supported by cvs2svn $
    15  *  @date $Date: 2004-08-09 23:40:55 $
     14 *  @version $Revision: 1.16 $ $Name: not supported by cvs2svn $
     15 *  @date $Date: 2004-08-10 01:55:34 $
    1616 *
    1717 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    2020#define PS_LOG_MSG_H
    2121#include <stdarg.h>
     22#include <stdbool.h>
    2223
    2324/** @addtogroup LogTrace
     
    2526 */
    2627
    27 /// This procedure sets the destination for future log messages.  Currently
    28 /// the destination is specified by an integer which can have the following
    29 /// pre-defined values: PS_LOG_NONE, PS_LOG_TO_STDOUT, and PS_LOG_TO_STDERR.
    30 /// In future versions, this procedure will take a character string as an
    31 /// argument which can specify more general log destinations.
    32 int psLogSetDestination(const char *dest        ///< Specifies where to send messages.
    33                        );
     28/** This procedure sets the destination for future log messages.  Currently
     29 *  the destination is specified by an integer which can have the following
     30 *  pre-defined values: PS_LOG_NONE, PS_LOG_TO_STDOUT, and PS_LOG_TO_STDERR.
     31 *  In future versions, this procedure will take a character string as an
     32 *  argument which can specify more general log destinations.
     33 *
     34 *  @return int     true if set successfully, otherwise false.
     35 */
     36bool psLogSetDestination(
     37    const char *dest                   ///< Specifies where to send messages.
     38);
    3439
    35 /// This procedure sets the message level for future log messages.  Subsequent
    36 /// log messages, with a log level of "mylevel", will only be logged if
    37 /// "mylevel" is less than the current log level set by this procedure.
    38 /// Ie. higher values set by this procedure will cause more log messages to
    39 /// be displayed.
    40 int psLogSetLevel(int level     ///< Specifies the system log level
    41                  );
     40/** This procedure sets the message level for future log messages.  Subsequent
     41 *  log messages, with a log level of "mylevel", will only be logged if
     42 *  "mylevel" is less than the current log level set by this procedure.
     43 *  Ie. higher values set by this procedure will cause more log messages to
     44 *  be displayed.
     45 *
     46 *  @return int    old logging level
     47 */
     48int psLogSetLevel(
     49    int level                          ///< Specifies the system log level
     50);
    4251
    43 /// This procedure sets the log format for future log messages.  The argument
    44 /// must be a character string consistsing of the letters H (host), L
    45 /// (level), M (message), N (name), and T (time).  The default is "THLNM".
    46 /// Deleting a letter from the string will cause the associated information
    47 /// to not be logged.
    48 void psLogSetFormat(const char *fmt     ///< Specifies the system log format
    49                    );
     52/** This procedure sets the log format for future log messages.  The argument
     53 *  must be a character string consistsing of the letters H (host), L
     54 *  (level), M (message), N (name), and T (time).  The default is "THLNM".
     55 *  Deleting a letter from the string will cause the associated information
     56 *  to not be logged.
     57 *
     58 */
     59void psLogSetFormat(
     60    const char *fmt                    ///< Specifies the system log format
     61);
    5062
    51 /// This procedure logs a message to the destination set by a prior
    52 /// call to psLogSetDestination(), if myLevel is less than the level
    53 /// specified by a prior call to psLogSetLevel().  The message is specified
    54 /// with a printf-stype string an arguments.
    55 void psLogMsg(const char *name, ///< name of the log source
    56               int myLevel,      ///< severity level of this log message
    57               const char *fmt, ...      ///< printf-style format command
    58              );
     63/** This procedure logs a message to the destination set by a prior
     64 *  call to psLogSetDestination(), if myLevel is less than the level
     65 *  specified by a prior call to psLogSetLevel().  The message is specified
     66 *  with a printf-stype string an arguments.
     67 *
     68 */
     69void psLogMsg(
     70    const char *name,                  ///< name of the log source
     71    int myLevel,                       ///< severity level of this log message
     72    const char *fmt,                   ///< printf-style format command
     73    ...
     74);
    5975
    60 /// This procedure is functionally equivalent to psLogMsg(), except that
    61 /// it takes a va_list as the message parameter, not a printf-style string.
    62 void psLogMsgV(const char *name,        ///< name of the log source
    63                int myLevel,     ///< severity level of this log message
    64                const char *fmt, ///< printf-style format command
    65                va_list ap       ///< varargs argument list
    66               );
     76/** This procedure is functionally equivalent to psLogMsg(), except that
     77 *  it takes a va_list as the message parameter, not a printf-style string.
     78 *
     79 */
     80void psLogMsgV(
     81    const char *name,                  ///< name of the log source
     82    int myLevel,                       ///< severity level of this log message
     83    const char *fmt,                   ///< printf-style format command
     84    va_list ap                         ///< varargs argument list
     85);
    6786
    6887///< Status codes for log messages
    6988enum {
    70     PS_LOG_ABORT = 0,
    71     PS_LOG_ERROR,
    72     PS_LOG_WARN,
    73     PS_LOG_INFO
     89    PS_LOG_ABORT = 0,                  ///< log message is a critical error, perform an abort after printing
     90    PS_LOG_ERROR,                      ///< log message is an error, but don't abort
     91    PS_LOG_WARN,                       ///< log message is a warning
     92    PS_LOG_INFO                        ///< log message is informational only
    7493};
    7594
    7695///< Destinations for log messages
    7796enum {
    78     PS_LOG_NONE,
    79     PS_LOG_TO_STDERR,
    80     PS_LOG_TO_STDOUT
     97    PS_LOG_NONE,                       ///< turn off logging
     98    PS_LOG_TO_STDERR,                  ///< log to system's stderr
     99    PS_LOG_TO_STDOUT                   ///< log to system's stdout
    81100};
    82101
Note: See TracChangeset for help on using the changeset viewer.