[ http://issues.apache.org/jira/browse/LOG4NET-107?page=comments#action_12459972 ] Drew Schaeffer commented on LOG4NET-107: ----------------------------------------
It seemed intuitive to make ExceptionType of type Type. Otherwise, when creating an ExceptionEvaluator you would have to set ExceptionType to an instance of the type of exception you want to trigger on. ie ExceptionEvaluator eval = new ExceptionEvaluator(); eval.ExceptionType = new ApplicationException(); This would certainly work but ExceptionEvaluator.IsTriggeringEvent would still be comparing the type. ie m_type.GetType() == loggingEvent.ExceptionObject.GetType() So if the type of exception is what is being compared why not have ExceptionType be of type Type? > [PATCH] Added ExceptionEvaluator > -------------------------------- > > Key: LOG4NET-107 > URL: http://issues.apache.org/jira/browse/LOG4NET-107 > Project: Log4net > Issue Type: New Feature > Components: Core > Reporter: Drew Schaeffer > Assigned To: Ron Grabowski > Priority: Minor > Attachments: ExceptionEvaluator.cs, patch-file.diff > > > Added an ExceptionEvaluator class to allow buffered appenders to trigger > based on the type of LoggingEvent.ExceptionObject. By setting the > TiggerOnSubclass property the evaluator will trigger on types that are of the > same type or subclasses of ExceptionType. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
