directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r490911 - /directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/
Date Fri, 29 Dec 2006 02:53:32 GMT
Author: trustin
Date: Thu Dec 28 18:53:31 2006
New Revision: 490911

URL: http://svn.apache.org/viewvc?view=rev&rev=490911
Log:
Added JavaDoc for mitosis.service.protocol.handler

Modified:
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientProtocolHandler.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationContextHandler.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationProtocolHandler.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationServerProtocolHandler.java

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientProtocolHandler.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientProtocolHandler.java?view=diff&rev=490911&r1=490910&r2=490911
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientProtocolHandler.java
(original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientProtocolHandler.java
Thu Dec 28 18:53:31 2006
@@ -22,7 +22,15 @@
 
 import org.apache.directory.mitosis.service.ReplicationService;
 
-
+/**
+ * A {@link ReplicationProtocolHandler} for client-side, which uses
+ * {@link ReplicationClientContextHandler}.  This class is actually 
+ * a shortcut to creating a {@link ReplicationProtocolHandler} with a
+ * new {@link ReplicationClientContextHandler}.
+ * 
+ * @author The Apache Directory Project (dev@directory.apache.org)
+ * @version $Rev$, $Date$
+ */
 public class ReplicationClientProtocolHandler extends ReplicationProtocolHandler
 {
     public ReplicationClientProtocolHandler( ReplicationService service )

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationContextHandler.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationContextHandler.java?view=diff&rev=490911&r1=490910&r2=490911
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationContextHandler.java
(original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationContextHandler.java
Thu Dec 28 18:53:31 2006
@@ -22,24 +22,50 @@
 
 import org.apache.directory.mitosis.service.ReplicationContext;
 import org.apache.mina.common.IdleStatus;
+import org.apache.mina.common.IoHandler;
 
-
+/**
+ * An interface that provides handler methods for events which occurs
+ * when a two replicas communicate with each other.  This interface is
+ * very similar to MINA {@link IoHandler}, but there's a difference
+ * in that this interface provide a {@link ReplicationContext} instead of
+ * an {@link IoHandler}.  It's usually wrapped by
+ * {@link ReplicationProtocolHandler} to work with MINA.
+ * 
+ * @author The Apache Directory Project (dev@directory.apache.org)
+ * @version $Rev$, $Date$
+ */
 public interface ReplicationContextHandler
 {
+    /**
+     * Invoked when a connection is established between two replicas.
+     */
     void contextBegin( ReplicationContext ctx ) throws Exception;
 
-
+    /**
+     * Invoked when a connection is closed between two replicas.
+     */
     void contextEnd( ReplicationContext ctx ) throws Exception;
 
-
+    /**
+     * Invoked when a message is received from a peer replica.
+     */
     void messageReceived( ReplicationContext ctx, Object message ) throws Exception;
 
-
+    /**
+     * Invoked when a message is received from a peer replica.
+     */
     void messageSent( ReplicationContext ctx, Object message ) throws Exception;
 
-
+    /**
+     * Invoked when an exception is raised during the communication or
+     * executing replication logic.
+     */
     void exceptionCaught( ReplicationContext ctx, Throwable cause ) throws Exception;
 
-
+    /**
+     * Invoked when two replicas are not exchanging any data for certain
+     * amount of time.
+     */
     void contextIdle( ReplicationContext ctx, IdleStatus status ) throws Exception;
 }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationProtocolHandler.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationProtocolHandler.java?view=diff&rev=490911&r1=490910&r2=490911
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationProtocolHandler.java
(original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationProtocolHandler.java
Thu Dec 28 18:53:31 2006
@@ -29,7 +29,13 @@
 import org.apache.mina.common.IoHandler;
 import org.apache.mina.common.IoSession;
 
-
+/**
+ * A MINA {@link IoHandler} that wraps a {@link ReplicationContextHandler}
+ * and provides a default implementation of {@link ReplicationContext}.
+ *  
+ * @author The Apache Directory Project (dev@directory.apache.org)
+ * @version $Rev$, $Date$
+ */
 public class ReplicationProtocolHandler implements IoHandler
 {
     private static final String CONTEXT = "context";

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationServerProtocolHandler.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationServerProtocolHandler.java?view=diff&rev=490911&r1=490910&r2=490911
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationServerProtocolHandler.java
(original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationServerProtocolHandler.java
Thu Dec 28 18:53:31 2006
@@ -22,7 +22,15 @@
 
 import org.apache.directory.mitosis.service.ReplicationService;
 
-
+/**
+ * A {@link ReplicationProtocolHandler} for server-side, which uses
+ * {@link ReplicationServerContextHandler}.  This class is actually 
+ * a shortcut to creating a {@link ReplicationProtocolHandler} with a
+ * new {@link ReplicationServerContextHandler}.
+ * 
+ * @author The Apache Directory Project (dev@directory.apache.org)
+ * @version $Rev$, $Date$
+ */
 public class ReplicationServerProtocolHandler extends ReplicationProtocolHandler
 {
     public ReplicationServerProtocolHandler( ReplicationService service )



Mime
View raw message