17 #ifndef _LOG4CXX_FILTER_MAPFILTER_H 18 #define _LOG4CXX_FILTER_MAPFILTER_H 23 #pragma warning ( push ) 24 #pragma warning ( disable: 4251 ) 45 typedef std::map < LogString, LogString > KeyVals;
64 virtual void setOption(
const LogString& option,
69 this->keyVals[strKey] = strValue;
75 const KeyVals::const_iterator it(this->keyVals.find(strKey));
77 return (it != keyVals.end() ? it->second : empty);
82 this->acceptOnMatch = acceptOnMatch1;
97 this->mustMatchAll = mustMatchAll1;
112 #if defined(_MSC_VER) 113 #pragma warning (pop) 116 #endif // _LOG4CXX_FILTER_MAPFILTER_H #define LOG4CXX_CAST_ENTRY(Interface)
Definition: object.h:153
#define END_LOG4CXX_CAST_MAP()
Definition: object.h:147
void setMustMatchAll(bool mustMatchAll1)
Definition: mapfilter.h:95
std::shared_ptr< LoggingEvent > LoggingEventPtr
Definition: appender.h:37
#define BEGIN_LOG4CXX_CAST_MAP()
Definition: object.h:141
LOG4CXX_PTR_DEF(AndFilter)
FilterDecision
Definition: filter.h:87
bool getMustMatchAll() const
Definition: mapfilter.h:90
#define DECLARE_LOG4CXX_OBJECT(object)
Definition: object.h:39
bool getAcceptOnMatch() const
Definition: mapfilter.h:85
void setAcceptOnMatch(bool acceptOnMatch1)
Definition: mapfilter.h:80
A Filter that operates on a Map and can be used like in the following example:
Definition: mapfilter.h:43
#define LOG4CXX_CAST_ENTRY_CHAIN(Interface)
Definition: object.h:159
void setKeyValue(const LogString &strKey, const LogString &strValue)
Definition: mapfilter.h:67
Definition: appender.h:32
std::basic_string< logchar > LogString
Definition: logstring.h:66
Users should extend this class to implement customized logging event filtering.
Definition: filter.h:68
const LogString & getValue(const LogString &strKey) const
Definition: mapfilter.h:72