/**********************************************************************
 
	Copyright (C) 2003 Hirohisa MORI <joshua@nichibun.ac.jp>
 
	This program is free software; you can redistribute it 
	and/or modify it under the terms of the GLOBALBASE 
	Library General Public License (G-LGPL) as published by 

	http://www.globalbase.org/
 
	This program is distributed in the hope that it will be 
	useful, but WITHOUT ANY WARRANTY; without even the 
	implied warranty of MERCHANTABILITY or FITNESS FOR A 
	PARTICULAR PURPOSE.

**********************************************************************/



#ifndef ___LOG_H___
#define ___LOG_H___

#ifdef VA2
#include	<varargs.h>
#else
#include	<stdarg.h>
#endif
#include	<fcntl.h>

extern int (*__log_vprintf)();
int
log_vprintf(int level,int layer,void*,char * fmt,va_list p);
int log_printf(int level,int layer,void*,char * fmt,...);

/* LOG LEVEL */
#define LOG_TEST	0
#define LOG_DEBUG	1
#define LOG_WARNING	2
#define LOG_ERROR	3
#define LOG_SYSTEM	4
#define LOG_MESSAGE	5
#define LOG_MAX_LEVEL	6

/* LOG LAYER */
#define LOG_LAYER_NANE		0
#define LOG_LAYER_LIB		1
#define LOG_LAYER_XLoHTTP	2
#define LOG_LAYER_STREAM	3
#define LOG_LAYER_XL		4
#define LOG_LAYER_GB		5
#define LOG_LAYER_UI		6
#define LOG_LAYER_MAX		7

#endif

