directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r376623 [30/38] - in /directory/sandbox/akarasulu/rc1/apacheds: core-plugin/src/main/java/org/apache/directory/server/core/tools/schema/ core-plugin/src/test/java/org/apache/directory/server/core/tools/schema/ core-shared/src/main/java/org/...
Date Fri, 10 Feb 2006 10:49:57 GMT
Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/decoder/ResourceRecordDecoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/decoder/ResourceRecordDecoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/decoder/ResourceRecordDecoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/decoder/ResourceRecordDecoder.java Fri Feb 10 02:48:07 2006
@@ -17,34 +17,41 @@
 
 package org.apache.directory.server.dns.io.decoder;
 
+
 import java.nio.ByteBuffer;
 
+
 public class ResourceRecordDecoder
 {
     protected short getUnsignedByte( ByteBuffer byteBuffer )
     {
-        return ( (short) ( byteBuffer.get() & 0xff ) );
+        return ( ( short ) ( byteBuffer.get() & 0xff ) );
     }
 
+
     protected short getUnsignedByte( ByteBuffer byteBuffer, int position )
     {
-        return ( (short) ( byteBuffer.get( position ) & (short) 0xff ) );
+        return ( ( short ) ( byteBuffer.get( position ) & ( short ) 0xff ) );
     }
 
+
     protected int getUnsignedShort( ByteBuffer byteBuffer )
     {
         return ( byteBuffer.getShort() & 0xffff );
     }
 
+
     protected int getUnsignedShort( ByteBuffer byteBuffer, int position )
     {
         return ( byteBuffer.getShort( position ) & 0xffff );
     }
 
+
     protected long getUnsignedInt( ByteBuffer byteBuffer )
     {
         return ( byteBuffer.getInt() & 0xffffffffL );
     }
+
 
     protected long getUnsignedInt( ByteBuffer byteBuffer, int position )
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/A6RecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/A6RecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/A6RecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/A6RecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 3.1.1.  Format
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/AddressRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/AddressRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/AddressRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/AddressRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,11 +17,13 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import java.net.InetAddress;
 import java.net.UnknownHostException;
 
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.directory.server.dns.store.DnsAttribute;
+
 
 /**
  * 3.4.1. A RDATA format

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/CanonicalNameRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/CanonicalNameRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/CanonicalNameRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/CanonicalNameRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,8 +17,10 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.directory.server.dns.store.DnsAttribute;
+
 
 /**
  * 3.3.1. CNAME RDATA format

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/CertificateRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/CertificateRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/CertificateRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/CertificateRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 2. The CERT Resource Record
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/DnameRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/DnameRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/DnameRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/DnameRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 3. The DNAME Resource Record
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/HostInformationRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/HostInformationRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/HostInformationRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/HostInformationRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 3.3.2. HINFO RDATA format
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/Inet6AddressRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/Inet6AddressRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/Inet6AddressRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/Inet6AddressRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 2. New resource record definition and domain
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/KeyExchangeRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/KeyExchangeRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/KeyExchangeRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/KeyExchangeRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 3.1 KX RDATA format
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/KeyRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/KeyRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/KeyRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/KeyRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 3. The KEY Resource Record
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/LocationRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/LocationRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/LocationRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/LocationRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 2. RDATA Format
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/MailExchangeRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/MailExchangeRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/MailExchangeRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/MailExchangeRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,11 +17,13 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import java.nio.ByteBuffer;
 
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.directory.server.dns.store.DnsAttribute;
 
+
 /**
  * 3.3.9. MX RDATA format
  * 
@@ -54,7 +56,7 @@
         byteBuffer.put( encodeDomainName( record.get( DnsAttribute.DOMAIN_NAME ) ) );
 
         byteBuffer.flip();
-        byte[] bytes = new byte[ byteBuffer.remaining() ];
+        byte[] bytes = new byte[byteBuffer.remaining()];
         byteBuffer.get( bytes, 0, bytes.length );
 
         return bytes;

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/MailInformationRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/MailInformationRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/MailInformationRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/MailInformationRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 3.3.7. MINFO RDATA format (EXPERIMENTAL)
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NameAuthorityPointerEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NameAuthorityPointerEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NameAuthorityPointerEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NameAuthorityPointerEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 4. NAPTR RR Format
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NameServerRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NameServerRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NameServerRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NameServerRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,8 +17,10 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.directory.server.dns.store.DnsAttribute;
+
 
 /**
  * 3.3.11. NS RDATA format

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NextNameRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NextNameRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NextNameRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/NextNameRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 5.2 NXT RDATA Format
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/PointerRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/PointerRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/PointerRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/PointerRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,8 +17,10 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.directory.server.dns.store.DnsAttribute;
+
 
 /**
  * 3.3.12. PTR RDATA format

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/QuestionRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/QuestionRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/QuestionRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/QuestionRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,11 +17,13 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import org.apache.directory.server.dns.messages.QuestionRecord;
 import org.apache.directory.server.dns.messages.RecordClass;
 import org.apache.directory.server.dns.messages.RecordType;
 import org.apache.mina.common.ByteBuffer;
 
+
 public class QuestionRecordEncoder
 {
     public void encode( ByteBuffer out, QuestionRecord question )
@@ -31,31 +33,34 @@
         encodeRecordClass( out, question.getRecordClass() );
     }
 
+
     private void encodeDomainName( ByteBuffer byteBuffer, String domainName )
     {
         String[] labels = domainName.split( "\\." );
 
         for ( int ii = 0; ii < labels.length; ii++ )
         {
-            byteBuffer.put( (byte) labels[ ii ].length() );
+            byteBuffer.put( ( byte ) labels[ii].length() );
 
-            char[] characters = labels[ ii ].toCharArray();
+            char[] characters = labels[ii].toCharArray();
             for ( int jj = 0; jj < characters.length; jj++ )
             {
-                byteBuffer.put( (byte) characters[ jj ] );
+                byteBuffer.put( ( byte ) characters[jj] );
             }
         }
 
-        byteBuffer.put( (byte) 0x00 );
+        byteBuffer.put( ( byte ) 0x00 );
     }
 
+
     private void encodeRecordType( ByteBuffer byteBuffer, RecordType recordType )
     {
-        byteBuffer.putShort( (short) recordType.getOrdinal() );
+        byteBuffer.putShort( ( short ) recordType.getOrdinal() );
     }
 
+
     private void encodeRecordClass( ByteBuffer byteBuffer, RecordClass recordClass )
     {
-        byteBuffer.putShort( (short) recordClass.getOrdinal() );
+        byteBuffer.putShort( ( short ) recordClass.getOrdinal() );
     }
 }

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/RecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/RecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/RecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/RecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,10 +17,12 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import java.io.IOException;
 
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.mina.common.ByteBuffer;
+
 
 public interface RecordEncoder
 {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/ResourceRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/ResourceRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/ResourceRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/ResourceRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import java.io.IOException;
 
 import org.apache.directory.server.dns.messages.RecordClass;
@@ -24,10 +25,12 @@
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.mina.common.ByteBuffer;
 
+
 public abstract class ResourceRecordEncoder implements RecordEncoder
 {
     protected abstract byte[] encodeResourceData( ResourceRecord record );
 
+
     public void encode( ByteBuffer out, ResourceRecord record ) throws IOException
     {
         encodeDomainName( out, record.getDomainName() );
@@ -38,10 +41,11 @@
 
         byte[] resourceData = encodeResourceData( record );
 
-        out.putShort( (short) resourceData.length );
+        out.putShort( ( short ) resourceData.length );
         out.put( resourceData );
     }
 
+
     /**
      * <domain-name> is a domain name represented as a series of labels, and
      * terminated by a label with zero length.
@@ -55,12 +59,13 @@
         encodeDomainName( byteBuffer, domainName );
 
         byteBuffer.flip();
-        byte[] bytes = new byte[ byteBuffer.remaining() ];
+        byte[] bytes = new byte[byteBuffer.remaining()];
         byteBuffer.get( bytes, 0, bytes.length );
 
         return bytes;
     }
 
+
     /**
      * <domain-name> is a domain name represented as a series of labels, and
      * terminated by a label with zero length.
@@ -73,28 +78,31 @@
 
         for ( int ii = 0; ii < labels.length; ii++ )
         {
-            byteBuffer.put( (byte) labels[ ii ].length() );
+            byteBuffer.put( ( byte ) labels[ii].length() );
 
-            char[] characters = labels[ ii ].toCharArray();
+            char[] characters = labels[ii].toCharArray();
             for ( int jj = 0; jj < characters.length; jj++ )
             {
-                byteBuffer.put( (byte) characters[ jj ] );
+                byteBuffer.put( ( byte ) characters[jj] );
             }
         }
 
-        byteBuffer.put( (byte) 0x00 );
+        byteBuffer.put( ( byte ) 0x00 );
     }
 
+
     protected void encodeRecordType( ByteBuffer byteBuffer, RecordType recordType )
     {
-        byteBuffer.putShort( (short) recordType.getOrdinal() );
+        byteBuffer.putShort( ( short ) recordType.getOrdinal() );
     }
 
+
     protected void encodeRecordClass( ByteBuffer byteBuffer, RecordClass recordClass )
     {
-        byteBuffer.putShort( (short) recordClass.getOrdinal() );
+        byteBuffer.putShort( ( short ) recordClass.getOrdinal() );
     }
 
+
     /**
      * <character-string> is a single length octet followed by that number
      * of characters.  <character-string> is treated as binary information,
@@ -106,49 +114,55 @@
     {
         ByteBuffer byteBuffer = ByteBuffer.allocate( 256 );
 
-        byteBuffer.put( (byte) characterString.length() );
+        byteBuffer.put( ( byte ) characterString.length() );
 
         char[] characters = characterString.toCharArray();
 
         for ( int ii = 0; ii < characters.length; ii++ )
         {
-            byteBuffer.put( (byte) characters[ ii ] );
+            byteBuffer.put( ( byte ) characters[ii] );
         }
 
         byteBuffer.flip();
-        byte[] bytes = new byte[ byteBuffer.remaining() ];
+        byte[] bytes = new byte[byteBuffer.remaining()];
         byteBuffer.get( bytes, 0, bytes.length );
 
         return bytes;
     }
 
+
     protected void putUnsignedByte( ByteBuffer byteBuffer, int value )
     {
-        byteBuffer.put( (byte) ( value & 0xff ) );
+        byteBuffer.put( ( byte ) ( value & 0xff ) );
     }
 
+
     protected void putUnsignedByte( ByteBuffer byteBuffer, int position, int value )
     {
-        byteBuffer.put( position, (byte) ( value & 0xff ) );
+        byteBuffer.put( position, ( byte ) ( value & 0xff ) );
     }
 
+
     protected void putUnsignedShort( ByteBuffer byteBuffer, int value )
     {
-        byteBuffer.putShort( (short) ( value & 0xffff ) );
+        byteBuffer.putShort( ( short ) ( value & 0xffff ) );
     }
 
+
     protected void putUnsignedShort( ByteBuffer byteBuffer, int position, int value )
     {
-        byteBuffer.putShort( position, (short) ( value & 0xffff ) );
+        byteBuffer.putShort( position, ( short ) ( value & 0xffff ) );
     }
 
+
     protected void putUnsignedInt( ByteBuffer byteBuffer, long value )
     {
-        byteBuffer.putInt( (int) ( value & 0xffffffffL ) );
+        byteBuffer.putInt( ( int ) ( value & 0xffffffffL ) );
     }
 
+
     protected void putUnsignedInt( ByteBuffer byteBuffer, int position, long value )
     {
-        byteBuffer.putInt( position, (int) ( value & 0xffffffffL ) );
+        byteBuffer.putInt( position, ( int ) ( value & 0xffffffffL ) );
     }
 }

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/ServerSelectionRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/ServerSelectionRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/ServerSelectionRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/ServerSelectionRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,11 +17,13 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import java.nio.ByteBuffer;
 
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.directory.server.dns.store.DnsAttribute;
 
+
 /**
  * The format of the SRV RR
  * 
@@ -132,7 +134,7 @@
         byteBuffer.put( encodeDomainName( record.get( DnsAttribute.DOMAIN_NAME ) ) );
 
         byteBuffer.flip();
-        byte[] bytes = new byte[ byteBuffer.remaining() ];
+        byte[] bytes = new byte[byteBuffer.remaining()];
         byteBuffer.get( bytes, 0, bytes.length );
 
         return bytes;

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/SignatureRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/SignatureRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/SignatureRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/SignatureRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 4.1 SIG RDATA Format
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/StartOfAuthorityRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/StartOfAuthorityRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/StartOfAuthorityRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/StartOfAuthorityRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,10 +17,12 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.directory.server.dns.store.DnsAttribute;
 import org.apache.mina.common.ByteBuffer;
 
+
 /**
  * 3.3.13. SOA RDATA format
  * 
@@ -113,7 +115,7 @@
         putUnsignedInt( byteBuffer, minimum );
 
         byteBuffer.flip();
-        byte[] bytes = new byte[ byteBuffer.remaining() ];
+        byte[] bytes = new byte[byteBuffer.remaining()];
         byteBuffer.get( bytes, 0, bytes.length );
 
         return bytes;

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/TextRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/TextRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/TextRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/TextRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,8 +17,10 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.directory.server.dns.store.DnsAttribute;
+
 
 /**
  * 3.3.14. TXT RDATA format

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/WellKnownServicesRecordEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/WellKnownServicesRecordEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/WellKnownServicesRecordEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/io/encoder/WellKnownServicesRecordEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.io.encoder;
 
+
 /**
  * 3.4.2. WKS RDATA format
  * 

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/DnsMessage.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/DnsMessage.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/DnsMessage.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/DnsMessage.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 /**
  * All communications inside of the domain protocol are carried in a single
  * format called a message.  The top level format of message is divided
@@ -59,10 +60,11 @@
     private ResourceRecords authorityRecords;
     private ResourceRecords additionalRecords;
 
-    public DnsMessage( short transactionId, MessageType messageType, OpCode opCode, boolean authoritativeAnswer,
-            boolean truncated, boolean recursionDesired, boolean recursionAvailable, boolean reserved,
-            boolean acceptNonAuthenticatedData, ResponseCode responseCode, QuestionRecords question,
-            ResourceRecords answer, ResourceRecords authority, ResourceRecords additional )
+
+    public DnsMessage(short transactionId, MessageType messageType, OpCode opCode, boolean authoritativeAnswer,
+        boolean truncated, boolean recursionDesired, boolean recursionAvailable, boolean reserved,
+        boolean acceptNonAuthenticatedData, ResponseCode responseCode, QuestionRecords question,
+        ResourceRecords answer, ResourceRecords authority, ResourceRecords additional)
     {
         this.transactionId = transactionId;
         this.messageType = messageType;
@@ -80,6 +82,7 @@
         this.additionalRecords = additional;
     }
 
+
     /**
      * @return Returns the acceptNonAuthenticatedData.
      */
@@ -88,6 +91,7 @@
         return acceptNonAuthenticatedData;
     }
 
+
     /**
      * @return Returns the additional.
      */
@@ -96,6 +100,7 @@
         return additionalRecords;
     }
 
+
     /**
      * @return Returns the answers.
      */
@@ -104,6 +109,7 @@
         return answerRecords;
     }
 
+
     /**
      * @return Returns the authoritativeAnswer.
      */
@@ -112,6 +118,7 @@
         return authoritativeAnswer;
     }
 
+
     /**
      * @return Returns the authority.
      */
@@ -120,6 +127,7 @@
         return authorityRecords;
     }
 
+
     /**
      * @return Returns the messageType.
      */
@@ -128,6 +136,7 @@
         return messageType;
     }
 
+
     /**
      * @return Returns the opCode.
      */
@@ -136,6 +145,7 @@
         return opCode;
     }
 
+
     /**
      * @return Returns the question.
      */
@@ -144,6 +154,7 @@
         return questionRecords;
     }
 
+
     /**
      * @return Returns the recursionAvailable.
      */
@@ -152,6 +163,7 @@
         return recursionAvailable;
     }
 
+
     /**
      * @return Returns the recursionDesired.
      */
@@ -160,6 +172,7 @@
         return recursionDesired;
     }
 
+
     /**
      * @return Returns the reserved.
      */
@@ -168,6 +181,7 @@
         return reserved;
     }
 
+
     /**
      * @return Returns the responseCode.
      */
@@ -176,6 +190,7 @@
         return responseCode;
     }
 
+
     /**
      * @return Returns the transactionId.
      */
@@ -184,6 +199,7 @@
         return transactionId;
     }
 
+
     /**
      * @return Returns the truncated.
      */
@@ -191,6 +207,7 @@
     {
         return truncated;
     }
+
 
     public String toString()
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/DnsMessageModifier.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/DnsMessageModifier.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/DnsMessageModifier.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/DnsMessageModifier.java Fri Feb 10 02:48:07 2006
@@ -60,13 +60,15 @@
     private ResourceRecords authorityRecords;
     private ResourceRecords additionalRecords;
 
+
     public DnsMessage getDnsMessage()
     {
         return new DnsMessage( transactionId, messageType, opCode, authoritativeAnswer, truncated, recursionDesired,
-                recursionAvailable, reserved, acceptNonAuthenticatedData, responseCode, questionRecords, answerRecords,
-                authorityRecords, additionalRecords );
+            recursionAvailable, reserved, acceptNonAuthenticatedData, responseCode, questionRecords, answerRecords,
+            authorityRecords, additionalRecords );
     }
 
+
     /**
      * @param acceptNonAuthenticatedData The acceptNonAuthenticatedData to set.
      */
@@ -75,6 +77,7 @@
         this.acceptNonAuthenticatedData = acceptNonAuthenticatedData;
     }
 
+
     /**
      * @param additionalRecords The additional to set.
      */
@@ -83,6 +86,7 @@
         this.additionalRecords = additionalRecords;
     }
 
+
     /**
      * @param answerRecords The answer to set.
      */
@@ -91,6 +95,7 @@
         this.answerRecords = answerRecords;
     }
 
+
     /**
      * @param authoritativeAnswer The authoritativeAnswer to set.
      */
@@ -99,6 +104,7 @@
         this.authoritativeAnswer = authoritativeAnswer;
     }
 
+
     /**
      * @param authorityRecords The authority to set.
      */
@@ -107,6 +113,7 @@
         this.authorityRecords = authorityRecords;
     }
 
+
     /**
      * @param messageType The messageType to set.
      */
@@ -115,6 +122,7 @@
         this.messageType = messageType;
     }
 
+
     /**
      * @param opCode The opCode to set.
      */
@@ -123,6 +131,7 @@
         this.opCode = opCode;
     }
 
+
     /**
      * @param questionRecords The question to set.
      */
@@ -131,6 +140,7 @@
         this.questionRecords = questionRecords;
     }
 
+
     /**
      * @param recursionAvailable The recursionAvailable to set.
      */
@@ -139,6 +149,7 @@
         this.recursionAvailable = recursionAvailable;
     }
 
+
     /**
      * @param recursionDesired The recursionDesired to set.
      */
@@ -147,6 +158,7 @@
         this.recursionDesired = recursionDesired;
     }
 
+
     /**
      * @param reserved The reserved to set.
      */
@@ -155,6 +167,7 @@
         this.reserved = reserved;
     }
 
+
     /**
      * @param responseCode The responseCode to set.
      */
@@ -163,6 +176,7 @@
         this.responseCode = responseCode;
     }
 
+
     /**
      * @param transactionId The transactionId to set.
      */
@@ -170,6 +184,7 @@
     {
         this.transactionId = transactionId;
     }
+
 
     /**
      * @param truncated The truncated to set.

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/MessageType.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/MessageType.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/MessageType.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/MessageType.java Fri Feb 10 02:48:07 2006
@@ -17,10 +17,12 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
 
+
 public final class MessageType implements Comparable
 {
     /**
@@ -33,44 +35,50 @@
     /**
      * These two lines are all that's necessary to export a List of VALUES.
      */
-    private static final MessageType[] values = { QUERY, RESPONSE };
+    private static final MessageType[] values =
+        { QUERY, RESPONSE };
 
     public static final List VALUES = Collections.unmodifiableList( Arrays.asList( values ) );
 
     private final String name;
     private final int ordinal;
 
+
     /**
      * Private constructor prevents construction outside of this class.
      */
-    private MessageType( int ordinal, String name )
+    private MessageType(int ordinal, String name)
     {
         this.ordinal = ordinal;
         this.name = name;
     }
 
+
     public String toString()
     {
         return name;
     }
 
+
     public int compareTo( Object that )
     {
-        return ordinal - ( (MessageType) that ).ordinal;
+        return ordinal - ( ( MessageType ) that ).ordinal;
     }
 
+
     public static MessageType getTypeByOrdinal( int type )
     {
         for ( int ii = 0; ii < values.length; ii++ )
         {
-            if ( values[ ii ].ordinal == type )
+            if ( values[ii].ordinal == type )
             {
-                return values[ ii ];
+                return values[ii];
             }
         }
 
         return QUERY;
     }
+
 
     public int getOrdinal()
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/OpCode.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/OpCode.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/OpCode.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/OpCode.java Fri Feb 10 02:48:07 2006
@@ -17,10 +17,12 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
 
+
 public final class OpCode implements Comparable
 {
     /**
@@ -36,44 +38,50 @@
     /**
      * These two lines are all that's necessary to export a List of VALUES.
      */
-    private static final OpCode[] values = { QUERY, IQUERY, STATUS, NOTIFY, UPDATE };
+    private static final OpCode[] values =
+        { QUERY, IQUERY, STATUS, NOTIFY, UPDATE };
 
     public static final List VALUES = Collections.unmodifiableList( Arrays.asList( values ) );
 
     private final String name;
     private final int ordinal;
 
+
     /**
      * Private constructor prevents construction outside of this class.
      */
-    private OpCode( int ordinal, String name )
+    private OpCode(int ordinal, String name)
     {
         this.ordinal = ordinal;
         this.name = name;
     }
 
+
     public String toString()
     {
         return name;
     }
 
+
     public int compareTo( Object that )
     {
-        return ordinal - ( (OpCode) that ).ordinal;
+        return ordinal - ( ( OpCode ) that ).ordinal;
     }
 
+
     public static OpCode getTypeByOrdinal( int type )
     {
         for ( int ii = 0; ii < values.length; ii++ )
         {
-            if ( values[ ii ].ordinal == type )
+            if ( values[ii].ordinal == type )
             {
-                return values[ ii ];
+                return values[ii];
             }
         }
 
         return QUERY;
     }
+
 
     public int getOrdinal()
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ProtocolType.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ProtocolType.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ProtocolType.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ProtocolType.java Fri Feb 10 02:48:07 2006
@@ -17,10 +17,12 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
 
+
 public final class ProtocolType implements Comparable
 {
     /**
@@ -74,47 +76,52 @@
     /**
      * These two lines are all that's necessary to export a List of VALUES.
      */
-    private static final ProtocolType[] values = { NULL, ICMP, IGMP, GGP, ST, TCP, UCL, EGP, IGP, BBN_RCC_MON, NVP_II,
-            PUP, ARGUS, EMCON, XNET, CHAOS, UDP, MUX, DCN_MEAS, HMP, PRM, XNS_IDP, TRUNK_1, TRUNK_2, LEAF_1, LEAF_2,
-            RDP, IRTP, ISO_TP4, NETBLT, MFE_NSP, MERIT_INP, SEP, CFTP, SAT_EXPAK, MIT_SUBNET, RVD, IPPC, SAT_MON, IPCV,
-            BR_SAT_MON, WB_MON, WB_EXPAK };
+    private static final ProtocolType[] values =
+        { NULL, ICMP, IGMP, GGP, ST, TCP, UCL, EGP, IGP, BBN_RCC_MON, NVP_II, PUP, ARGUS, EMCON, XNET, CHAOS, UDP, MUX,
+            DCN_MEAS, HMP, PRM, XNS_IDP, TRUNK_1, TRUNK_2, LEAF_1, LEAF_2, RDP, IRTP, ISO_TP4, NETBLT, MFE_NSP,
+            MERIT_INP, SEP, CFTP, SAT_EXPAK, MIT_SUBNET, RVD, IPPC, SAT_MON, IPCV, BR_SAT_MON, WB_MON, WB_EXPAK };
 
     public static final List VALUES = Collections.unmodifiableList( Arrays.asList( values ) );
 
     private final String name;
     private final int ordinal;
 
+
     /**
      * Private constructor prevents construction outside of this class.
      */
-    private ProtocolType( int ordinal, String name )
+    private ProtocolType(int ordinal, String name)
     {
         this.ordinal = ordinal;
         this.name = name;
     }
 
+
     public String toString()
     {
         return name;
     }
 
+
     public int compareTo( Object that )
     {
-        return ordinal - ( (ProtocolType) that ).ordinal;
+        return ordinal - ( ( ProtocolType ) that ).ordinal;
     }
 
+
     public static ProtocolType getTypeByOrdinal( int type )
     {
         for ( int ii = 0; ii < values.length; ii++ )
         {
-            if ( values[ ii ].ordinal == type )
+            if ( values[ii].ordinal == type )
             {
-                return values[ ii ];
+                return values[ii];
             }
         }
 
         return NULL;
     }
+
 
     public int getOrdinal()
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/QuestionRecord.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/QuestionRecord.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/QuestionRecord.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/QuestionRecord.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 /**
  * The question section is used to carry the "question" in most queries,
  * i.e., the parameters that define what is being asked.  The section
@@ -57,13 +58,15 @@
      */
     private RecordClass recordClass;
 
-    public QuestionRecord( String domainName, RecordType recordType, RecordClass recordClass )
+
+    public QuestionRecord(String domainName, RecordType recordType, RecordClass recordClass)
     {
         this.domainName = domainName;
         this.recordType = recordType;
         this.recordClass = recordClass;
     }
 
+
     /**
      * The domain name of this query.
      * For example, www.example.com.
@@ -73,6 +76,7 @@
         return domainName;
     }
 
+
     /**
      * The type of the query.
      * For example, the type is A for address records.
@@ -82,6 +86,7 @@
         return recordType;
     }
 
+
     /**
      * The class for this query.
      * For example, the class is IN for the Internet.
@@ -90,6 +95,7 @@
     {
         return recordClass;
     }
+
 
     public String toString()
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/QuestionRecords.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/QuestionRecords.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/QuestionRecords.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/QuestionRecords.java Fri Feb 10 02:48:07 2006
@@ -17,39 +17,47 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
 
+
 public class QuestionRecords
 {
     private List questionRecords;
 
+
     public QuestionRecords()
     {
         this.questionRecords = new ArrayList();
     }
 
-    public QuestionRecords( int initialCapacity )
+
+    public QuestionRecords(int initialCapacity)
     {
         this.questionRecords = new ArrayList( initialCapacity );
     }
 
+
     public void add( QuestionRecord question )
     {
         questionRecords.add( question );
     }
 
+
     public int size()
     {
         return questionRecords.size();
     }
 
+
     public Iterator iterator()
     {
         return questionRecords.iterator();
     }
 
+
     public String toString()
     {
         StringBuffer sb = new StringBuffer();
@@ -58,7 +66,7 @@
 
         while ( it.hasNext() )
         {
-            QuestionRecord question = (QuestionRecord) it.next();
+            QuestionRecord question = ( QuestionRecord ) it.next();
             sb.append( "\n\t" + "dnsName                    " + question.getDomainName() );
             sb.append( "\n\t" + "dnsType                    " + question.getRecordType() );
             sb.append( "\n\t" + "dnsClass                   " + question.getRecordClass() );

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/RecordClass.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/RecordClass.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/RecordClass.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/RecordClass.java Fri Feb 10 02:48:07 2006
@@ -17,10 +17,12 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
 
+
 public final class RecordClass implements Comparable
 {
     /**
@@ -31,13 +33,15 @@
     public static final RecordClass CS = new RecordClass( 2, "CS", "CSNET class" );
     public static final RecordClass CH = new RecordClass( 3, "CH", "CHAOS class" );
     public static final RecordClass HS = new RecordClass( 4, "HS", "Hesiod [Dyer 87]" );
-    public static final RecordClass NONE = new RecordClass( 254, "NONE", "Special value used in dynamic update messages" );
+    public static final RecordClass NONE = new RecordClass( 254, "NONE",
+        "Special value used in dynamic update messages" );
     public static final RecordClass ANY = new RecordClass( 255, "*", "Any class" );
 
     /**
      * These two lines are all that's necessary to export a List of VALUES.
      */
-    private static final RecordClass[] values = { IN, CS, CH, HS, NONE, ANY };
+    private static final RecordClass[] values =
+        { IN, CS, CH, HS, NONE, ANY };
 
     public static final List VALUES = Collections.unmodifiableList( Arrays.asList( values ) );
 
@@ -45,56 +49,63 @@
     private final String code;
     private final int ordinal;
 
+
     /**
      * Private constructor prevents construction outside of this class.
      */
-    private RecordClass( int ordinal, String code, String name )
+    private RecordClass(int ordinal, String code, String name)
     {
         this.ordinal = ordinal;
         this.code = code;
         this.name = name;
     }
 
+
     public String toString()
     {
         return name;
     }
 
+
     public int compareTo( Object that )
     {
-        return ordinal - ( (RecordClass) that ).ordinal;
+        return ordinal - ( ( RecordClass ) that ).ordinal;
     }
 
+
     public static RecordClass getTypeByOrdinal( int type )
     {
         for ( int ii = 0; ii < values.length; ii++ )
         {
-            if ( values[ ii ].ordinal == type )
+            if ( values[ii].ordinal == type )
             {
-                return values[ ii ];
+                return values[ii];
             }
         }
 
         return IN;
     }
 
+
     public static RecordClass getTypeByName( String type )
     {
         for ( int ii = 0; ii < values.length; ii++ )
         {
-            if ( values[ ii ].code.equalsIgnoreCase( type ) )
+            if ( values[ii].code.equalsIgnoreCase( type ) )
             {
-                return values[ ii ];
+                return values[ii];
             }
         }
 
         return IN;
     }
 
+
     public int getOrdinal()
     {
         return ordinal;
     }
+
 
     public String getCode()
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/RecordType.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/RecordType.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/RecordType.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/RecordType.java Fri Feb 10 02:48:07 2006
@@ -17,10 +17,12 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
 
+
 public class RecordType implements Comparable
 {
     /**
@@ -74,7 +76,7 @@
     public static final RecordType NSEC = new RecordType( 47, "NSEC", "Next Secure Name" );
     public static final RecordType DNSKEY = new RecordType( 48, "DNSKEY", "DNSSEC Key" );
     public static final RecordType TKEY = new RecordType( 249, "TKEY",
-            "Transaction key - used to compute a shared secret or exchange a key" );
+        "Transaction key - used to compute a shared secret or exchange a key" );
     public static final RecordType TSIG = new RecordType( 250, "TSIG", "Transaction signature" );
     public static final RecordType IXFR = new RecordType( 251, "IXFR", "Incremental zone transfer" );
     public static final RecordType AXFR = new RecordType( 252, "AXFR", "Request for transfer of an entire zone" );
@@ -85,10 +87,10 @@
     /**
      * These two lines are all that's necessary to export a List of VALUES.
      */
-    private static final RecordType[] values = { A, NS, MD, MF, CNAME, SOA, MB, MG, MR, NULL, WKS, PTR, HINFO, MINFO,
-            MX, TXT, RP, AFSDB, X25, ISDN, RT, NSAP, NSAP_PTR, SIG, KEY, PX, GPOS, AAAA, LOC, NXT, EID, NIMLOC, SRV,
-            ATMA, NAPTR, KX, CERT, A6, DNAME, OPT, APL, DS, SSHFP, RRSIG, NSEC, DNSKEY, TKEY, TSIG, IXFR, AXFR, MAILB,
-            MAILA, ANY };
+    private static final RecordType[] values =
+        { A, NS, MD, MF, CNAME, SOA, MB, MG, MR, NULL, WKS, PTR, HINFO, MINFO, MX, TXT, RP, AFSDB, X25, ISDN, RT, NSAP,
+            NSAP_PTR, SIG, KEY, PX, GPOS, AAAA, LOC, NXT, EID, NIMLOC, SRV, ATMA, NAPTR, KX, CERT, A6, DNAME, OPT, APL,
+            DS, SSHFP, RRSIG, NSEC, DNSKEY, TKEY, TSIG, IXFR, AXFR, MAILB, MAILA, ANY };
 
     public static final List VALUES = Collections.unmodifiableList( Arrays.asList( values ) );
 
@@ -96,61 +98,69 @@
     private final String code;
     private final int ordinal;
 
+
     /**
      * Private constructor prevents construction outside of this class.
      */
-    private RecordType( int ordinal, String code, String name )
+    private RecordType(int ordinal, String code, String name)
     {
         this.ordinal = ordinal;
         this.code = code;
         this.name = name;
     }
 
+
     public String toString()
     {
         return name;
     }
 
+
     public int compareTo( Object that )
     {
-        return ordinal - ( (RecordType) that ).ordinal;
+        return ordinal - ( ( RecordType ) that ).ordinal;
     }
 
+
     public static RecordType getTypeByOrdinal( int type )
     {
         for ( int ii = 0; ii < values.length; ii++ )
         {
-            if ( values[ ii ].ordinal == type )
+            if ( values[ii].ordinal == type )
             {
-                return values[ ii ];
+                return values[ii];
             }
         }
 
         return A;
     }
 
+
     public static RecordType getTypeByName( String type )
     {
         for ( int ii = 0; ii < values.length; ii++ )
         {
-            if ( values[ ii ].code.equalsIgnoreCase( type ) )
+            if ( values[ii].code.equalsIgnoreCase( type ) )
             {
-                return values[ ii ];
+                return values[ii];
             }
         }
 
         return A;
     }
 
+
     public int getOrdinal()
     {
         return ordinal;
     }
 
+
     public String getCode()
     {
         return code;
     }
+
 
     public static boolean isResourceRecord( RecordType resourceType )
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecord.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecord.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecord.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecord.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 public interface ResourceRecord
 {
     /**
@@ -24,20 +25,24 @@
      */
     public String getDomainName();
 
+
     /**
      * @return Returns the recordType.
      */
     public RecordType getRecordType();
 
+
     /**
      * @return Returns the recordClass.
      */
     public RecordClass getRecordClass();
 
+
     /**
      * @return Returns the timeToLive.
      */
     public int getTimeToLive();
+
 
     /**
      * @return Returns the value for an id.

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecordImpl.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecordImpl.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecordImpl.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecordImpl.java Fri Feb 10 02:48:07 2006
@@ -17,8 +17,10 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.Map;
 
+
 /**
  * The answer, authority, and additional sections all share the same
  * format: a variable number of resource records, where the number of
@@ -83,8 +85,9 @@
      */
     private Map attributes;
 
-    public ResourceRecordImpl( String domainName, RecordType recordType, RecordClass recordClass, int timeToLive,
-            Map attributes )
+
+    public ResourceRecordImpl(String domainName, RecordType recordType, RecordClass recordClass, int timeToLive,
+        Map attributes)
     {
         this.domainName = domainName;
         this.recordType = recordType;
@@ -93,6 +96,7 @@
         this.attributes = attributes;
     }
 
+
     /**
      * @return Returns the domainName.
      */
@@ -101,6 +105,7 @@
         return domainName;
     }
 
+
     /**
      * @return Returns the recordType.
      */
@@ -109,6 +114,7 @@
         return recordType;
     }
 
+
     /**
      * @return Returns the recordClass.
      */
@@ -117,6 +123,7 @@
         return recordClass;
     }
 
+
     /**
      * @return Returns the timeToLive.
      */
@@ -125,14 +132,16 @@
         return timeToLive;
     }
 
+
     /**
      * @return Returns the value for the id.
      */
     public String get( String id )
     {
-        return (String) attributes.get( id );
+        return ( String ) attributes.get( id );
     }
 
+
     public boolean equals( Object o )
     {
         if ( this == o )
@@ -145,20 +154,22 @@
             return false;
         }
 
-        ResourceRecordImpl that = (ResourceRecordImpl) o;
+        ResourceRecordImpl that = ( ResourceRecordImpl ) o;
 
         return ( this.domainName.equals( that.domainName ) ) && ( this.recordType == that.recordType )
-                && ( this.recordClass == that.recordClass );
+            && ( this.recordClass == that.recordClass );
     }
 
+
     public int hashCode()
     {
         return domainName.hashCode() + recordType.hashCode() + recordClass.hashCode();
     }
 
+
     public String toString()
     {
         return getClass().getName() + " [ " + domainName + " ( " + recordType + " " + recordClass + " " + timeToLive
-                + " " + attributes.size() + " ) ]";
+            + " " + attributes.size() + " ) ]";
     }
 }

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecordModifier.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecordModifier.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecordModifier.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecordModifier.java Fri Feb 10 02:48:07 2006
@@ -16,6 +16,7 @@
  */
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.HashMap;
 import java.util.Map;
 
@@ -24,6 +25,7 @@
 import org.apache.directory.server.dns.messages.ResourceRecord;
 import org.apache.directory.server.dns.messages.ResourceRecordImpl;
 
+
 public class ResourceRecordModifier
 {
     private String dnsName;
@@ -32,11 +34,13 @@
     private int dnsTtl;
     private Map attributes = new HashMap();
 
+
     public ResourceRecord getEntry()
     {
         return new ResourceRecordImpl( dnsName, dnsType, dnsClass, dnsTtl, attributes );
     }
 
+
     /**
      * @param dnsName The dnsName to set.
      */
@@ -45,6 +49,7 @@
         this.dnsName = dnsName;
     }
 
+
     /**
      * @param dnsType The dnsType to set.
      */
@@ -53,6 +58,7 @@
         this.dnsType = dnsType;
     }
 
+
     /**
      * @param dnsClass The dnsClass to set.
      */
@@ -61,6 +67,7 @@
         this.dnsClass = dnsClass;
     }
 
+
     /**
      * @param dnsTtl The dnsTtl to set.
      */
@@ -68,6 +75,7 @@
     {
         this.dnsTtl = dnsTtl;
     }
+
 
     /**
      * @param id The id to set

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecords.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecords.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecords.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResourceRecords.java Fri Feb 10 02:48:07 2006
@@ -17,45 +17,54 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Iterator;
 import java.util.List;
 
+
 public class ResourceRecords
 {
     private List resourceRecords;
 
+
     public ResourceRecords()
     {
         this.resourceRecords = new ArrayList();
     }
 
-    public ResourceRecords( int initialCapacity )
+
+    public ResourceRecords(int initialCapacity)
     {
         this.resourceRecords = new ArrayList( initialCapacity );
     }
 
+
     public void add( ResourceRecord record )
     {
         resourceRecords.add( record );
     }
 
+
     public void addAll( Collection records )
     {
         resourceRecords.addAll( records );
     }
 
+
     public int size()
     {
         return resourceRecords.size();
     }
 
+
     public Iterator iterator()
     {
         return resourceRecords.iterator();
     }
 
+
     public String toString()
     {
         StringBuffer sb = new StringBuffer();
@@ -64,7 +73,7 @@
 
         while ( it.hasNext() )
         {
-            ResourceRecord record = (ResourceRecord) it.next();
+            ResourceRecord record = ( ResourceRecord ) it.next();
             sb.append( "\n\t" + "dnsName                    " + record.getDomainName() );
             sb.append( "\n\t" + "dnsType                    " + record.getRecordType() );
             sb.append( "\n\t" + "dnsClass                   " + record.getRecordClass() );

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResponseCode.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResponseCode.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResponseCode.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ResponseCode.java Fri Feb 10 02:48:07 2006
@@ -17,10 +17,12 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
 
+
 public final class ResponseCode implements Comparable
 {
     /**
@@ -29,63 +31,69 @@
      */
     public static final ResponseCode NO_ERROR = new ResponseCode( 0, "No error condition." );
     public static final ResponseCode FORMAT_ERROR = new ResponseCode( 1,
-            "The name server was unable to interpret the query." );
+        "The name server was unable to interpret the query." );
     public static final ResponseCode SERVER_FAILURE = new ResponseCode( 2,
-            "The name server was unable to process this query due to a problem with the name server." );
+        "The name server was unable to process this query due to a problem with the name server." );
     public static final ResponseCode NAME_ERROR = new ResponseCode( 3,
-            "The domain name referenced in the query does not exist." );
+        "The domain name referenced in the query does not exist." );
     public static final ResponseCode NOT_IMPLEMENTED = new ResponseCode( 4,
-            "The name server does not support the requested kind of query." );
+        "The name server does not support the requested kind of query." );
     public static final ResponseCode REFUSED = new ResponseCode( 5,
-            "The name server refuses to perform the specified operation for policy reasons." );
+        "The name server refuses to perform the specified operation for policy reasons." );
 
     /**
      * These two lines are all that's necessary to export a List of VALUES.
      */
-    private static final ResponseCode[] values = { NO_ERROR, FORMAT_ERROR, SERVER_FAILURE, NAME_ERROR, NOT_IMPLEMENTED,
-            REFUSED };
+    private static final ResponseCode[] values =
+        { NO_ERROR, FORMAT_ERROR, SERVER_FAILURE, NAME_ERROR, NOT_IMPLEMENTED, REFUSED };
 
     public static final List VALUES = Collections.unmodifiableList( Arrays.asList( values ) );
 
     private final String name;
     private final int ordinal;
 
+
     /**
      * Private constructor prevents construction outside of this class.
      */
-    private ResponseCode( int ordinal, String name )
+    private ResponseCode(int ordinal, String name)
     {
         this.ordinal = ordinal;
         this.name = name;
     }
 
+
     public String getMessage()
     {
         return name;
     }
 
+
     public String toString()
     {
         return name;
     }
 
+
     public int compareTo( Object that )
     {
-        return ordinal - ( (ResponseCode) that ).ordinal;
+        return ordinal - ( ( ResponseCode ) that ).ordinal;
     }
 
+
     public static ResponseCode getTypeByOrdinal( int type )
     {
         for ( int ii = 0; ii < values.length; ii++ )
         {
-            if ( values[ ii ].ordinal == type )
+            if ( values[ii].ordinal == type )
             {
-                return values[ ii ];
+                return values[ii];
             }
         }
 
         return NO_ERROR;
     }
+
 
     public int getOrdinal()
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ServiceType.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ServiceType.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ServiceType.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/messages/ServiceType.java Fri Feb 10 02:48:07 2006
@@ -17,10 +17,12 @@
 
 package org.apache.directory.server.dns.messages;
 
+
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
 
+
 public final class ServiceType implements Comparable
 {
     /**
@@ -111,51 +113,56 @@
     /**
      * These two lines are all that's necessary to export a List of VALUES.
      */
-    private static final ServiceType[] values = { NULL, RJE, ECHO, DISCARD, USERS, DAYTIME, QUOTE, CHARGEN, FTP_DATA,
-            FTP, TELNET, SMTP, NSW_FE, MSG_ICP, MSG_AUTH, DSP, TIME, RLP, GRAPHICS, NAMESERVER, NICKNAME, MPM_FLAGS,
-            MPM, MPM_SND, NI_FTP, LOGIN, LA_MAINT, DOMAIN, ISI_GL, NI_MAIL, VIA_FTP, TACACS_DS, BOOTPS, BOOTPC, TFTP,
-            NETRJS_1, NETRJS_2, NETRJS_3, NETRJS_4, FINGER, HOSTS2_NS, SU_MIT_TG, MIT_DOV, DCP, SUPDUP, SWIFT_RVF,
-            TACNEWS, METAGRAM, HOSTNAME, ISO_TSAP, X400, X400_SND, CSNET_NS, RTELNET, POP_2, SUNRPC, AUTH, SFTP,
-            UUCP_PATH, NNTP, ERPC, NTP, LOCUS_MAP, LOCUS_CON, PWDGEN, CISCO_FNA, CISCO_TNA, CISCO_SYS, STATSRV,
-            INGRES_NET, LOC_SRV, PROFILE, NETBIOS_NS, NETBIOS_DGM, NETBIOS_SSN, EMFIS_DATA, EMFIS_CNTL, BL_IDM,
-            SUR_MEAS, LINK };
+    private static final ServiceType[] values =
+        { NULL, RJE, ECHO, DISCARD, USERS, DAYTIME, QUOTE, CHARGEN, FTP_DATA, FTP, TELNET, SMTP, NSW_FE, MSG_ICP,
+            MSG_AUTH, DSP, TIME, RLP, GRAPHICS, NAMESERVER, NICKNAME, MPM_FLAGS, MPM, MPM_SND, NI_FTP, LOGIN, LA_MAINT,
+            DOMAIN, ISI_GL, NI_MAIL, VIA_FTP, TACACS_DS, BOOTPS, BOOTPC, TFTP, NETRJS_1, NETRJS_2, NETRJS_3, NETRJS_4,
+            FINGER, HOSTS2_NS, SU_MIT_TG, MIT_DOV, DCP, SUPDUP, SWIFT_RVF, TACNEWS, METAGRAM, HOSTNAME, ISO_TSAP, X400,
+            X400_SND, CSNET_NS, RTELNET, POP_2, SUNRPC, AUTH, SFTP, UUCP_PATH, NNTP, ERPC, NTP, LOCUS_MAP, LOCUS_CON,
+            PWDGEN, CISCO_FNA, CISCO_TNA, CISCO_SYS, STATSRV, INGRES_NET, LOC_SRV, PROFILE, NETBIOS_NS, NETBIOS_DGM,
+            NETBIOS_SSN, EMFIS_DATA, EMFIS_CNTL, BL_IDM, SUR_MEAS, LINK };
 
     public static final List VALUES = Collections.unmodifiableList( Arrays.asList( values ) );
 
     private final String name;
     private final int ordinal;
 
+
     /**
      * Private constructor prevents construction outside of this class.
      */
-    private ServiceType( int ordinal, String name )
+    private ServiceType(int ordinal, String name)
     {
         this.ordinal = ordinal;
         this.name = name;
     }
 
+
     public String toString()
     {
         return name;
     }
 
+
     public int compareTo( Object that )
     {
-        return ordinal - ( (ServiceType) that ).ordinal;
+        return ordinal - ( ( ServiceType ) that ).ordinal;
     }
 
+
     public static ServiceType getTypeByOrdinal( int type )
     {
         for ( int ii = 0; ii < values.length; ii++ )
         {
-            if ( values[ ii ].ordinal == type )
+            if ( values[ii].ordinal == type )
             {
-                return values[ ii ];
+                return values[ii];
             }
         }
 
         return NULL;
     }
+
 
     public int getOrdinal()
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsDecoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsDecoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsDecoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsDecoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.protocol;
 
+
 import java.io.IOException;
 import java.util.Collections;
 import java.util.HashMap;
@@ -41,6 +42,7 @@
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
+
 public class DnsDecoder implements ProtocolDecoder
 {
     /** the log for this class */
@@ -60,11 +62,13 @@
         DEFAULT_DECODERS = Collections.unmodifiableMap( map );
     }
 
+
     public void decode( IoSession session, ByteBuffer in, ProtocolDecoderOutput out )
     {
         out.write( decode( in ) );
     }
 
+
     DnsMessage decode( ByteBuffer in )
     {
         DnsMessageModifier modifier = new DnsMessageModifier();
@@ -95,6 +99,7 @@
         return modifier.getDnsMessage();
     }
 
+
     private ResourceRecords decodeRecords( short recordCount, ByteBuffer byteBuffer )
     {
         ResourceRecords records = new ResourceRecords( recordCount );
@@ -109,7 +114,7 @@
             int timeToLive = byteBuffer.getInt();
             short dataLength = byteBuffer.getShort();
 
-            byte[] data = new byte[ dataLength ];
+            byte[] data = new byte[dataLength];
             byteBuffer.get( data );
 
             try
@@ -126,9 +131,10 @@
         return records;
     }
 
+
     private Map decode( RecordType type, byte[] resourceData ) throws IOException
     {
-        Decoder decoder = (Decoder) DEFAULT_DECODERS.get( type );
+        Decoder decoder = ( Decoder ) DEFAULT_DECODERS.get( type );
 
         if ( decoder == null )
         {
@@ -138,6 +144,7 @@
         return decoder.decode( resourceData );
     }
 
+
     private QuestionRecords decodeQuestions( short questionCount, ByteBuffer byteBuffer )
     {
         QuestionRecords questions = new QuestionRecords( questionCount );
@@ -155,6 +162,7 @@
         return questions;
     }
 
+
     private String decodeDomainName( ByteBuffer byteBuffer )
     {
         StringBuffer domainName = new StringBuffer();
@@ -163,11 +171,12 @@
         return domainName.toString();
     }
 
+
     private void recurseDomainName( StringBuffer domainName, ByteBuffer byteBuffer )
     {
         byte currentByte = byteBuffer.get();
 
-        boolean isCompressed = ( ( currentByte & (byte) 0xc0 ) == (byte) 0xc0 );
+        boolean isCompressed = ( ( currentByte & ( byte ) 0xc0 ) == ( byte ) 0xc0 );
         boolean isLabelLength = ( ( currentByte != 0 ) && !isCompressed );
 
         if ( isCompressed )
@@ -191,11 +200,12 @@
         }
     }
 
+
     private void getLabel( int labelLength, ByteBuffer byteBuffer, StringBuffer domainName )
     {
         for ( int jj = 0; jj < labelLength; jj++ )
         {
-            char character = (char) byteBuffer.get();
+            char character = ( char ) byteBuffer.get();
             domainName.append( character );
         }
 
@@ -205,40 +215,48 @@
         }
     }
 
+
     private MessageType decodeMessageType( byte header )
     {
         return MessageType.getTypeByOrdinal( ( header & 0x80 ) >>> 7 );
     }
 
+
     private OpCode decodeOpCode( byte header )
     {
         return OpCode.getTypeByOrdinal( ( header & 0x78 ) >>> 3 );
     }
 
+
     private boolean decodeAuthoritativeAnswer( byte header )
     {
         return ( ( header & 0x04 ) >>> 2 ) == 1;
     }
 
+
     private boolean decodeTruncated( byte header )
     {
         return ( ( header & 0x02 ) >>> 1 ) == 1;
     }
 
+
     private boolean decodeRecursionDesired( byte header )
     {
         return ( ( header & 0x01 ) ) == 1;
     }
 
+
     private boolean decodeRecursionAvailable( byte header )
     {
         return ( ( header & 0x80 ) >>> 7 ) == 1;
     }
 
+
     private ResponseCode decodeResponseCode( byte header )
     {
         return ResponseCode.getTypeByOrdinal( header & 0x0F );
     }
+
 
     public void dispose( IoSession arg0 ) throws Exception
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsEncoder.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsEncoder.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsEncoder.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsEncoder.java Fri Feb 10 02:48:07 2006
@@ -17,6 +17,7 @@
 
 package org.apache.directory.server.dns.protocol;
 
+
 import java.io.IOException;
 import java.util.Collections;
 import java.util.HashMap;
@@ -49,6 +50,7 @@
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
+
 public class DnsEncoder implements ProtocolEncoder
 {
     /** the log for this class */
@@ -75,21 +77,23 @@
         DEFAULT_ENCODERS = Collections.unmodifiableMap( map );
     }
 
+
     public void encode( IoSession session, Object message, ProtocolEncoderOutput out )
     {
         ByteBuffer buf = ByteBuffer.allocate( 1024 );
-        encode( buf, (DnsMessage) message );
+        encode( buf, ( DnsMessage ) message );
 
         buf.flip();
 
         out.write( buf );
     }
 
+
     public void encode( ByteBuffer byteBuffer, DnsMessage message )
     {
         byteBuffer.putShort( message.getTransactionId() );
 
-        byte header = (byte) 0x00;
+        byte header = ( byte ) 0x00;
         header = encodeMessageType( message.getMessageType(), header );
         header = encodeOpCode( message.getOpCode(), header );
         header = encodeAuthoritativeAnswer( message.isAuthoritativeAnswer(), header );
@@ -97,15 +101,15 @@
         header = encodeRecursionDesired( message.isRecursionDesired(), header );
         byteBuffer.put( header );
 
-        header = (byte) 0x00;
+        header = ( byte ) 0x00;
         header = encodeRecursionAvailable( message.isRecursionAvailable(), header );
         header = encodeResponseCode( message.getResponseCode(), header );
         byteBuffer.put( header );
 
-        byteBuffer.putShort( (short) message.getQuestionRecords().size() );
-        byteBuffer.putShort( (short) message.getAnswerRecords().size() );
-        byteBuffer.putShort( (short) message.getAuthorityRecords().size() );
-        byteBuffer.putShort( (short) message.getAdditionalRecords().size() );
+        byteBuffer.putShort( ( short ) message.getQuestionRecords().size() );
+        byteBuffer.putShort( ( short ) message.getAnswerRecords().size() );
+        byteBuffer.putShort( ( short ) message.getAuthorityRecords().size() );
+        byteBuffer.putShort( ( short ) message.getAdditionalRecords().size() );
 
         encodeRecords( message.getQuestionRecords(), byteBuffer );
         encodeRecords( message.getAnswerRecords(), byteBuffer );
@@ -113,6 +117,7 @@
         encodeRecords( message.getAdditionalRecords(), byteBuffer );
     }
 
+
     private void encodeRecords( QuestionRecords questions, ByteBuffer byteBuffer )
     {
         QuestionRecordEncoder encoder = new QuestionRecordEncoder();
@@ -121,18 +126,19 @@
 
         while ( it.hasNext() )
         {
-            QuestionRecord question = (QuestionRecord) it.next();
+            QuestionRecord question = ( QuestionRecord ) it.next();
             encoder.encode( byteBuffer, question );
         }
     }
 
+
     private void encodeRecords( ResourceRecords records, ByteBuffer byteBuffer )
     {
         Iterator it = records.iterator();
 
         while ( it.hasNext() )
         {
-            ResourceRecord record = (ResourceRecord) it.next();
+            ResourceRecord record = ( ResourceRecord ) it.next();
 
             try
             {
@@ -145,11 +151,12 @@
         }
     }
 
+
     private void encode( ByteBuffer out, ResourceRecord record ) throws IOException
     {
         RecordType type = record.getRecordType();
 
-        RecordEncoder encoder = (RecordEncoder) DEFAULT_ENCODERS.get( type );
+        RecordEncoder encoder = ( RecordEncoder ) DEFAULT_ENCODERS.get( type );
 
         if ( encoder == null )
         {
@@ -159,59 +166,67 @@
         encoder.encode( out, record );
     }
 
+
     private byte encodeMessageType( MessageType messageType, byte header )
     {
-        byte oneBit = (byte) ( messageType.getOrdinal() & 0x01 );
-        return (byte) ( ( oneBit << 7 ) | header );
+        byte oneBit = ( byte ) ( messageType.getOrdinal() & 0x01 );
+        return ( byte ) ( ( oneBit << 7 ) | header );
     }
 
+
     private byte encodeOpCode( OpCode opCode, byte header )
     {
-        byte fourBits = (byte) ( opCode.getOrdinal() & 0x0F );
-        return (byte) ( ( fourBits << 3 ) | header );
+        byte fourBits = ( byte ) ( opCode.getOrdinal() & 0x0F );
+        return ( byte ) ( ( fourBits << 3 ) | header );
     }
 
+
     private byte encodeAuthoritativeAnswer( boolean authoritative, byte header )
     {
         if ( authoritative )
         {
-            header = (byte) ( ( (byte) 0x01 << 2 ) | header );
+            header = ( byte ) ( ( ( byte ) 0x01 << 2 ) | header );
         }
         return header;
     }
 
+
     private byte encodeTruncated( boolean truncated, byte header )
     {
         if ( truncated )
         {
-            header = (byte) ( ( (byte) 0x01 << 1 ) | header );
+            header = ( byte ) ( ( ( byte ) 0x01 << 1 ) | header );
         }
         return header;
     }
 
+
     private byte encodeRecursionDesired( boolean recursionDesired, byte header )
     {
         if ( recursionDesired )
         {
-            header = (byte) ( ( (byte) 0x01 ) | header );
+            header = ( byte ) ( ( ( byte ) 0x01 ) | header );
         }
         return header;
     }
 
+
     private byte encodeRecursionAvailable( boolean recursionAvailable, byte header )
     {
         if ( recursionAvailable )
         {
-            header = (byte) ( ( (byte) 0x01 << 7 ) | header );
+            header = ( byte ) ( ( ( byte ) 0x01 << 7 ) | header );
         }
         return header;
     }
 
+
     private byte encodeResponseCode( ResponseCode responseCode, byte header )
     {
-        byte fourBits = (byte) ( responseCode.getOrdinal() & 0x0F );
-        return (byte) ( fourBits | header );
+        byte fourBits = ( byte ) ( responseCode.getOrdinal() & 0x0F );
+        return ( byte ) ( fourBits | header );
     }
+
 
     public void dispose( IoSession arg0 ) throws Exception
     {

Modified: directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsProtocolCodecFactory.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsProtocolCodecFactory.java?rev=376623&r1=376622&r2=376623&view=diff
==============================================================================
--- directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsProtocolCodecFactory.java (original)
+++ directory/sandbox/akarasulu/rc1/apacheds/protocol-dns/src/main/java/org/apache/directory/server/dns/protocol/DnsProtocolCodecFactory.java Fri Feb 10 02:48:07 2006
@@ -17,29 +17,34 @@
 
 package org.apache.directory.server.dns.protocol;
 
+
 import org.apache.mina.filter.codec.ProtocolCodecFactory;
 import org.apache.mina.filter.codec.ProtocolDecoder;
 import org.apache.mina.filter.codec.ProtocolEncoder;
 
+
 public class DnsProtocolCodecFactory implements ProtocolCodecFactory
 {
-    private static final DnsProtocolCodecFactory INSTANCE = 
-        new DnsProtocolCodecFactory();
-    
+    private static final DnsProtocolCodecFactory INSTANCE = new DnsProtocolCodecFactory();
+
+
     public static DnsProtocolCodecFactory getInstance()
     {
         return INSTANCE;
     }
 
+
     private DnsProtocolCodecFactory()
     {
     }
 
+
     public ProtocolEncoder getEncoder()
     {
         // Create a new encoder.
         return new DnsEncoder();
     }
+
 
     public ProtocolDecoder getDecoder()
     {



Mime
View raw message