You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mina.apache.org by tr...@apache.org on 2008/05/22 03:19:48 UTC

svn commit: r658967 - /mina/branches/buffer/core/src/main/java/org/apache/mina/queue/IoQueue.java

Author: trustin
Date: Wed May 21 18:19:47 2008
New Revision: 658967

URL: http://svn.apache.org/viewvc?rev=658967&view=rev
Log:
Added JavaDoc for IoQueue

Modified:
    mina/branches/buffer/core/src/main/java/org/apache/mina/queue/IoQueue.java

Modified: mina/branches/buffer/core/src/main/java/org/apache/mina/queue/IoQueue.java
URL: http://svn.apache.org/viewvc/mina/branches/buffer/core/src/main/java/org/apache/mina/queue/IoQueue.java?rev=658967&r1=658966&r2=658967&view=diff
==============================================================================
--- mina/branches/buffer/core/src/main/java/org/apache/mina/queue/IoQueue.java (original)
+++ mina/branches/buffer/core/src/main/java/org/apache/mina/queue/IoQueue.java Wed May 21 18:19:47 2008
@@ -21,7 +21,32 @@
 
 import java.util.Queue;
 
+/**
+ * A {@link Queue} that stores the objects used for I/O operations.
+ * <p>
+ * {@link IoQueue} is different from an ordinary {@link Queue} in that it
+ * provides a way to listen to the state of the queue, {@link IoQueueListener}.
+ * This is often useful when you want to veto adding an element or to monitor
+ * the insertion and removal of an element, which allows a user to enforce
+ * various constraints to the queue dynamically in run time.
+ *
+ * @param <E> the type of the queue's elements
+ *
+ * @author The Apache MINA project (dev@mina.apache.org)
+ * @version $Rev$, $Date$
+ */
 public interface IoQueue<E> extends Queue<E> {
+
+    /**
+     * Adds the specified {@link IoQueueListener} to this queue.  Once added,
+     * the listener will be notified whenever the state of this queue changes.
+     */
     void addListener(IoQueueListener<? super E> listener);
+
+    /**
+     * Removes the specified {@link IoQueueListener} from this queue.  Once
+     * removed, the listener will no longer be notified when the state of this
+     * queue changes.
+     */
     void removeListener(IoQueueListener<? super E> listener);
 }