blob: ad658d9e8289bfc2aa62db5ee87d64733608fe2d [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="de">
<head>
<!-- Generated by javadoc (version 1.7.0_25) on Mon Oct 14 12:35:23 CEST 2013 -->
<meta http-equiv="Content-Type" content="text/html" charset="UTF-8">
<title>PluginRegistry (Apache Extras™ for Apache log4j™. 1.2.17 API)</title>
<meta name="date" content="2013-10-14">
<link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="PluginRegistry (Apache Extras™ for Apache log4j™. 1.2.17 API)";
}
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!-- -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/PluginRegistry.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../../org/apache/log4j/component/plugins/PluginListener.html" title="interface in org.apache.log4j.component.plugins"><span class="strong">Prev Class</span></a></li>
<li><a href="../../../../../org/apache/log4j/component/plugins/PluginSkeleton.html" title="class in org.apache.log4j.component.plugins"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../index.html?org/apache/log4j/component/plugins/PluginRegistry.html" target="_top">Frames</a></li>
<li><a href="PluginRegistry.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">org.apache.log4j.component.plugins</div>
<h2 title="Class PluginRegistry" class="title">Class PluginRegistry</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li><a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li>
<li>
<ul class="inheritance">
<li>org.apache.log4j.component.plugins.PluginRegistry</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<hr>
<br>
<pre>public final class <span class="strong">PluginRegistry</span>
extends <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></pre>
<div class="block">This is a registry for Plugin instances. It provides methods to
start and stop plugin objects individually and to stop all
plugins for a repository.</div>
<dl><dt><span class="strong">Author:</span></dt>
<dd>Mark Womack, Paul Smith</dd></dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_summary">
<!-- -->
</a>
<h3>Constructor Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../../../../org/apache/log4j/component/plugins/PluginRegistry.html#PluginRegistry(org.apache.log4j.component.spi.LoggerRepositoryEx)">PluginRegistry</a></strong>(<a href="../../../../../org/apache/log4j/component/spi/LoggerRepositoryEx.html" title="interface in org.apache.log4j.component.spi">LoggerRepositoryEx</a>&nbsp;repository)</code>
<div class="block">Creates a new instance.</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method_summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/log4j/component/plugins/PluginRegistry.html#addPlugin(org.apache.log4j.component.plugins.Plugin)">addPlugin</a></strong>(<a href="../../../../../org/apache/log4j/component/plugins/Plugin.html" title="interface in org.apache.log4j.component.plugins">Plugin</a>&nbsp;plugin)</code>
<div class="block">Adds a plugin to the plugin registry.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/log4j/component/plugins/PluginRegistry.html#addPluginListener(org.apache.log4j.component.plugins.PluginListener)">addPluginListener</a></strong>(<a href="../../../../../org/apache/log4j/component/plugins/PluginListener.html" title="interface in org.apache.log4j.component.plugins">PluginListener</a>&nbsp;l)</code>
<div class="block">Adds a PluginListener to this registry to be notified
of PluginEvents.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code><a href="../../../../../org/apache/log4j/component/spi/LoggerRepositoryEx.html" title="interface in org.apache.log4j.component.spi">LoggerRepositoryEx</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/log4j/component/plugins/PluginRegistry.html#getLoggerRepository()">getLoggerRepository</a></strong>()</code>
<div class="block">Get logger repository.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/log4j/component/plugins/PluginRegistry.html#getPlugins()">getPlugins</a></strong>()</code>
<div class="block">Returns all the plugins for a given repository.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/log4j/component/plugins/PluginRegistry.html#getPlugins(java.lang.Class)">getPlugins</a></strong>(<a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&nbsp;pluginClass)</code>
<div class="block">Returns all the plugins for a given repository that are instances
of a certain class.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/log4j/component/plugins/PluginRegistry.html#pluginNameExists(java.lang.String)">pluginNameExists</a></strong>(<a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;name)</code>
<div class="block">Returns true if the specified name is already taken by
an existing Plugin registered within the scope of the specified
LoggerRepository.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/log4j/component/plugins/PluginRegistry.html#removePluginListener(org.apache.log4j.component.plugins.PluginListener)">removePluginListener</a></strong>(<a href="../../../../../org/apache/log4j/component/plugins/PluginListener.html" title="interface in org.apache.log4j.component.plugins">PluginListener</a>&nbsp;l)</code>
<div class="block">Removes a particular PluginListener from this registry
such that it will no longer be notified of PluginEvents.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/log4j/component/plugins/PluginRegistry.html#stopAllPlugins()">stopAllPlugins</a></strong>()</code>
<div class="block">Stops all plugins in the given logger repository.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code><a href="../../../../../org/apache/log4j/component/plugins/Plugin.html" title="interface in org.apache.log4j.component.plugins">Plugin</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/log4j/component/plugins/PluginRegistry.html#stopPlugin(java.lang.String)">stopPlugin</a></strong>(<a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;pluginName)</code>
<div class="block">Stops a plugin by plugin name and repository.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.<a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3>
<code><a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</a></code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a name="PluginRegistry(org.apache.log4j.component.spi.LoggerRepositoryEx)">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>PluginRegistry</h4>
<pre>public&nbsp;PluginRegistry(<a href="../../../../../org/apache/log4j/component/spi/LoggerRepositoryEx.html" title="interface in org.apache.log4j.component.spi">LoggerRepositoryEx</a>&nbsp;repository)</pre>
<div class="block">Creates a new instance.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>repository</code> - logger repository.</dd></dl>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method_detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="getLoggerRepository()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getLoggerRepository</h4>
<pre>public&nbsp;<a href="../../../../../org/apache/log4j/component/spi/LoggerRepositoryEx.html" title="interface in org.apache.log4j.component.spi">LoggerRepositoryEx</a>&nbsp;getLoggerRepository()</pre>
<div class="block">Get logger repository.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>logger repository.</dd></dl>
</li>
</ul>
<a name="pluginNameExists(java.lang.String)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>pluginNameExists</h4>
<pre>public&nbsp;boolean&nbsp;pluginNameExists(<a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;name)</pre>
<div class="block">Returns true if the specified name is already taken by
an existing Plugin registered within the scope of the specified
LoggerRepository.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>name</code> - The name to check the repository for</dd>
<dt><span class="strong">Returns:</span></dt><dd>true if the name is already in use, otherwise false</dd></dl>
</li>
</ul>
<a name="addPlugin(org.apache.log4j.component.plugins.Plugin)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>addPlugin</h4>
<pre>public&nbsp;void&nbsp;addPlugin(<a href="../../../../../org/apache/log4j/component/plugins/Plugin.html" title="interface in org.apache.log4j.component.plugins">Plugin</a>&nbsp;plugin)</pre>
<div class="block">Adds a plugin to the plugin registry.
If a plugin with the same name exists
already, it is shutdown and removed.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>plugin</code> - the plugin to add.</dd></dl>
</li>
</ul>
<a name="getPlugins()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getPlugins</h4>
<pre>public&nbsp;<a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a>&nbsp;getPlugins()</pre>
<div class="block">Returns all the plugins for a given repository.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>List list of plugins from the repository.</dd></dl>
</li>
</ul>
<a name="getPlugins(java.lang.Class)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getPlugins</h4>
<pre>public&nbsp;<a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a>&nbsp;getPlugins(<a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&nbsp;pluginClass)</pre>
<div class="block">Returns all the plugins for a given repository that are instances
of a certain class.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>pluginClass</code> - the class the plugin must implement to be selected.</dd>
<dt><span class="strong">Returns:</span></dt><dd>List list of plugins from the repository.</dd></dl>
</li>
</ul>
<a name="stopPlugin(java.lang.String)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>stopPlugin</h4>
<pre>public&nbsp;<a href="../../../../../org/apache/log4j/component/plugins/Plugin.html" title="interface in org.apache.log4j.component.plugins">Plugin</a>&nbsp;stopPlugin(<a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;pluginName)</pre>
<div class="block">Stops a plugin by plugin name and repository.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>pluginName</code> - the name of the plugin to stop.</dd>
<dt><span class="strong">Returns:</span></dt><dd>Plugin the plugin, if stopped, or null if the
the plugin was not found in the registry.</dd></dl>
</li>
</ul>
<a name="stopAllPlugins()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>stopAllPlugins</h4>
<pre>public&nbsp;void&nbsp;stopAllPlugins()</pre>
<div class="block">Stops all plugins in the given logger repository.</div>
</li>
</ul>
<a name="addPluginListener(org.apache.log4j.component.plugins.PluginListener)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>addPluginListener</h4>
<pre>public&nbsp;void&nbsp;addPluginListener(<a href="../../../../../org/apache/log4j/component/plugins/PluginListener.html" title="interface in org.apache.log4j.component.plugins">PluginListener</a>&nbsp;l)</pre>
<div class="block">Adds a PluginListener to this registry to be notified
of PluginEvents.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>l</code> - PluginListener to add to this registry</dd></dl>
</li>
</ul>
<a name="removePluginListener(org.apache.log4j.component.plugins.PluginListener)">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>removePluginListener</h4>
<pre>public&nbsp;void&nbsp;removePluginListener(<a href="../../../../../org/apache/log4j/component/plugins/PluginListener.html" title="interface in org.apache.log4j.component.plugins">PluginListener</a>&nbsp;l)</pre>
<div class="block">Removes a particular PluginListener from this registry
such that it will no longer be notified of PluginEvents.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>l</code> - PluginListener to remove</dd></dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!-- -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/PluginRegistry.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../../org/apache/log4j/component/plugins/PluginListener.html" title="interface in org.apache.log4j.component.plugins"><span class="strong">Prev Class</span></a></li>
<li><a href="../../../../../org/apache/log4j/component/plugins/PluginSkeleton.html" title="class in org.apache.log4j.component.plugins"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../index.html?org/apache/log4j/component/plugins/PluginRegistry.html" target="_top">Frames</a></li>
<li><a href="PluginRegistry.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small><p>Copyright © 2013 The Apache Software Foundation. Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a></p> <p>Apache Extras for Apache log4j, Apache log4j and Apache are trademarks of the Apache Software Foundation.</p></small></p>
</body>
</html>