World Of ιζσεα.

The Dark Time Will Pass

 

NetTiers学习笔记11---nettiers中的日志和异常捕获

关于日志:

nettiers使用了 Microsoft.Practices.EnterpriseLibrary.Logging

使用起来很方便

 

 

Logger.Write(obj);

 

就可以写入日志了, 关于Logging Application Block 的配置, 大家可以搜一下cnblogs以前的文章, 有很多介绍

 

 

 

关于异常:

nettiers使用了Microsoft.Practices.EnterpriseLibrary.ExceptionHandling

使用起来同样很方便...

 

ExceptionPolicy.HandleException(exceptionToHandle, policyName)

 

配置都在entlib.config中

 

 

发一个entlib.config

 

Code

 

 

posted on 2008-08-27 18:10  Ψιζσεα.  阅读(1607)  评论(0编辑  收藏  举报

导航