Return-Path: Delivered-To: apmail-ws-axis-cvs-archive@www.apache.org Received: (qmail 7037 invoked from network); 30 Jan 2006 10:09:16 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 30 Jan 2006 10:09:16 -0000 Received: (qmail 70127 invoked by uid 500); 30 Jan 2006 10:09:15 -0000 Delivered-To: apmail-ws-axis-cvs-archive@ws.apache.org Received: (qmail 70037 invoked by uid 500); 30 Jan 2006 10:09:14 -0000 Mailing-List: contact axis-cvs-help@ws.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list axis-cvs@ws.apache.org Received: (qmail 70026 invoked by uid 500); 30 Jan 2006 10:09:14 -0000 Delivered-To: apmail-ws-axis2-cvs@ws.apache.org Received: (qmail 70023 invoked by uid 99); 30 Jan 2006 10:09:14 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 30 Jan 2006 02:09:14 -0800 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.29) with SMTP; Mon, 30 Jan 2006 02:09:13 -0800 Received: (qmail 6871 invoked by uid 65534); 30 Jan 2006 10:08:53 -0000 Message-ID: <20060130100853.6870.qmail@minotaur.apache.org> Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r373485 - /webservices/axis2/trunk/c/include/axis2_log.h Date: Mon, 30 Jan 2006 10:08:53 -0000 To: axis2-cvs@ws.apache.org From: damitha@apache.org X-Mailer: svnmailer-1.0.5 X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Author: damitha Date: Mon Jan 30 02:08:47 2006 New Revision: 373485 URL: http://svn.apache.org/viewcvs?rev=373485&view=rev Log: updated for new log functions added changed log level enums Modified: webservices/axis2/trunk/c/include/axis2_log.h Modified: webservices/axis2/trunk/c/include/axis2_log.h URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/include/axis2_log.h?rev=373485&r1=373484&r2=373485&view=diff ============================================================================== --- webservices/axis2/trunk/c/include/axis2_log.h (original) +++ webservices/axis2/trunk/c/include/axis2_log.h Mon Jan 30 02:08:47 2006 @@ -27,12 +27,17 @@ struct axis2_log; struct axis2_log_ops; + +#define LOG_SI __FILE__,__LINE__ + /** * @defgroup axis2_log Log * @ingroup axis2_util * @{ */ +/*TODO:log_xml*/ + /** * \brief Axis2 log levels */ @@ -71,7 +76,13 @@ * @param size size of the buffer to be written to log * @return satus of the op. AXIS2_SUCCESS on success else AXIS2_FAILURE */ - axis2_status_t (AXIS2_CALL *write) (struct axis2_log *log, const axis2_char_t *buffer, axis2_log_levels_t level); + axis2_status_t (AXIS2_CALL *write) (struct axis2_log *log, const axis2_char_t *buffer, axis2_log_levels_t level,const axis2_char_t *file,const int line); + + axis2_status_t (AXIS2_CALL *log_critical) (struct axis2_log *log,const char *filename,const int linenumber,axis2_char_t *format,...); + axis2_status_t (AXIS2_CALL *log_error) (struct axis2_log *log,const char *filename,const int linenumber,axis2_char_t *format,...); + axis2_status_t (AXIS2_CALL *log_warning) (struct axis2_log *log,const char *filename,const int linenumber,axis2_char_t *format,...); + axis2_status_t (AXIS2_CALL *log_info) (struct axis2_log *log,const char *filename,const int linenumber,axis2_char_t *format,...); + axis2_status_t (AXIS2_CALL *log_debug) (struct axis2_log *log,const char *filename,const int linenumber,axis2_char_t *format,...); } axis2_log_ops_t; /** @@ -83,15 +94,25 @@ { /** Log related ops */ struct axis2_log_ops *ops; + + /*FILE *log;*/ /** Log level */ axis2_log_levels_t level; /** Is logging enabled? */ axis2_bool_t enabled; + } axis2_log_t; - + #define AXIS2_LOG_FREE(log) ((log->ops)->free(log)) -#define AXIS2_LOG_WRITE(log, buffer, level) ((log)->ops->write(log, buffer, level)) + +#define AXIS2_LOG_WRITE(log, buffer, level) ((log)->ops->write(log, buffer, level,LOG_SI)) + +#define AXIS2_LOG_DEBUG log->ops->log_debug +#define AXIS2_LOG_INFO log->ops->log_info +#define AXIS2_LOG_WARNING log->ops->log_warning +#define AXIS2_LOG_ERROR log->ops->log_error +#define AXIS2_LOG_CRITICAL log->ops->log_critical /** @} */