directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r471336 [1/2] - in /directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis: service/protocol/ service/protocol/codec/ service/protocol/message/ store/ store/derby/ util/
Date Sun, 05 Nov 2006 02:31:05 GMT
Author: akarasulu
Date: Sat Nov  4 18:31:02 2006
New Revision: 471336

URL: http://svn.apache.org/viewvc?view=rev&rev=471336
Log:
source formatting

Modified:
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/Constants.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BaseMessageDecoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BaseMessageEncoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesAckMessageDecoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesAckMessageEncoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesMessageDecoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesMessageEncoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesAckMessageDecoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesAckMessageEncoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesMessageDecoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesMessageEncoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryAckMessageDecoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryAckMessageEncoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryMessageDecoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryMessageEncoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginAckMessageDecoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginAckMessageEncoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginMessageDecoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginMessageEncoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ReplicationClientProtocolCodecFactory.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ReplicationServerProtocolCodecFactory.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ResponseMessageDecoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ResponseMessageEncoder.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BaseMessage.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BeginLogEntriesAckMessage.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BeginLogEntriesMessage.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/EndLogEntriesAckMessage.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/EndLogEntriesMessage.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LogEntryAckMessage.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LogEntryMessage.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LoginAckMessage.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LoginMessage.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/ResponseMessage.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationLogIterator.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationStore.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationStoreException.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationLogIterator.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStore.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/SQLUtil.java
    directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/util/OctetString.java

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/Constants.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/Constants.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/Constants.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/Constants.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol;
 
+
 public class Constants
 {
     public static final int LOGIN = 0x00;
@@ -31,10 +32,11 @@
     public static final int BEGIN_LOG_ENTRIES_ACK = 0x07;
     public static final int END_LOG_ENTRIES = 0x08;
     public static final int END_LOG_ENTRIES_ACK = 0x09;
-    
+
     public static final int OK = 0;
     public static final int NOT_OK = -1;
-    
+
+
     private Constants()
     {
     }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BaseMessageDecoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BaseMessageDecoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BaseMessageDecoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BaseMessageDecoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.mina.common.ByteBuffer;
 import org.apache.mina.common.IoSession;
@@ -27,6 +28,7 @@
 import org.apache.mina.filter.codec.demux.MessageDecoder;
 import org.apache.mina.filter.codec.demux.MessageDecoderResult;
 
+
 public abstract class BaseMessageDecoder implements MessageDecoder
 {
     private final int type;
@@ -36,6 +38,7 @@
     private int sequence;
     private int bodyLength;
 
+
     protected BaseMessageDecoder( int type, int minBodyLength, int maxBodyLength )
     {
         this.type = type;
@@ -43,42 +46,44 @@
         this.maxBodyLength = maxBodyLength;
     }
 
+
     public final MessageDecoderResult decodable( IoSession session, ByteBuffer buf )
     {
-        return type == buf.get()? OK : NOT_OK;
+        return type == buf.get() ? OK : NOT_OK;
     }
 
-    public final MessageDecoderResult decode( IoSession session, ByteBuffer in,
-                                              ProtocolDecoderOutput out ) throws Exception
+
+    public final MessageDecoderResult decode( IoSession session, ByteBuffer in, ProtocolDecoderOutput out )
+        throws Exception
     {
-        if( !readHeader )
+        if ( !readHeader )
         {
-            if( in.remaining() < 9 )
+            if ( in.remaining() < 9 )
             {
                 return NEED_DATA;
             }
-            
+
             in.get(); // skip type field
             sequence = in.getInt();
             bodyLength = in.getInt();
-            
-            if( bodyLength < minBodyLength || bodyLength > maxBodyLength )
+
+            if ( bodyLength < minBodyLength || bodyLength > maxBodyLength )
             {
                 throw new ProtocolDecoderException( "Wrong bodyLength: " + bodyLength );
             }
-            
+
             readHeader = true;
         }
-        
-        if( readHeader )
+
+        if ( readHeader )
         {
-            if( in.remaining() < bodyLength )
+            if ( in.remaining() < bodyLength )
             {
                 return NEED_DATA;
             }
-            
+
             int oldLimit = in.limit();
-            
+
             try
             {
                 in.limit( in.position() + bodyLength );
@@ -91,9 +96,10 @@
                 in.limit( oldLimit );
             }
         }
-        
+
         throw new InternalError();
     }
-    
+
+
     protected abstract BaseMessage decodeBody( int sequence, int bodyLength, ByteBuffer in ) throws Exception;
 }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BaseMessageEncoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BaseMessageEncoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BaseMessageEncoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BaseMessageEncoder.java Sat Nov  4 18:31:02 2006
@@ -19,19 +19,22 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.mina.common.ByteBuffer;
 import org.apache.mina.common.IoSession;
 import org.apache.mina.filter.codec.ProtocolEncoderOutput;
 import org.apache.mina.filter.codec.demux.MessageEncoder;
 
+
 public abstract class BaseMessageEncoder implements MessageEncoder
 {
     public BaseMessageEncoder()
     {
     }
 
-    public final void encode( IoSession session, Object in, ProtocolEncoderOutput out) throws Exception
+
+    public final void encode( IoSession session, Object in, ProtocolEncoderOutput out ) throws Exception
     {
         BaseMessage m = ( BaseMessage ) in;
         ByteBuffer buf = ByteBuffer.allocate( 16 );
@@ -44,15 +47,16 @@
         encodeBody( m, buf );
         final int bodyEndPos = buf.position();
         final int bodyLength = bodyEndPos - bodyStartPos;
-        
+
         // fill bodyLength
         buf.position( bodyStartPos - 4 );
         buf.putInt( bodyLength );
         buf.position( bodyEndPos );
-        
+
         buf.flip();
         out.write( buf );
     }
-    
+
+
     protected abstract void encodeBody( BaseMessage in, ByteBuffer out ) throws Exception;
 }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesAckMessageDecoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesAckMessageDecoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesAckMessageDecoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesAckMessageDecoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.nio.charset.CharacterCodingException;
 import java.nio.charset.Charset;
 import java.nio.charset.CharsetDecoder;
@@ -34,19 +35,22 @@
 import org.apache.mina.filter.codec.ProtocolDecoderException;
 import org.apache.mina.filter.codec.ProtocolDecoderOutput;
 
+
 public class BeginLogEntriesAckMessageDecoder extends ResponseMessageDecoder
 {
     private final CharsetDecoder utf8decoder;
 
+
     public BeginLogEntriesAckMessageDecoder()
     {
         super( Constants.GET_UPDATE_VECTOR_ACK, 0, 3072 );
         utf8decoder = Charset.forName( "UTF-8" ).newDecoder();
     }
-    protected BaseMessage decodeBody( int sequence, int bodyLength,
-                                      int responseCode, ByteBuffer in ) throws Exception
+
+
+    protected BaseMessage decodeBody( int sequence, int bodyLength, int responseCode, ByteBuffer in ) throws Exception
     {
-        if( responseCode != Constants.OK )
+        if ( responseCode != Constants.OK )
         {
             return new BeginLogEntriesAckMessage( sequence, responseCode, null, null );
         }
@@ -56,34 +60,36 @@
         BeginLogEntriesAckMessage m = new BeginLogEntriesAckMessage( sequence, responseCode, purgeVector, updateVector );
         readCSNVector( in, purgeVector );
         readCSNVector( in, updateVector );
-        
+
         return m;
     }
 
+
     private void readCSNVector( ByteBuffer in, CSNVector updateVector ) throws Exception
     {
         int nReplicas = in.getInt();
-        if( nReplicas < 0 )
+        if ( nReplicas < 0 )
         {
             throw new ProtocolDecoderException( "Wrong nReplicas: " + nReplicas );
         }
-        
-        for( ; nReplicas > 0; nReplicas-- )
+
+        for ( ; nReplicas > 0; nReplicas-- )
         {
             ReplicaId replicaId;
             try
             {
                 replicaId = new ReplicaId( in.getString( utf8decoder ) );
             }
-            catch( CharacterCodingException e )
+            catch ( CharacterCodingException e )
             {
                 throw new ProtocolDecoderException( "Invalid replicaId", e );
             }
-            
+
             updateVector.setCSN( new SimpleCSN( in.getLong(), replicaId, in.getInt() ) );
         }
     }
-    
+
+
     public void finishDecode( IoSession session, ProtocolDecoderOutput out ) throws Exception
     {
     }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesAckMessageEncoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesAckMessageEncoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesAckMessageEncoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesAckMessageEncoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.nio.charset.CharacterCodingException;
 import java.nio.charset.Charset;
 import java.nio.charset.CharsetEncoder;
@@ -34,41 +35,47 @@
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.directory.mitosis.service.protocol.message.BeginLogEntriesAckMessage;
 
+
 public class BeginLogEntriesAckMessageEncoder extends ResponseMessageEncoder
 {
     private final CharsetEncoder utf8encoder;
 
+
     public BeginLogEntriesAckMessageEncoder()
     {
         utf8encoder = Charset.forName( "UTF-8" ).newEncoder();
     }
-    
-    protected void encodeBody(BaseMessage in, ByteBuffer out) throws Exception {
+
+
+    protected void encodeBody( BaseMessage in, ByteBuffer out ) throws Exception
+    {
         // write out response code
         super.encodeBody( in, out );
-        
+
         BeginLogEntriesAckMessage m = ( BeginLogEntriesAckMessage ) in;
-        if( m.getResponseCode() != Constants.OK )
+        if ( m.getResponseCode() != Constants.OK )
         {
             return;
         }
-        
+
         writeCSNVector( out, m.getPurgeVector() );
         writeCSNVector( out, m.getUpdateVector() );
     }
 
+
     private void writeCSNVector( ByteBuffer out, CSNVector csns )
     {
         Set replicaIds = csns.getReplicaIds();
-        
+
         int nReplicas = replicaIds.size();
         out.putInt( nReplicas );
         Iterator it = replicaIds.iterator();
-        while( it.hasNext() )
+        while ( it.hasNext() )
         {
             ReplicaId replicaId = ( ReplicaId ) it.next();
             CSN csn = csns.getCSN( replicaId );
-            try {
+            try
+            {
                 out.putString( replicaId.getId(), utf8encoder );
                 out.put( ( byte ) 0x00 );
                 out.putLong( csn.getTimestamp() );
@@ -80,6 +87,7 @@
             }
         }
     }
+
 
     public Set getMessageTypes()
     {

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesMessageDecoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesMessageDecoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesMessageDecoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesMessageDecoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.directory.mitosis.service.protocol.Constants;
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.directory.mitosis.service.protocol.message.BeginLogEntriesMessage;
@@ -26,18 +27,21 @@
 import org.apache.mina.common.IoSession;
 import org.apache.mina.filter.codec.ProtocolDecoderOutput;
 
-public class BeginLogEntriesMessageDecoder extends BaseMessageDecoder {
+
+public class BeginLogEntriesMessageDecoder extends BaseMessageDecoder
+{
 
     public BeginLogEntriesMessageDecoder()
     {
         super( Constants.BEGIN_LOG_ENTRIES, 0, 0 );
     }
 
-    protected BaseMessage decodeBody( int sequence, int bodyLength, ByteBuffer in )
-            throws Exception
+
+    protected BaseMessage decodeBody( int sequence, int bodyLength, ByteBuffer in ) throws Exception
     {
         return new BeginLogEntriesMessage( sequence );
     }
+
 
     public void finishDecode( IoSession session, ProtocolDecoderOutput out ) throws Exception
     {

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesMessageEncoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesMessageEncoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesMessageEncoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/BeginLogEntriesMessageEncoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.util.HashSet;
 import java.util.Set;
 
@@ -26,14 +27,21 @@
 import org.apache.directory.mitosis.service.protocol.message.BeginLogEntriesMessage;
 import org.apache.mina.common.ByteBuffer;
 
-public class BeginLogEntriesMessageEncoder extends BaseMessageEncoder {
-    public BeginLogEntriesMessageEncoder() {
+
+public class BeginLogEntriesMessageEncoder extends BaseMessageEncoder
+{
+    public BeginLogEntriesMessageEncoder()
+    {
     }
 
-    protected void encodeBody( BaseMessage in, ByteBuffer out ) {
+
+    protected void encodeBody( BaseMessage in, ByteBuffer out )
+    {
     }
 
-    public Set getMessageTypes() {
+
+    public Set getMessageTypes()
+    {
         Set set = new HashSet();
         set.add( BeginLogEntriesMessage.class );
         return set;

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesAckMessageDecoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesAckMessageDecoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesAckMessageDecoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesAckMessageDecoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.directory.mitosis.service.protocol.Constants;
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.directory.mitosis.service.protocol.message.EndLogEntriesAckMessage;
@@ -26,6 +27,7 @@
 import org.apache.mina.common.IoSession;
 import org.apache.mina.filter.codec.ProtocolDecoderOutput;
 
+
 public class EndLogEntriesAckMessageDecoder extends ResponseMessageDecoder
 {
     public EndLogEntriesAckMessageDecoder()
@@ -33,12 +35,13 @@
         super( Constants.END_LOG_ENTRIES_ACK, 0, 0 );
     }
 
-    protected BaseMessage decodeBody( int sequence, int bodyLength,
-            int responseCode, ByteBuffer in ) throws Exception
+
+    protected BaseMessage decodeBody( int sequence, int bodyLength, int responseCode, ByteBuffer in ) throws Exception
     {
         return new EndLogEntriesAckMessage( sequence, responseCode );
     }
-    
+
+
     public void finishDecode( IoSession session, ProtocolDecoderOutput out ) throws Exception
     {
     }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesAckMessageEncoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesAckMessageEncoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesAckMessageEncoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesAckMessageEncoder.java Sat Nov  4 18:31:02 2006
@@ -19,18 +19,24 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.util.HashSet;
 import java.util.Set;
 
 import org.apache.directory.mitosis.service.protocol.message.EndLogEntriesAckMessage;
 
-public class EndLogEntriesAckMessageEncoder extends ResponseMessageEncoder {
 
-    public EndLogEntriesAckMessageEncoder() {
+public class EndLogEntriesAckMessageEncoder extends ResponseMessageEncoder
+{
+
+    public EndLogEntriesAckMessageEncoder()
+    {
         super();
     }
 
-    public Set getMessageTypes() {
+
+    public Set getMessageTypes()
+    {
         Set set = new HashSet();
         set.add( EndLogEntriesAckMessage.class );
         return set;

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesMessageDecoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesMessageDecoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesMessageDecoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesMessageDecoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.directory.mitosis.service.protocol.Constants;
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.directory.mitosis.service.protocol.message.EndLogEntriesMessage;
@@ -26,19 +27,22 @@
 import org.apache.mina.common.IoSession;
 import org.apache.mina.filter.codec.ProtocolDecoderOutput;
 
-public class EndLogEntriesMessageDecoder extends BaseMessageDecoder {
+
+public class EndLogEntriesMessageDecoder extends BaseMessageDecoder
+{
 
     public EndLogEntriesMessageDecoder()
     {
         super( Constants.END_LOG_ENTRIES, 0, 0 );
     }
 
-    protected BaseMessage decodeBody( int sequence, int bodyLength, ByteBuffer in )
-            throws Exception
+
+    protected BaseMessage decodeBody( int sequence, int bodyLength, ByteBuffer in ) throws Exception
     {
         return new EndLogEntriesMessage( sequence );
     }
-    
+
+
     public void finishDecode( IoSession session, ProtocolDecoderOutput out ) throws Exception
     {
     }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesMessageEncoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesMessageEncoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesMessageEncoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/EndLogEntriesMessageEncoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.util.HashSet;
 import java.util.Set;
 
@@ -26,14 +27,21 @@
 import org.apache.directory.mitosis.service.protocol.message.EndLogEntriesMessage;
 import org.apache.mina.common.ByteBuffer;
 
-public class EndLogEntriesMessageEncoder extends BaseMessageEncoder {
-    public EndLogEntriesMessageEncoder() {
+
+public class EndLogEntriesMessageEncoder extends BaseMessageEncoder
+{
+    public EndLogEntriesMessageEncoder()
+    {
     }
 
-    protected void encodeBody( BaseMessage in, ByteBuffer out ) {
+
+    protected void encodeBody( BaseMessage in, ByteBuffer out )
+    {
     }
 
-    public Set getMessageTypes() {
+
+    public Set getMessageTypes()
+    {
         Set set = new HashSet();
         set.add( EndLogEntriesMessage.class );
         return set;

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryAckMessageDecoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryAckMessageDecoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryAckMessageDecoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryAckMessageDecoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.directory.mitosis.service.protocol.Constants;
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.directory.mitosis.service.protocol.message.LogEntryAckMessage;
@@ -26,6 +27,7 @@
 import org.apache.mina.common.IoSession;
 import org.apache.mina.filter.codec.ProtocolDecoderOutput;
 
+
 public class LogEntryAckMessageDecoder extends ResponseMessageDecoder
 {
     public LogEntryAckMessageDecoder()
@@ -33,12 +35,13 @@
         super( Constants.LOG_ENTRY_ACK, 0, 0 );
     }
 
-    protected BaseMessage decodeBody( int sequence, int bodyLength,
-            int responseCode, ByteBuffer in ) throws Exception
+
+    protected BaseMessage decodeBody( int sequence, int bodyLength, int responseCode, ByteBuffer in ) throws Exception
     {
         return new LogEntryAckMessage( sequence, responseCode );
     }
-    
+
+
     public void finishDecode( IoSession session, ProtocolDecoderOutput out ) throws Exception
     {
     }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryAckMessageEncoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryAckMessageEncoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryAckMessageEncoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryAckMessageEncoder.java Sat Nov  4 18:31:02 2006
@@ -19,18 +19,24 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.util.HashSet;
 import java.util.Set;
 
 import org.apache.directory.mitosis.service.protocol.message.LogEntryAckMessage;
 
-public class LogEntryAckMessageEncoder extends ResponseMessageEncoder {
 
-    public LogEntryAckMessageEncoder() {
+public class LogEntryAckMessageEncoder extends ResponseMessageEncoder
+{
+
+    public LogEntryAckMessageEncoder()
+    {
         super();
     }
 
-    public Set getMessageTypes() {
+
+    public Set getMessageTypes()
+    {
         Set set = new HashSet();
         set.add( LogEntryAckMessage.class );
         return set;

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryMessageDecoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryMessageDecoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryMessageDecoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryMessageDecoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.directory.mitosis.operation.OperationCodec;
 import org.apache.directory.mitosis.service.protocol.Constants;
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
@@ -27,26 +28,27 @@
 import org.apache.mina.common.IoSession;
 import org.apache.mina.filter.codec.ProtocolDecoderOutput;
 
+
 public class LogEntryMessageDecoder extends BaseMessageDecoder
 {
     private final OperationCodec operationCodec = new OperationCodec();
-    
+
+
     public LogEntryMessageDecoder()
     {
         super( Constants.LOG_ENTRY, 1, Integer.MAX_VALUE );
     }
 
-    protected BaseMessage decodeBody( int sequence, int bodyLength,
-                                      ByteBuffer in ) throws Exception
+
+    protected BaseMessage decodeBody( int sequence, int bodyLength, ByteBuffer in ) throws Exception
     {
-        byte[] src = new byte[ in.remaining() ];
+        byte[] src = new byte[in.remaining()];
         in.get( src );
-        
-        return new LogEntryMessage(
-                sequence,
-                operationCodec.decode( src ) );
+
+        return new LogEntryMessage( sequence, operationCodec.decode( src ) );
     }
-    
+
+
     public void finishDecode( IoSession session, ProtocolDecoderOutput out ) throws Exception
     {
     }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryMessageEncoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryMessageEncoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryMessageEncoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LogEntryMessageEncoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.util.HashSet;
 import java.util.Set;
 
@@ -27,19 +28,23 @@
 import org.apache.directory.mitosis.service.protocol.message.LogEntryMessage;
 import org.apache.mina.common.ByteBuffer;
 
+
 public class LogEntryMessageEncoder extends BaseMessageEncoder
 {
     private final OperationCodec operationCodec = new OperationCodec();
-    
+
+
     public LogEntryMessageEncoder()
     {
     }
 
+
     protected void encodeBody( BaseMessage in, ByteBuffer out )
     {
         LogEntryMessage m = ( LogEntryMessage ) in;
         out.put( operationCodec.encode( m.getOperation() ) );
     }
+
 
     public Set getMessageTypes()
     {

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginAckMessageDecoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginAckMessageDecoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginAckMessageDecoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginAckMessageDecoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.nio.charset.Charset;
 import java.nio.charset.CharsetDecoder;
 
@@ -30,21 +31,24 @@
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.directory.mitosis.service.protocol.message.LoginAckMessage;
 
+
 public class LoginAckMessageDecoder extends ResponseMessageDecoder
 {
-    private final CharsetDecoder utf8decoder = Charset.forName("UTF-8").newDecoder();
+    private final CharsetDecoder utf8decoder = Charset.forName( "UTF-8" ).newDecoder();
+
 
     public LoginAckMessageDecoder()
     {
         super( Constants.LOGIN_ACK, 1, 64 );
     }
 
-    protected BaseMessage decodeBody( int sequence, int bodyLength,
-                                      int responseCode, ByteBuffer in ) throws Exception
+
+    protected BaseMessage decodeBody( int sequence, int bodyLength, int responseCode, ByteBuffer in ) throws Exception
     {
         return new LoginAckMessage( sequence, responseCode, new ReplicaId( in.getString( utf8decoder ) ) );
     }
-    
+
+
     public void finishDecode( IoSession session, ProtocolDecoderOutput out ) throws Exception
     {
     }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginAckMessageEncoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginAckMessageEncoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginAckMessageEncoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginAckMessageEncoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.nio.charset.Charset;
 import java.nio.charset.CharsetEncoder;
 import java.util.HashSet;
@@ -28,20 +29,24 @@
 import org.apache.directory.mitosis.service.protocol.message.LoginAckMessage;
 import org.apache.mina.common.ByteBuffer;
 
+
 public class LoginAckMessageEncoder extends ResponseMessageEncoder
 {
-    private final CharsetEncoder utf8encoder = Charset.forName("UTF-8").newEncoder();
+    private final CharsetEncoder utf8encoder = Charset.forName( "UTF-8" ).newEncoder();
+
 
     public LoginAckMessageEncoder()
     {
     }
 
+
     public Set getMessageTypes()
     {
         Set set = new HashSet();
         set.add( LoginAckMessage.class );
         return set;
     }
+
 
     protected void encodeBody( BaseMessage in, ByteBuffer out ) throws Exception
     {

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginMessageDecoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginMessageDecoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginMessageDecoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginMessageDecoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.nio.charset.Charset;
 import java.nio.charset.CharsetDecoder;
 
@@ -30,9 +31,11 @@
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.directory.mitosis.service.protocol.message.LoginMessage;
 
+
 public class LoginMessageDecoder extends BaseMessageDecoder
 {
-    private final CharsetDecoder utf8decoder; 
+    private final CharsetDecoder utf8decoder;
+
 
     public LoginMessageDecoder()
     {
@@ -40,12 +43,13 @@
         utf8decoder = Charset.forName( "UTF-8" ).newDecoder();
     }
 
-    protected BaseMessage decodeBody( int sequence, int bodyLength,
-                                      ByteBuffer in ) throws Exception
+
+    protected BaseMessage decodeBody( int sequence, int bodyLength, ByteBuffer in ) throws Exception
     {
         return new LoginMessage( sequence, new ReplicaId( in.getString( utf8decoder ) ) );
     }
-    
+
+
     public void finishDecode( IoSession session, ProtocolDecoderOutput out ) throws Exception
     {
     }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginMessageEncoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginMessageEncoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginMessageEncoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/LoginMessageEncoder.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import java.nio.charset.CharacterCodingException;
 import java.nio.charset.Charset;
 import java.nio.charset.CharsetEncoder;
@@ -34,30 +35,33 @@
 {
     private final CharsetEncoder utf8encoder;
 
+
     public LoginMessageEncoder()
     {
         utf8encoder = Charset.forName( "UTF-8" ).newEncoder();
     }
 
+
     protected void encodeBody( BaseMessage in, ByteBuffer out )
     {
         LoginMessage m = ( LoginMessage ) in;
-        
+
         try
         {
             out.putString( m.getReplicaId().getId(), utf8encoder );
         }
-        catch( CharacterCodingException e )
+        catch ( CharacterCodingException e )
         {
             throw new RuntimeException( e );
         }
     }
 
-    public Set getMessageTypes() 
+
+    public Set getMessageTypes()
     {
         Set set = new HashSet();
         set.add( LoginMessage.class );
-        
+
         return set;
     }
 }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ReplicationClientProtocolCodecFactory.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ReplicationClientProtocolCodecFactory.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ReplicationClientProtocolCodecFactory.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ReplicationClientProtocolCodecFactory.java Sat Nov  4 18:31:02 2006
@@ -19,10 +19,12 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.mina.filter.codec.demux.DemuxingProtocolCodecFactory;
 
-public class ReplicationClientProtocolCodecFactory extends
-        DemuxingProtocolCodecFactory {
+
+public class ReplicationClientProtocolCodecFactory extends DemuxingProtocolCodecFactory
+{
 
     public ReplicationClientProtocolCodecFactory()
     {
@@ -30,7 +32,7 @@
         register( LoginMessageEncoder.class );
         register( BeginLogEntriesMessageEncoder.class );
         register( EndLogEntriesMessageEncoder.class );
-        
+
         register( LogEntryAckMessageDecoder.class );
         register( LoginAckMessageDecoder.class );
         register( BeginLogEntriesAckMessageDecoder.class );

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ReplicationServerProtocolCodecFactory.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ReplicationServerProtocolCodecFactory.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ReplicationServerProtocolCodecFactory.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ReplicationServerProtocolCodecFactory.java Sat Nov  4 18:31:02 2006
@@ -19,10 +19,12 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.mina.filter.codec.demux.DemuxingProtocolCodecFactory;
 
-public class ReplicationServerProtocolCodecFactory extends
-        DemuxingProtocolCodecFactory {
+
+public class ReplicationServerProtocolCodecFactory extends DemuxingProtocolCodecFactory
+{
 
     public ReplicationServerProtocolCodecFactory()
     {
@@ -30,7 +32,7 @@
         register( LoginAckMessageEncoder.class );
         register( BeginLogEntriesAckMessageEncoder.class );
         register( EndLogEntriesAckMessageEncoder.class );
-        
+
         register( LogEntryMessageDecoder.class );
         register( LoginMessageDecoder.class );
         register( BeginLogEntriesMessageDecoder.class );

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ResponseMessageDecoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ResponseMessageDecoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ResponseMessageDecoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ResponseMessageDecoder.java Sat Nov  4 18:31:02 2006
@@ -19,9 +19,11 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.mina.common.ByteBuffer;
 
+
 public abstract class ResponseMessageDecoder extends BaseMessageDecoder
 {
 
@@ -30,13 +32,14 @@
         super( type, minBodyLength + 4, maxBodyLength + 4 );
     }
 
-    protected final BaseMessage decodeBody( int sequence, int bodyLength,
-                                      ByteBuffer in ) throws Exception
+
+    protected final BaseMessage decodeBody( int sequence, int bodyLength, ByteBuffer in ) throws Exception
     {
         return decodeBody( sequence, bodyLength, in.getInt(), in );
     }
 
-    protected abstract BaseMessage decodeBody( int sequence, int bodyLength,
-                                               int responseCode, ByteBuffer in ) throws Exception;
+
+    protected abstract BaseMessage decodeBody( int sequence, int bodyLength, int responseCode, ByteBuffer in )
+        throws Exception;
 
 }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ResponseMessageEncoder.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ResponseMessageEncoder.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ResponseMessageEncoder.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/codec/ResponseMessageEncoder.java Sat Nov  4 18:31:02 2006
@@ -19,15 +19,18 @@
  */
 package org.apache.directory.mitosis.service.protocol.codec;
 
+
 import org.apache.directory.mitosis.service.protocol.message.BaseMessage;
 import org.apache.directory.mitosis.service.protocol.message.ResponseMessage;
 import org.apache.mina.common.ByteBuffer;
 
+
 public abstract class ResponseMessageEncoder extends BaseMessageEncoder
 {
     public ResponseMessageEncoder()
     {
     }
+
 
     protected void encodeBody( BaseMessage in, ByteBuffer out ) throws Exception
     {

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BaseMessage.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BaseMessage.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BaseMessage.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BaseMessage.java Sat Nov  4 18:31:02 2006
@@ -19,44 +19,51 @@
  */
 package org.apache.directory.mitosis.service.protocol.message;
 
+
 import org.apache.directory.shared.ldap.util.EqualsBuilder;
 import org.apache.directory.shared.ldap.util.HashCodeBuilder;
 
-public abstract class BaseMessage {
+
+public abstract class BaseMessage
+{
 
     private final int sequence;
 
+
     protected BaseMessage( int sequence )
     {
         this.sequence = sequence;
     }
-    
+
+
     public abstract int getType();
 
+
     public int getSequence()
     {
         return sequence;
     }
 
-    public boolean equals(Object object) 
+
+    public boolean equals( Object object )
     {
-        if (!(object instanceof BaseMessage)) 
+        if ( !( object instanceof BaseMessage ) )
         {
             return false;
         }
-        
-        BaseMessage rhs = (BaseMessage) object;
-        
-        return new EqualsBuilder().append(
-                this.sequence, rhs.sequence).isEquals();
+
+        BaseMessage rhs = ( BaseMessage ) object;
+
+        return new EqualsBuilder().append( this.sequence, rhs.sequence ).isEquals();
     }
 
-    public int hashCode() 
+
+    public int hashCode()
     {
-        return new HashCodeBuilder(-1364566505, -1158072471).append(
-                this.sequence).toHashCode();
+        return new HashCodeBuilder( -1364566505, -1158072471 ).append( this.sequence ).toHashCode();
     }
-    
+
+
     public String toString()
     {
         return String.valueOf( sequence );

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BeginLogEntriesAckMessage.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BeginLogEntriesAckMessage.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BeginLogEntriesAckMessage.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BeginLogEntriesAckMessage.java Sat Nov  4 18:31:02 2006
@@ -19,23 +19,24 @@
  */
 package org.apache.directory.mitosis.service.protocol.message;
 
+
 import org.apache.directory.shared.ldap.util.EqualsBuilder;
 import org.apache.directory.shared.ldap.util.HashCodeBuilder;
 import org.apache.directory.mitosis.common.CSNVector;
 import org.apache.directory.mitosis.service.protocol.Constants;
 
+
 public class BeginLogEntriesAckMessage extends ResponseMessage
 {
     private final CSNVector purgeVector;
     private final CSNVector updateVector;
 
-    public BeginLogEntriesAckMessage( int sequence, int responseCode,
-                                      CSNVector purgeVector,
-                                      CSNVector updateVector )
+
+    public BeginLogEntriesAckMessage( int sequence, int responseCode, CSNVector purgeVector, CSNVector updateVector )
     {
         super( sequence, responseCode );
-        
-        if( responseCode == Constants.OK )
+
+        if ( responseCode == Constants.OK )
         {
             assert purgeVector != null;
             assert updateVector != null;
@@ -50,51 +51,57 @@
         }
     }
 
+
     public int getType()
     {
         return Constants.GET_UPDATE_VECTOR_ACK;
     }
-    
+
+
     public CSNVector getPurgeVector()
     {
         return purgeVector;
     }
-    
+
+
     public CSNVector getUpdateVector()
     {
         return updateVector;
     }
 
+
     /**
      * @see java.lang.Object#equals(Object)
      */
-    public boolean equals(Object object) 
+    public boolean equals( Object object )
     {
-        if (object == this) {
+        if ( object == this )
+        {
             return true;
         }
-    
-        if (!(object instanceof BeginLogEntriesAckMessage)) 
+
+        if ( !( object instanceof BeginLogEntriesAckMessage ) )
         {
             return false;
         }
-        
-        BeginLogEntriesAckMessage rhs = (BeginLogEntriesAckMessage) object;
-        
-        return new EqualsBuilder().appendSuper(super.equals(object)).append(
-                this.purgeVector, rhs.purgeVector).append(
-                        this.updateVector, rhs.updateVector).isEquals();
+
+        BeginLogEntriesAckMessage rhs = ( BeginLogEntriesAckMessage ) object;
+
+        return new EqualsBuilder().appendSuper( super.equals( object ) ).append( this.purgeVector, rhs.purgeVector )
+            .append( this.updateVector, rhs.updateVector ).isEquals();
     }
 
+
     /**
      * @see java.lang.Object#hashCode()
      */
-    public int hashCode() 
+    public int hashCode()
     {
-        return new HashCodeBuilder(537917217, 1652875233).appendSuper(
-                super.hashCode()).append(this.purgeVector).append(this.updateVector).toHashCode();
+        return new HashCodeBuilder( 537917217, 1652875233 ).appendSuper( super.hashCode() ).append( this.purgeVector )
+            .append( this.updateVector ).toHashCode();
     }
-    
+
+
     public String toString()
     {
         return "[BeginLogEntriesAck] " + super.toString() + ", PV: " + purgeVector + ", UV: " + updateVector;

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BeginLogEntriesMessage.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BeginLogEntriesMessage.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BeginLogEntriesMessage.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/BeginLogEntriesMessage.java Sat Nov  4 18:31:02 2006
@@ -19,10 +19,12 @@
  */
 package org.apache.directory.mitosis.service.protocol.message;
 
+
 import org.apache.directory.mitosis.service.protocol.Constants;
 import org.apache.directory.shared.ldap.util.EqualsBuilder;
 import org.apache.directory.shared.ldap.util.HashCodeBuilder;
 
+
 public class BeginLogEntriesMessage extends BaseMessage
 {
 
@@ -31,26 +33,29 @@
         super( sequence );
     }
 
+
     public int getType()
     {
         return Constants.BEGIN_LOG_ENTRIES;
     }
 
+
     public boolean equals( final Object other )
     {
-        if( !( other instanceof BeginLogEntriesMessage ) )
+        if ( !( other instanceof BeginLogEntriesMessage ) )
         {
             return false;
         }
-        
+
         return new EqualsBuilder().isEquals();
     }
 
+
     public int hashCode()
     {
-        return new HashCodeBuilder( -1480829129, 951761287 ).appendSuper(
-                super.hashCode() ).toHashCode();
+        return new HashCodeBuilder( -1480829129, 951761287 ).appendSuper( super.hashCode() ).toHashCode();
     }
+
 
     public String toString()
     {

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/EndLogEntriesAckMessage.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/EndLogEntriesAckMessage.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/EndLogEntriesAckMessage.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/EndLogEntriesAckMessage.java Sat Nov  4 18:31:02 2006
@@ -19,10 +19,12 @@
  */
 package org.apache.directory.mitosis.service.protocol.message;
 
+
 import org.apache.directory.mitosis.service.protocol.Constants;
 import org.apache.directory.shared.ldap.util.EqualsBuilder;
 import org.apache.directory.shared.ldap.util.HashCodeBuilder;
 
+
 public class EndLogEntriesAckMessage extends ResponseMessage
 {
 
@@ -31,27 +33,29 @@
         super( sequence, responseCode );
     }
 
+
     public int getType()
     {
         return Constants.END_LOG_ENTRIES_ACK;
     }
 
+
     public boolean equals( Object object )
     {
-        if( !( object instanceof EndLogEntriesAckMessage ) )
+        if ( !( object instanceof EndLogEntriesAckMessage ) )
         {
             return false;
         }
-        
-        return new EqualsBuilder().appendSuper( super.equals( object ) )
-                .isEquals();
+
+        return new EqualsBuilder().appendSuper( super.equals( object ) ).isEquals();
     }
 
+
     public int hashCode()
     {
-        return new HashCodeBuilder( 247639103, -470023671 ).appendSuper(
-                super.hashCode() ).toHashCode();
+        return new HashCodeBuilder( 247639103, -470023671 ).appendSuper( super.hashCode() ).toHashCode();
     }
+
 
     public String toString()
     {

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/EndLogEntriesMessage.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/EndLogEntriesMessage.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/EndLogEntriesMessage.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/EndLogEntriesMessage.java Sat Nov  4 18:31:02 2006
@@ -19,10 +19,12 @@
  */
 package org.apache.directory.mitosis.service.protocol.message;
 
+
 import org.apache.directory.mitosis.service.protocol.Constants;
 import org.apache.directory.shared.ldap.util.EqualsBuilder;
 import org.apache.directory.shared.ldap.util.HashCodeBuilder;
 
+
 public class EndLogEntriesMessage extends BaseMessage
 {
 
@@ -31,26 +33,29 @@
         super( sequence );
     }
 
+
     public int getType()
     {
         return Constants.END_LOG_ENTRIES;
     }
 
+
     public boolean equals( final Object other )
     {
-        if( !( other instanceof EndLogEntriesMessage ) )
+        if ( !( other instanceof EndLogEntriesMessage ) )
         {
             return false;
         }
-        
+
         return new EqualsBuilder().isEquals();
     }
 
+
     public int hashCode()
     {
-        return new HashCodeBuilder( 1892305163, -1367551105 ).appendSuper(
-                super.hashCode() ).toHashCode();
+        return new HashCodeBuilder( 1892305163, -1367551105 ).appendSuper( super.hashCode() ).toHashCode();
     }
+
 
     public String toString()
     {

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LogEntryAckMessage.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LogEntryAckMessage.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LogEntryAckMessage.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LogEntryAckMessage.java Sat Nov  4 18:31:02 2006
@@ -19,49 +19,54 @@
  */
 package org.apache.directory.mitosis.service.protocol.message;
 
+
 import org.apache.directory.mitosis.service.protocol.Constants;
 import org.apache.directory.shared.ldap.util.EqualsBuilder;
 import org.apache.directory.shared.ldap.util.HashCodeBuilder;
 
+
 public class LogEntryAckMessage extends ResponseMessage
 {
     public LogEntryAckMessage( int sequence, int responseCode )
     {
-        super(sequence, responseCode);
+        super( sequence, responseCode );
     }
 
+
     public int getType()
     {
         return Constants.LOG_ENTRY_ACK;
     }
 
+
     /**
      * @see java.lang.Object#equals(Object)
      */
-    public boolean equals(Object object) 
+    public boolean equals( Object object )
     {
-        if (object == this) 
+        if ( object == this )
         {
             return true;
         }
-        
-        if (!(object instanceof LogEntryAckMessage)) 
+
+        if ( !( object instanceof LogEntryAckMessage ) )
         {
             return false;
         }
-        
-        return new EqualsBuilder().appendSuper(super.equals(object)).isEquals();
+
+        return new EqualsBuilder().appendSuper( super.equals( object ) ).isEquals();
     }
 
+
     /**
      * @see java.lang.Object#hashCode()
      */
-    public int hashCode() 
+    public int hashCode()
     {
-        return new HashCodeBuilder(-873557437, -1464393829).appendSuper(
-                super.hashCode()).toHashCode();
+        return new HashCodeBuilder( -873557437, -1464393829 ).appendSuper( super.hashCode() ).toHashCode();
     }
-    
+
+
     public String toString()
     {
         return "[LogEntryAck] " + super.toString();

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LogEntryMessage.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LogEntryMessage.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LogEntryMessage.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LogEntryMessage.java Sat Nov  4 18:31:02 2006
@@ -19,61 +19,69 @@
  */
 package org.apache.directory.mitosis.service.protocol.message;
 
+
 import org.apache.directory.mitosis.operation.Operation;
 import org.apache.directory.mitosis.service.protocol.Constants;
 import org.apache.directory.shared.ldap.util.EqualsBuilder;
 import org.apache.directory.shared.ldap.util.HashCodeBuilder;
 
+
 public class LogEntryMessage extends BaseMessage
 {
     private final Operation operation;
 
+
     public LogEntryMessage( int sequence, Operation operation )
     {
-        super(sequence);
+        super( sequence );
         this.operation = operation;
     }
-    
+
+
     public int getType()
     {
         return Constants.LOG_ENTRY;
     }
-    
+
+
     public Operation getOperation()
     {
         return operation;
     }
 
+
     /**
      * @see java.lang.Object#equals(Object)
      */
-    public boolean equals(Object object) 
+    public boolean equals( Object object )
     {
-        if (object == this) {
+        if ( object == this )
+        {
             return true;
         }
-    
-        if (!(object instanceof LogEntryMessage)) 
+
+        if ( !( object instanceof LogEntryMessage ) )
         {
             return false;
         }
-        
-        LogEntryMessage rhs = (LogEntryMessage) object;
-        
-        return new EqualsBuilder().appendSuper(super.equals(object)).append(
-                this.operation, rhs.operation).isEquals();
+
+        LogEntryMessage rhs = ( LogEntryMessage ) object;
+
+        return new EqualsBuilder().appendSuper( super.equals( object ) ).append( this.operation, rhs.operation )
+            .isEquals();
     }
 
+
     /**
      * @see java.lang.Object#hashCode()
      */
-    public int hashCode() 
+    public int hashCode()
     {
-        return new HashCodeBuilder(633013569, -1063609843).appendSuper(
-                super.hashCode()).append(this.operation)
-                .toHashCode();
+        return new HashCodeBuilder( 633013569, -1063609843 ).appendSuper( super.hashCode() ).append( this.operation )
+            .toHashCode();
     }
-    
+
+
     public String toString()
     {
         return "[LogEntry] " + super.toString() + ", " + operation;

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LoginAckMessage.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LoginAckMessage.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LoginAckMessage.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LoginAckMessage.java Sat Nov  4 18:31:02 2006
@@ -19,61 +19,69 @@
  */
 package org.apache.directory.mitosis.service.protocol.message;
 
+
 import org.apache.directory.shared.ldap.util.EqualsBuilder;
 import org.apache.directory.shared.ldap.util.HashCodeBuilder;
 import org.apache.directory.mitosis.common.ReplicaId;
 import org.apache.directory.mitosis.service.protocol.Constants;
 
+
 public class LoginAckMessage extends ResponseMessage
 {
     private ReplicaId replicaId;
 
+
     public LoginAckMessage( int sequence, int responseCode, ReplicaId replicaId )
     {
-        super(sequence, responseCode);
+        super( sequence, responseCode );
         this.replicaId = replicaId;
     }
 
+
     public int getType()
     {
         return Constants.LOGIN_ACK;
     }
 
+
     public ReplicaId getReplicaId()
     {
         return replicaId;
     }
 
+
     /**
      * @see java.lang.Object#equals(Object)
      */
-    public boolean equals(Object object) 
+    public boolean equals( Object object )
     {
-        if (object == this) 
+        if ( object == this )
         {
             return true;
         }
-        
-        if (!(object instanceof LoginAckMessage)) 
+
+        if ( !( object instanceof LoginAckMessage ) )
         {
             return false;
         }
-        
-        LoginAckMessage rhs = (LoginAckMessage) object;
-        
-        return new EqualsBuilder().appendSuper(super.equals(object)).
-                append(this.replicaId, rhs.replicaId).isEquals();
+
+        LoginAckMessage rhs = ( LoginAckMessage ) object;
+
+        return new EqualsBuilder().appendSuper( super.equals( object ) ).append( this.replicaId, rhs.replicaId )
+            .isEquals();
     }
 
+
     /**
      * @see java.lang.Object#hashCode()
      */
-    public int hashCode() 
+    public int hashCode()
     {
-        return new HashCodeBuilder(-280394717, -328404193).appendSuper(
-                super.hashCode()).append(this.replicaId).toHashCode();
+        return new HashCodeBuilder( -280394717, -328404193 ).appendSuper( super.hashCode() ).append( this.replicaId )
+            .toHashCode();
     }
-    
+
+
     public String toString()
     {
         return "[LoginAck] " + super.toString() + ", " + replicaId;

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LoginMessage.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LoginMessage.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LoginMessage.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/LoginMessage.java Sat Nov  4 18:31:02 2006
@@ -19,56 +19,64 @@
  */
 package org.apache.directory.mitosis.service.protocol.message;
 
+
 import org.apache.directory.shared.ldap.util.EqualsBuilder;
 import org.apache.directory.shared.ldap.util.HashCodeBuilder;
 import org.apache.directory.mitosis.common.ReplicaId;
 import org.apache.directory.mitosis.service.protocol.Constants;
 
+
 public class LoginMessage extends BaseMessage
 {
     private final ReplicaId replicaId;
 
+
     public LoginMessage( int sequence, ReplicaId replicaId )
     {
         super( sequence );
-        
+
         this.replicaId = replicaId;
     }
-    
+
+
     public int getType()
     {
         return Constants.LOGIN;
     }
-    
+
+
     public ReplicaId getReplicaId()
     {
         return replicaId;
     }
 
+
     /**
      * @see java.lang.Object#equals(Object)
      */
-    public boolean equals(Object object)
+    public boolean equals( Object object )
     {
-        if (!(object instanceof LoginMessage)) 
+        if ( !( object instanceof LoginMessage ) )
         {
             return false;
         }
-        
-        LoginMessage rhs = (LoginMessage) object;
-        
-        return new EqualsBuilder().appendSuper(super.equals(object)).append(
-                this.replicaId, rhs.replicaId).isEquals();
+
+        LoginMessage rhs = ( LoginMessage ) object;
+
+        return new EqualsBuilder().appendSuper( super.equals( object ) ).append( this.replicaId, rhs.replicaId )
+            .isEquals();
     }
 
+
     /**
      * @see java.lang.Object#hashCode()
      */
-    public int hashCode() 
+    public int hashCode()
     {
-        return new HashCodeBuilder(1520317245, 1630850531).appendSuper(
-                super.hashCode()).append(this.replicaId).toHashCode();
+        return new HashCodeBuilder( 1520317245, 1630850531 ).appendSuper( super.hashCode() ).append( this.replicaId )
+            .toHashCode();
     }
+
 
     public String toString()
     {

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/ResponseMessage.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/ResponseMessage.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/ResponseMessage.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/message/ResponseMessage.java Sat Nov  4 18:31:02 2006
@@ -19,55 +19,62 @@
  */
 package org.apache.directory.mitosis.service.protocol.message;
 
+
 import org.apache.directory.shared.ldap.util.EqualsBuilder;
 import org.apache.directory.shared.ldap.util.HashCodeBuilder;
 
+
 public abstract class ResponseMessage extends BaseMessage
 {
     private final int responseCode;
-    
+
+
     public ResponseMessage( int sequence, int responseCode )
     {
-        super(sequence);
-        
+        super( sequence );
+
         this.responseCode = responseCode;
     }
 
+
     public int getResponseCode()
     {
         return responseCode;
     }
 
+
     /**
      * @see java.lang.Object#equals(Object)
      */
-    public boolean equals(Object object) 
+    public boolean equals( Object object )
     {
-        if (object == this) 
+        if ( object == this )
         {
             return true;
         }
-        
-        if (!(object instanceof ResponseMessage)) 
+
+        if ( !( object instanceof ResponseMessage ) )
         {
             return false;
         }
-        
-        ResponseMessage rhs = (ResponseMessage) object;
-        
-        return new EqualsBuilder().appendSuper(super.equals(object)).append(
-                this.responseCode, rhs.responseCode).isEquals();
+
+        ResponseMessage rhs = ( ResponseMessage ) object;
+
+        return new EqualsBuilder().appendSuper( super.equals( object ) ).append( this.responseCode, rhs.responseCode )
+            .isEquals();
     }
 
+
     /**
      * @see java.lang.Object#hashCode()
      */
-    public int hashCode() 
+    public int hashCode()
     {
-        return new HashCodeBuilder(-710373179, 1116475565).appendSuper(
-                super.hashCode()).append(this.responseCode).toHashCode();
+        return new HashCodeBuilder( -710373179, 1116475565 ).appendSuper( super.hashCode() ).append( this.responseCode )
+            .toHashCode();
     }
-    
+
+
     public String toString()
     {
         return super.toString() + ": " + responseCode;

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationLogIterator.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationLogIterator.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationLogIterator.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationLogIterator.java Sat Nov  4 18:31:02 2006
@@ -19,10 +19,17 @@
  */
 package org.apache.directory.mitosis.store;
 
+
 import org.apache.directory.mitosis.operation.Operation;
 
-public interface ReplicationLogIterator {
+
+public interface ReplicationLogIterator
+{
     boolean next();
+
+
     void close();
+
+
     Operation getOperation();
 }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationStore.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationStore.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationStore.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationStore.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.store;
 
+
 import java.util.Set;
 
 import javax.naming.Name;
@@ -31,39 +32,55 @@
 import org.apache.directory.mitosis.configuration.ReplicationConfiguration;
 import org.apache.directory.mitosis.operation.Operation;
 
-public interface ReplicationStore {
+
+public interface ReplicationStore
+{
 
     void open( DirectoryServiceConfiguration serviceCfg, ReplicationConfiguration cfg );
-    
+
+
     void close();
-    
+
+
     ReplicaId getReplicaId();
-    
+
+
     Set getKnownReplicaIds();
-    
+
+
     // UUID to DN table operations
-    
+
     Name getDN( UUID uuid );
-    
+
+
     boolean putUUID( UUID uuid, Name dn );
-    
+
+
     boolean removeUUID( UUID uuid );
-    
+
+
     // Log entry operations
-    
+
     void putLog( Operation operation );
-    
+
+
     ReplicationLogIterator getLogs( CSN fromCSN, boolean inclusive );
 
+
     ReplicationLogIterator getLogs( CSNVector updateVector, boolean inclusive );
 
+
     int removeLogs( CSN toCSN, boolean inclusive );
-    
+
+
     int getLogSize();
-    
+
+
     int getLogSize( ReplicaId replicaId );
-    
+
+
     CSNVector getUpdateVector();
-    
+
+
     CSNVector getPurgeVector();
 }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationStoreException.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationStoreException.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationStoreException.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/ReplicationStoreException.java Sat Nov  4 18:31:02 2006
@@ -19,23 +19,33 @@
  */
 package org.apache.directory.mitosis.store;
 
-public class ReplicationStoreException extends RuntimeException {
+
+public class ReplicationStoreException extends RuntimeException
+{
 
     private static final long serialVersionUID = 3257289127798913336L;
 
-    public ReplicationStoreException() {
+
+    public ReplicationStoreException()
+    {
         super();
     }
 
-    public ReplicationStoreException(String message) {
-        super(message);
+
+    public ReplicationStoreException( String message )
+    {
+        super( message );
     }
 
-    public ReplicationStoreException(String message, Throwable cause) {
-        super(message, cause);
+
+    public ReplicationStoreException( String message, Throwable cause )
+    {
+        super( message, cause );
     }
 
-    public ReplicationStoreException(Throwable cause) {
-        super(cause);
+
+    public ReplicationStoreException( Throwable cause )
+    {
+        super( cause );
     }
 }

Modified: directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationLogIterator.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationLogIterator.java?view=diff&rev=471336&r1=471335&r2=471336
==============================================================================
--- directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationLogIterator.java (original)
+++ directory/trunks/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationLogIterator.java Sat Nov  4 18:31:02 2006
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.mitosis.store.derby;
 
+
 import java.sql.Connection;
 import java.sql.ResultSet;
 import java.sql.SQLException;
@@ -32,15 +33,16 @@
 import org.apache.directory.mitosis.store.ReplicationLogIterator;
 import org.apache.directory.mitosis.store.ReplicationStoreException;
 
+
 class DerbyReplicationLogIterator implements ReplicationLogIterator
 {
     private final OperationCodec codec;
     private final Connection con;
     private final Statement stmt;
     private final ResultSet rs;
-    
-    DerbyReplicationLogIterator( OperationCodec codec,
-                                Connection con, Statement stmt, ResultSet rs )
+
+
+    DerbyReplicationLogIterator( OperationCodec codec, Connection con, Statement stmt, ResultSet rs )
     {
         this.codec = codec;
         this.con = con;
@@ -48,21 +50,26 @@
         this.rs = rs;
     }
 
-    public boolean next() {
+
+    public boolean next()
+    {
         try
         {
             return rs.next();
         }
-        catch( SQLException e )
+        catch ( SQLException e )
         {
             throw new ReplicationStoreException( e );
         }
     }
 
-    public void close() {
+
+    public void close()
+    {
         SQLUtil.cleanup( con, stmt, rs );
     }
-    
+
+
     public CSN getCSN()
     {
         try
@@ -72,19 +79,20 @@
             int operationSequence = rs.getInt( 3 );
             return new SimpleCSN( timestamp, replicaId, operationSequence );
         }
-        catch( Exception e )
+        catch ( Exception e )
         {
             throw new ReplicationStoreException( e );
         }
     }
-    
+
+
     public Operation getOperation()
     {
         try
         {
             return codec.decode( rs.getBytes( 4 ) );
         }
-        catch( Exception e )
+        catch ( Exception e )
         {
             throw new ReplicationStoreException( e );
         }



Mime
View raw message