#include <iostream>
#include <log4cxx/logstring.h>
#include <log4cxx/logger.h>
#include <log4cxx/propertyconfigurator.h>
#include <log4cxx/helpers/exception.h>
#include <locale.h>
#include <log4cxx/basicconfigurator.h>
using namespace log4cxx;
using namespace log4cxx::helpers;
int main(){
//LoggerPtr logger(Logger::getLogger("LogTest1"));
//BasicConfigurator::configure();
//LOG4CXX_INFO(logger, "Hello ");
//LOG4CXX_DEBUG(logger, "Log4Cxx");
//printf("aaaaaaaaaaa");
//加载log4cxx的配置文件,这里使用了属性文件
PropertyConfigurator::configure("log4cxx.properties");
//获得一个Logger,这里使用了RootLogger
LoggerPtr rootLogger = Logger::getRootLogger();
//发出INFO级别的输出请求
//LOG4CXX_INFO(rootLogger, _T("日志系统启动了。。。。"));
rootLogger->info("日志系统启动了。。。。"); //与上面那句话功能一样
return 0;
}
没有合适的资源?快使用搜索试试~ 我知道了~
log4cxx库文件使用
共224个文件
h:177个
in:17个
am:14个
4星 · 超过85%的资源 需积分: 10 10 下载量 108 浏览量
2013-12-31
14:57:51
上传
评论
收藏 1.42MB RAR 举报
温馨提示
有完整的使用实例,并且有release和debug两种版本都可以编译运行
资源推荐
资源详情
资源评论
收起资源包目录
log4cxx库文件使用 (224个子文件)
Makefile.am 1KB
Makefile.am 1KB
Makefile.am 905B
Makefile.am 904B
Makefile.am 902B
Makefile.am 902B
Makefile.am 902B
Makefile.am 898B
Makefile.am 898B
Makefile.am 894B
Makefile.am 886B
Makefile.am 886B
Makefile.am 882B
Makefile.am 882B
01.cpp 865B
log4cxx.dll 2.43MB
log4cxx.dll 1.46MB
loggTest1.vcxproj.filters 1014B
logger.h 73KB
messagebuffer.h 25KB
stream.h 20KB
ndc.h 15KB
patternlayout.h 14KB
domconfigurator.h 14KB
propertyconfigurator.h 13KB
exception.h 13KB
odbcappender.h 12KB
smtpappender.h 12KB
loggingevent.h 11KB
level.h 11KB
asyncappender.h 10KB
mdc.h 10KB
hierarchy.h 10KB
timebasedrollingpolicy.h 9KB
properties.h 9KB
sockethubappender.h 9KB
fileappender.h 9KB
transcoder.h 8KB
writerappender.h 8KB
cacheddateformat.h 8KB
thread.h 8KB
appenderskeleton.h 7KB
file.h 7KB
tchar.h 7KB
optionconverter.h 7KB
ttcclayout.h 7KB
logmanager.h 7KB
socketappenderskeleton.h 7KB
dailyrollingfileappender.h 6KB
syslogappender.h 6KB
xmlsocketappender.h 6KB
telnetappender.h 6KB
datagrampacket.h 6KB
levelrangefilter.h 6KB
socketappender.h 6KB
xmllayout.h 6KB
objectptr.h 5KB
patternparser.h 5KB
datagramsocket.h 5KB
filter.h 5KB
object.h 5KB
errorhandler.h 5KB
rollingfileappenderskeleton.h 5KB
fixedwindowrollingpolicy.h 5KB
xml.h 5KB
htmllayout.h 5KB
propertysetter.h 5KB
fallbackerrorhandler.h 5KB
nteventlogappender.h 5KB
charsetencoder.h 4KB
appender.h 4KB
loglog.h 4KB
rollingfileappender.h 4KB
loggerrepository.h 4KB
expressionfilter.h 4KB
levelmatchfilter.h 4KB
appenderattachableimpl.h 4KB
stringmatchfilter.h 4KB
rollingfileappender.h 4KB
charsetdecoder.h 4KB
rollingpolicybase.h 4KB
onlyonceerrorhandler.h 4KB
cyclicbuffer.h 4KB
inetaddress.h 4KB
datelayout.h 4KB
andfilter.h 4KB
locationinfo.h 4KB
resourcebundle.h 4KB
objectoutputstream.h 4KB
patternconverter.h 3KB
socket.h 3KB
rolloverdescription.h 3KB
fileinputstream.h 3KB
layout.h 3KB
dateformat.h 3KB
inputstreamreader.h 3KB
filterbasedtriggeringpolicy.h 3KB
simpledateformat.h 3KB
filewatchdog.h 3KB
bytearrayinputstream.h 3KB
共 224 条
- 1
- 2
- 3
资源评论
- TommyLike2014-01-29这个不错 可以直接跑
- fulei_master2014-02-04好用,编译就可以使用。
woshizfs
- 粉丝: 16
- 资源: 7
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 学生成绩管理系统-C++版本
- 吉林大学离散数学2笔记.pdf
- 通道处理过程的模拟通常涉及对通道处理机制的理解与实现.txt
- Flume进阶-自定义拦截器jar包
- Dubins曲线算法讲解和在运动规划中的使用.pdf
- 上市公司-股票性质数据-工具变量(民企、国企、央企)2003-2022年.dta
- 上市公司-股票性质数据-工具变量(民企、国企、央企)2003-2022年.xlsx
- Reeds+Shepp曲线算法讲解和实现.pdf
- 毕业设计基于SpringBoot+MyBatisPlus+MySQL+Vue的外卖配送信息系统源代码+数据库
- 词向量(Word Embeddings)是自然语言处理(NLP)领域的一种重要技术.txt
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功