directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r411055 - in /directory/trunks/mina/core/src/main/java/org/apache/mina/common: IoFilter.java ReferenceCountingIoFilter.java ReferenceCountingIoFilterWrapper.java
Date Fri, 02 Jun 2006 05:57:19 GMT
Author: trustin
Date: Thu Jun  1 22:57:18 2006
New Revision: 411055

URL: http://svn.apache.org/viewvc?rev=411055&view=rev
Log:
* Renamed ReferenceCountingIoFilterWrapper to ReferenceCountingIoFilter
* Revised JavaDoc of IoFilter

Added:
    directory/trunks/mina/core/src/main/java/org/apache/mina/common/ReferenceCountingIoFilter.java
      - copied, changed from r411015, directory/trunks/mina/core/src/main/java/org/apache/mina/common/ReferenceCountingIoFilterWrapper.java
Removed:
    directory/trunks/mina/core/src/main/java/org/apache/mina/common/ReferenceCountingIoFilterWrapper.java
Modified:
    directory/trunks/mina/core/src/main/java/org/apache/mina/common/IoFilter.java

Modified: directory/trunks/mina/core/src/main/java/org/apache/mina/common/IoFilter.java
URL: http://svn.apache.org/viewvc/directory/trunks/mina/core/src/main/java/org/apache/mina/common/IoFilter.java?rev=411055&r1=411054&r2=411055&view=diff
==============================================================================
--- directory/trunks/mina/core/src/main/java/org/apache/mina/common/IoFilter.java (original)
+++ directory/trunks/mina/core/src/main/java/org/apache/mina/common/IoFilter.java Thu Jun
 1 22:57:18 2006
@@ -41,8 +41,8 @@
  * <p>
  * When you add an {@link IoFilter} to an {@link IoFilterChain}:
  * <ol>
- *   <li>{@link #init()} is invoked by {@link IoFilterChain} if the filter is
- *       added at the first time.</li>
+ *   <li>{@link #init()} is invoked by {@link ReferenceCountingIoFilter} if
+ *       the filter is added at the first time.</li>
  *   <li>{@link #onPreAdd(IoFilterChain, String, NextFilter)} is invoked to notify
  *       that the filter will be added to the chain.</li>
  *   <li>The filter is added to the chain, and all events and I/O requests
@@ -50,8 +50,9 @@
  *   <li>{@link #onPostAdd(IoFilterChain, String, NextFilter)} is invoked to notify
  *       that the filter is added to the chain.</li>
  *   <li>The filter is removed from the chain if {@link #onPostAdd(IoFilterChain, String,
org.apache.mina.common.IoFilter.NextFilter)}
- *       threw an exception.  {@link #destroy()} is also invoked if the filter
- *       is the last filter which was added to {@link IoFilterChain}s.</li>
+ *       threw an exception.  {@link #destroy()} is also invoked by
+ *       {@link ReferenceCountingIoFilter} if the filter is the last filter which
+ *       was added to {@link IoFilterChain}s.</li>
  * </ol>
  * <p>
  * When you remove an {@link IoFilter} from an {@link IoFilterChain}:
@@ -62,7 +63,8 @@
  *       don't pass through the filter from now.</li>
  *   <li>{@link #onPostRemove(IoFilterChain, String, NextFilter)} is invoked to
  *       notify that the filter is removed from the chain.</li>
- *   <li>{@link #destroy()} is invoked if the removed filter was the last one.</li>
+ *   <li>{@link #destroy()} is invoked by {@link ReferenceCountingIoFilter} if
+ *       the removed filter was the last one.</li>
  * </ol>      
  * 
  * @author The Apache Directory Project (mina-dev@directory.apache.org)
@@ -73,14 +75,18 @@
 public interface IoFilter
 {
     /**
-     * Invoked when this filter is added to a {@link IoFilterChain}
-     * at the first time, so you can initialize shared resources.
+     * Invoked by {@link ReferenceCountingIoFilter} when this filter
+     * is added to a {@link IoFilterChain} at the first time, so you can
+     * initialize shared resources.  Please note that this method is never
+     * called if you don't wrap a filter with {@link ReferenceCountingIoFilter}.
      */
     void init() throws Exception;
 
     /**
-     * Invoked when this filter is not used by any {@link IoFilterChain}
-     * anymore, so you can destroy shared resources.
+     * Invoked by {@link ReferenceCountingIoFilter} when this filter
+     * is not used by any {@link IoFilterChain} anymore, so you can destroy
+     * shared resources.  Please note that this method is never called if
+     * you don't wrap a filter with {@link ReferenceCountingIoFilter}.
      */
     void destroy() throws Exception;
     

Copied: directory/trunks/mina/core/src/main/java/org/apache/mina/common/ReferenceCountingIoFilter.java
(from r411015, directory/trunks/mina/core/src/main/java/org/apache/mina/common/ReferenceCountingIoFilterWrapper.java)
URL: http://svn.apache.org/viewvc/directory/trunks/mina/core/src/main/java/org/apache/mina/common/ReferenceCountingIoFilter.java?p2=directory/trunks/mina/core/src/main/java/org/apache/mina/common/ReferenceCountingIoFilter.java&p1=directory/trunks/mina/core/src/main/java/org/apache/mina/common/ReferenceCountingIoFilterWrapper.java&r1=411015&r2=411055&rev=411055&view=diff
==============================================================================
--- directory/trunks/mina/core/src/main/java/org/apache/mina/common/ReferenceCountingIoFilterWrapper.java
(original)
+++ directory/trunks/mina/core/src/main/java/org/apache/mina/common/ReferenceCountingIoFilter.java
Thu Jun  1 22:57:18 2006
@@ -26,12 +26,12 @@
  * @author The Apache Directory Project (mina-dev@directory.apache.org)
  * @version $Rev$, $Date$
  */
-public class ReferenceCountingIoFilterWrapper implements IoFilter
+public class ReferenceCountingIoFilter implements IoFilter
 {
     private final IoFilter filter;
     private int count = 0;
 
-    public ReferenceCountingIoFilterWrapper( IoFilter filter )
+    public ReferenceCountingIoFilter( IoFilter filter )
     {
         this.filter = filter;
     }



Mime
View raw message