blob: 53049bebc7c10625046946280f48cf1e194465ba [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
--><html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>Apache log4cxx: Filter Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.4.6 -->
<div class="tabs">
<ul>
<li><a href="main.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="modules.html"><span>Modules</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li id="current"><a href="classes.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="classes.html"><span>Alphabetical&nbsp;List</span></a></li>
<li><a href="annotated.html"><span>Class&nbsp;List</span></a></li>
<li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
<li><a href="functions.html"><span>Class&nbsp;Members</span></a></li>
</ul></div>
<div class="nav">
<a class="el" href="namespacelog4cxx.html">log4cxx</a>::<a class="el" href="namespacelog4cxx_1_1spi.html">spi</a>::<a class="el" href="classlog4cxx_1_1spi_1_1_filter.html">Filter</a></div>
<h1>Filter Class Reference</h1><!-- doxytag: class="log4cxx::spi::Filter" --><!-- doxytag: inherits="log4cxx::spi::OptionHandler,log4cxx::helpers::ObjectImpl" -->Inherits <a class="el" href="classlog4cxx_1_1spi_1_1_option_handler.html">OptionHandler</a>, and <a class="el" href="classlog4cxx_1_1helpers_1_1_object_impl.html">ObjectImpl</a>.
<p>
Inherited by <a class="el" href="classlog4cxx_1_1filter_1_1_and_filter.html">AndFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_deny_all_filter.html">DenyAllFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_expression_filter.html">ExpressionFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_level_match_filter.html">LevelMatchFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_level_range_filter.html">LevelRangeFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_location_info_filter.html">LocationInfoFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_map_filter.html">MapFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_property_filter.html">PropertyFilter</a>, and <a class="el" href="classlog4cxx_1_1filter_1_1_string_match_filter.html">StringMatchFilter</a>.
<p>
<a href="classlog4cxx_1_1spi_1_1_filter-members.html">List of all members.</a><hr><a name="_details"></a><h2>Detailed Description</h2>
Users should extend this class to implement customized logging event filtering.
<p>
Note that <a class="el" href="classlog4cxx_1_1_logger.html">Logger</a> and <a class="el" href="classlog4cxx_1_1_appender_skeleton.html">AppenderSkeleton</a>, the parent class of all standard appenders, have built-in filtering rules. It is suggested that you first use and understand the built-in rules before rushing to write your own custom filters.<p>
This abstract class assumes and also imposes that filters be organized in a linear chain. The <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#88283dec47599dde698374489126f01c">decide(LoggingEvent)</a> method of each filter is called sequentially, in the order of their addition to the chain.<p>
The <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#88283dec47599dde698374489126f01c">decide(LoggingEvent)</a> method must return one of the integer constants <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcd692e4d49cf7d68c58e78875ae1833fc3">DENY</a>, <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcdf46d14eb9d5d71afc9f6e747689fcb56">NEUTRAL</a> or <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcd5707b7b8bf1b098d620552e9576d8061">ACCEPT</a>.<p>
If the value <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcd692e4d49cf7d68c58e78875ae1833fc3">DENY</a> is returned, then the log event is dropped immediately without consulting with the remaining filters.<p>
If the value <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcdf46d14eb9d5d71afc9f6e747689fcb56">NEUTRAL</a> is returned, then the next filter in the chain is consulted. If there are no more filters in the chain, then the log event is logged. Thus, in the presence of no filters, the default behaviour is to log all logging events.<p>
If the value <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcd5707b7b8bf1b098d620552e9576d8061">ACCEPT</a> is returned, then the log event is logged without consulting the remaining filters.<p>
The philosophy of <a class="el" href="namespacelog4cxx.html">log4cxx</a> filters is largely inspired from the Linux ipchains.<p>
Note that filtering is only supported by the <a class="el" href="classlog4cxx_1_1xml_1_1_d_o_m_configurator.html">DOMConfigurator</a>.
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Types</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">enum &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcd">FilterDecision</a> { <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcd692e4d49cf7d68c58e78875ae1833fc3">DENY</a> = -1,
<a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcdf46d14eb9d5d71afc9f6e747689fcb56">NEUTRAL</a> = 0,
<a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcd5707b7b8bf1b098d620552e9576d8061">ACCEPT</a> = 1
}</td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#d724ba04cbde6118ceddbd6635e96eaa">Filter</a> ()</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#0198815940c2715c84b0e04828cf8dfa">addRef</a> () const </td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#55c31efee1904916b999395fa4d46a24">releaseRef</a> () const </td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="classlog4cxx_1_1helpers_1_1_object_ptr_t.html">log4cxx::spi::FilterPtr</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#c6ecf1ac8f2f77c59ec5bb44b702de4f">getNext</a> () const </td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#db980cf7b7dedc3e2678a5461ccc717e">setNext</a> (const <a class="el" href="classlog4cxx_1_1helpers_1_1_object_ptr_t.html">log4cxx::spi::FilterPtr</a> &amp;newNext)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#a3df68f8aae152299471992071e202f5">activateOptions</a> (<a class="el" href="classlog4cxx_1_1helpers_1_1_pool.html">log4cxx::helpers::Pool</a> &amp;p)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Usually filters options become active when set. <a href="#a3df68f8aae152299471992071e202f5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#c1d269357907e0809687a2bec962e1c8">setOption</a> (const <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> &amp;option, const <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> &amp;value)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set <code>option</code> to <code>value</code>. <a href="#c1d269357907e0809687a2bec962e1c8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcd">FilterDecision</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#88283dec47599dde698374489126f01c">decide</a> (const <a class="el" href="classlog4cxx_1_1helpers_1_1_object_ptr_t.html">LoggingEventPtr</a> &amp;event) const =0</td></tr>
</table>
<hr><h2>Member Enumeration Documentation</h2>
<a class="anchor" name="8c8b0cee5b13b164894f9eedd8d78bcd"></a><!-- doxytag: member="log4cxx::spi::Filter::FilterDecision" ref="8c8b0cee5b13b164894f9eedd8d78bcd" args="" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">enum <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcd">FilterDecision</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
<dl compact><dt><b>Enumerator: </b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"><em><a class="anchor" name="8c8b0cee5b13b164894f9eedd8d78bcd692e4d49cf7d68c58e78875ae1833fc3"></a><!-- doxytag: member="DENY" ref="8c8b0cee5b13b164894f9eedd8d78bcd692e4d49cf7d68c58e78875ae1833fc3" args="" -->DENY</em>&nbsp;</td><td>
The log event must be dropped immediately without consulting with the remaining filters, if any, in the chain. </td></tr>
<tr><td valign="top"><em><a class="anchor" name="8c8b0cee5b13b164894f9eedd8d78bcdf46d14eb9d5d71afc9f6e747689fcb56"></a><!-- doxytag: member="NEUTRAL" ref="8c8b0cee5b13b164894f9eedd8d78bcdf46d14eb9d5d71afc9f6e747689fcb56" args="" -->NEUTRAL</em>&nbsp;</td><td>
This filter is neutral with respect to the log event.
<p>
The remaining filters, if any, should be consulted for a final decision. </td></tr>
<tr><td valign="top"><em><a class="anchor" name="8c8b0cee5b13b164894f9eedd8d78bcd5707b7b8bf1b098d620552e9576d8061"></a><!-- doxytag: member="ACCEPT" ref="8c8b0cee5b13b164894f9eedd8d78bcd5707b7b8bf1b098d620552e9576d8061" args="" -->ACCEPT</em>&nbsp;</td><td>
The log event must be logged immediately without consulting with the remaining filters, if any, in the chain. </td></tr>
</table>
</dl>
</td>
</tr>
</table>
<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="d724ba04cbde6118ceddbd6635e96eaa"></a><!-- doxytag: member="log4cxx::spi::Filter::Filter" ref="d724ba04cbde6118ceddbd6635e96eaa" args="()" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"><a class="el" href="classlog4cxx_1_1spi_1_1_filter.html">Filter</a> </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="a3df68f8aae152299471992071e202f5"></a><!-- doxytag: member="log4cxx::spi::Filter::activateOptions" ref="a3df68f8aae152299471992071e202f5" args="(log4cxx::helpers::Pool &amp;p)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void activateOptions </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top"><a class="el" href="classlog4cxx_1_1helpers_1_1_pool.html">log4cxx::helpers::Pool</a> &amp;&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>p</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap><code> [virtual]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Usually filters options become active when set.
<p>
We provide a<p>
default do-nothing implementation for convenience.
<p>
Implements <a class="el" href="classlog4cxx_1_1spi_1_1_option_handler.html#f04d4bfbd66b46083b1aa042fdafbb06">OptionHandler</a>.
<p>
Reimplemented in <a class="el" href="classlog4cxx_1_1filter_1_1_expression_filter.html#a3df68f8aae152299471992071e202f5">ExpressionFilter</a>, and <a class="el" href="classlog4cxx_1_1filter_1_1_location_info_filter.html#580abdcb8fd42d07eaf679166f77bc34">LocationInfoFilter</a>. </td>
</tr>
</table>
<a class="anchor" name="0198815940c2715c84b0e04828cf8dfa"></a><!-- doxytag: member="log4cxx::spi::Filter::addRef" ref="0198815940c2715c84b0e04828cf8dfa" args="() const " --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void addRef </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap> const<code> [virtual]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
<p>
Reimplemented from <a class="el" href="classlog4cxx_1_1helpers_1_1_object_impl.html#0198815940c2715c84b0e04828cf8dfa">ObjectImpl</a>. </td>
</tr>
</table>
<a class="anchor" name="88283dec47599dde698374489126f01c"></a><!-- doxytag: member="log4cxx::spi::Filter::decide" ref="88283dec47599dde698374489126f01c" args="(const LoggingEventPtr &amp;event) const =0" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">virtual <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#8c8b0cee5b13b164894f9eedd8d78bcd">FilterDecision</a> decide </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const <a class="el" href="classlog4cxx_1_1helpers_1_1_object_ptr_t.html">LoggingEventPtr</a> &amp;&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>event</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap> const<code> [pure virtual]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
If the decision is <code>DENY</code>, then the event will be dropped. If the decision is <code>NEUTRAL</code>, then the next filter, if any, will be invoked. If the decision is ACCEPT then the event will be logged without consulting with other filters in the chain.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>event</em>&nbsp;</td><td>The <a class="el" href="classlog4cxx_1_1spi_1_1_logging_event.html">LoggingEvent</a> to decide upon. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>The decision of the filter. </dd></dl>
<p>
Implemented in <a class="el" href="classlog4cxx_1_1filter_1_1_and_filter.html#f0945cde84b8648b7497a6140e91ac5c">AndFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_deny_all_filter.html#cfc21839a1c2ec66d23e530636c17fca">DenyAllFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_expression_filter.html#f0945cde84b8648b7497a6140e91ac5c">ExpressionFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_level_match_filter.html#f0945cde84b8648b7497a6140e91ac5c">LevelMatchFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_level_range_filter.html#f0945cde84b8648b7497a6140e91ac5c">LevelRangeFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_location_info_filter.html#f0945cde84b8648b7497a6140e91ac5c">LocationInfoFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_map_filter.html#f0945cde84b8648b7497a6140e91ac5c">MapFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_property_filter.html#f0945cde84b8648b7497a6140e91ac5c">PropertyFilter</a>, and <a class="el" href="classlog4cxx_1_1filter_1_1_string_match_filter.html#f0945cde84b8648b7497a6140e91ac5c">StringMatchFilter</a>. </td>
</tr>
</table>
<a class="anchor" name="c6ecf1ac8f2f77c59ec5bb44b702de4f"></a><!-- doxytag: member="log4cxx::spi::Filter::getNext" ref="c6ecf1ac8f2f77c59ec5bb44b702de4f" args="() const " --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"><a class="el" href="classlog4cxx_1_1helpers_1_1_object_ptr_t.html">log4cxx::spi::FilterPtr</a> getNext </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap> const</td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="55c31efee1904916b999395fa4d46a24"></a><!-- doxytag: member="log4cxx::spi::Filter::releaseRef" ref="55c31efee1904916b999395fa4d46a24" args="() const " --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void releaseRef </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap> const<code> [virtual]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
<p>
Reimplemented from <a class="el" href="classlog4cxx_1_1helpers_1_1_object_impl.html#55c31efee1904916b999395fa4d46a24">ObjectImpl</a>. </td>
</tr>
</table>
<a class="anchor" name="db980cf7b7dedc3e2678a5461ccc717e"></a><!-- doxytag: member="log4cxx::spi::Filter::setNext" ref="db980cf7b7dedc3e2678a5461ccc717e" args="(const log4cxx::spi::FilterPtr &amp;newNext)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void setNext </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const <a class="el" href="classlog4cxx_1_1helpers_1_1_object_ptr_t.html">log4cxx::spi::FilterPtr</a> &amp;&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>newNext</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="c1d269357907e0809687a2bec962e1c8"></a><!-- doxytag: member="log4cxx::spi::Filter::setOption" ref="c1d269357907e0809687a2bec962e1c8" args="(const LogString &amp;option, const LogString &amp;value)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void setOption </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> &amp;&nbsp;</td>
<td class="mdname" nowrap> <em>option</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const <a class="el" href="namespacelog4cxx.html#d7ec98d27bca7666e23f27dd1fb181c8">LogString</a> &amp;&nbsp;</td>
<td class="mdname" nowrap> <em>value</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"><code> [virtual]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Set <code>option</code> to <code>value</code>.
<p>
The handling of each option depends on the <a class="el" href="classlog4cxx_1_1spi_1_1_option_handler.html">OptionHandler</a> instance. Some options may become active immediately whereas other may be activated only when <a class="el" href="classlog4cxx_1_1spi_1_1_filter.html#a3df68f8aae152299471992071e202f5">activateOptions</a> is called.
<p>
Implements <a class="el" href="classlog4cxx_1_1spi_1_1_option_handler.html#8f2ae2ded63f80c627269c99b20c19ee">OptionHandler</a>.
<p>
Reimplemented in <a class="el" href="classlog4cxx_1_1filter_1_1_level_match_filter.html#ee5023c29cca9dc68164b22a01cb7c6e">LevelMatchFilter</a>, <a class="el" href="classlog4cxx_1_1filter_1_1_level_range_filter.html#ee5023c29cca9dc68164b22a01cb7c6e">LevelRangeFilter</a>, and <a class="el" href="classlog4cxx_1_1filter_1_1_string_match_filter.html#ee5023c29cca9dc68164b22a01cb7c6e">StringMatchFilter</a>. </td>
</tr>
</table>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="filter_8h.html">filter.h</a></ul>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
</BODY>
</HTML>