directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r664290 [10/13] - in /directory/shared/branches/bigbang: ./ asn1/src/main/java/org/apache/directory/shared/asn1/ asn1/src/main/java/org/apache/directory/shared/asn1/ber/ asn1/src/main/java/org/apache/directory/shared/asn1/ber/grammar/ asn1/...
Date Sat, 07 Jun 2008 06:28:15 GMT
Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/OtherMailboxSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/OtherMailboxSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/OtherMailboxSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/OtherMailboxSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -67,7 +67,7 @@
      */
     public boolean isValidSyntax( Object value )
     {
-        String strValue;
+        String strValue = null;
 
         if ( value == null )
         {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PostalAddressSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PostalAddressSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PostalAddressSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PostalAddressSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -66,7 +66,7 @@
      */
     public boolean isValidSyntax( Object value )
     {
-        String strValue;
+        String strValue = null;
 
         if ( value == null )
         {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PresentationAddressSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PresentationAddressSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PresentationAddressSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PresentationAddressSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -56,6 +56,9 @@
     
     /**
      * @see org.apache.directory.shared.ldap.schema.syntax.SyntaxChecker#isValidSyntax(Object)
+     * 
+     * @param value the value of some attribute with the syntax
+     * @return true if the value is in the valid syntax, false otherwise
      */
     public boolean isValidSyntax( Object value )
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PrintableStringSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PrintableStringSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PrintableStringSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/PrintableStringSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -87,7 +87,7 @@
      */
     public boolean isValidSyntax( Object value )
     {
-        String strValue;
+        String strValue = null;
 
         if ( value == null )
         {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/ProtocolInformationSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/ProtocolInformationSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/ProtocolInformationSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/ProtocolInformationSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -55,6 +55,9 @@
     
     /**
      * @see org.apache.directory.shared.ldap.schema.syntax.SyntaxChecker#isValidSyntax(Object)
+     * 
+     * @param value the value of some attribute with the syntax
+     * @return true if the value is in the valid syntax, false otherwise
      */
     public boolean isValidSyntax( Object value )
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/RegexSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/RegexSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/RegexSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/RegexSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -80,6 +80,9 @@
     
     /**
      * @see org.apache.directory.shared.ldap.schema.syntax.SyntaxChecker#isValidSyntax(java.lang.Object)
+     * 
+     * @param value the value of some attribute with the syntax
+     * @return true if the value is in the valid syntax, false otherwise
      */
     public boolean isValidSyntax( Object value )
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SubstringAssertionSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SubstringAssertionSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SubstringAssertionSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SubstringAssertionSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -57,6 +57,9 @@
     
     /**
      * @see org.apache.directory.shared.ldap.schema.syntax.SyntaxChecker#isValidSyntax(Object)
+     * 
+     * @param value the value of some attribute with the syntax
+     * @return true if the value is in the valid syntax, false otherwise
      */
     public boolean isValidSyntax( Object value )
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SubtreeSpecificationSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SubtreeSpecificationSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SubtreeSpecificationSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SubtreeSpecificationSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -62,10 +62,13 @@
     
     /**
      * @see org.apache.directory.shared.ldap.schema.syntax.SyntaxChecker#isValidSyntax(Object)
+     * 
+     * @param value the value of some attribute with the syntax
+     * @return true if the value is in the valid syntax, false otherwise
      */
     public boolean isValidSyntax( Object value )
     {
-        String strValue;
+        String strValue = null;
 
         if ( value == null )
         {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierAndConsumerSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierAndConsumerSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierAndConsumerSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierAndConsumerSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -54,6 +54,9 @@
     
     /**
      * @see org.apache.directory.shared.ldap.schema.syntax.SyntaxChecker#isValidSyntax(Object)
+     * 
+     * @param value the value of some attribute with the syntax
+     * @return true if the value is in the valid syntax, false otherwise
      */
     public boolean isValidSyntax( Object value )
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierInformationSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierInformationSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierInformationSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierInformationSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -54,6 +54,9 @@
     
     /**
      * @see org.apache.directory.shared.ldap.schema.syntax.SyntaxChecker#isValidSyntax(Object)
+     * 
+     * @param value the value of some attribute with the syntax
+     * @return true if the value is in the valid syntax, false otherwise
      */
     public boolean isValidSyntax( Object value )
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierOrConsumerSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierOrConsumerSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierOrConsumerSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupplierOrConsumerSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -54,6 +54,9 @@
     
     /**
      * @see org.apache.directory.shared.ldap.schema.syntax.SyntaxChecker#isValidSyntax(Object)
+     * 
+     * @param value the value of some attribute with the syntax
+     * @return true if the value is in the valid syntax, false otherwise
      */
     public boolean isValidSyntax( Object value )
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupportedAlgorithmSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupportedAlgorithmSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupportedAlgorithmSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SupportedAlgorithmSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -56,6 +56,9 @@
     
     /**
      * @see org.apache.directory.shared.ldap.schema.syntax.SyntaxChecker#isValidSyntax(Object)
+     * 
+     * @param value the value of some attribute with the syntax
+     * @return true if the value is in the valid syntax, false otherwise
      */
     public boolean isValidSyntax( Object value )
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -29,6 +29,7 @@
  * enforce a syntax within the Eve server.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public interface SyntaxChecker
 {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SyntaxCheckerDescription.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SyntaxCheckerDescription.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SyntaxCheckerDescription.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/SyntaxCheckerDescription.java Fri Jun  6 23:28:06 2008
@@ -25,6 +25,7 @@
  * An ApacheDS specific schema description.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class SyntaxCheckerDescription extends AbstractAdsSchemaDescription
 {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TelephoneNumberSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TelephoneNumberSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TelephoneNumberSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TelephoneNumberSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -54,7 +54,7 @@
     private List<Pattern> compiledREs;
     
     /** The default pattern used to check a TelephoneNumber */
-    private final static String DEFAULT_REGEXP = "^ *[+]? *((\\([0-9- ]+\\))|[0-9- ]+)+$";
+    private static final String DEFAULT_REGEXP = "^ *[+]? *((\\([0-9- ]+\\))|[0-9- ]+)+$";
     
     /** The compiled default pattern */
     private Pattern defaultPattern =  Pattern.compile( DEFAULT_REGEXP );
@@ -73,7 +73,7 @@
     /**
      * Creates a new instance of TelephoneNumberSyntaxChecker.
      * 
-     * @param The OID to associate with this SyntaxChecker
+     * @param oid The OID to associate with this SyntaxChecker
      */
     protected TelephoneNumberSyntaxChecker( String oid )
     {
@@ -109,9 +109,12 @@
             return;
         }
     }
-    
+
+
     /**
+     * Set the defaut regular expression for the Telephone number
      * 
+     * @param regexp the default regular expression.
      */
     public void setDefaultRegexp( String regexp )
     {
@@ -134,7 +137,7 @@
      */
     public boolean isValidSyntax( Object value )
     {
-        String strValue;
+        String strValue = null;
 
         if ( value == null )
         {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TeletexTerminalIdentifierSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TeletexTerminalIdentifierSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TeletexTerminalIdentifierSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TeletexTerminalIdentifierSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -71,7 +71,7 @@
      */
     public boolean isValidSyntax( Object value )
     {
-        String strValue;
+        String strValue = null;
 
         if ( value == null )
         {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TelexNumberSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TelexNumberSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TelexNumberSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/TelexNumberSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -68,7 +68,7 @@
      */
     public boolean isValidSyntax( Object value )
     {
-        String strValue;
+        String strValue = null;
 
         if ( value == null )
         {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/UtcTimeSyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/UtcTimeSyntaxChecker.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/UtcTimeSyntaxChecker.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/UtcTimeSyntaxChecker.java Fri Jun  6 23:28:06 2008
@@ -22,8 +22,8 @@
 
 import java.util.regex.Pattern;
 
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.ldap.constants.SchemaConstants;
+import org.apache.directory.shared.ldap.util.StringTools;
 
 
 /**
@@ -104,7 +104,7 @@
      */
     public boolean isValidSyntax( Object value )
     {
-        String strValue;
+        String strValue = null;
 
         if ( value == null )
         {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/AbstractSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/AbstractSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/AbstractSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/AbstractSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -19,28 +19,42 @@
  */
 package org.apache.directory.shared.ldap.schema.syntax.parser;
 
+
 import java.io.StringReader;
 import java.text.ParseException;
 
+import org.apache.directory.shared.ldap.schema.parser.ParserMonitor;
+import org.apache.directory.shared.ldap.schema.parser.ParserMonitorAdapter;
 import org.apache.directory.shared.ldap.schema.syntax.AbstractSchemaDescription;
 
+
+/**
+ * 
+ * TODO AbstractSchemaParser.
+ *
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
+ */
 public abstract class AbstractSchemaParser
 {
 
+    /** the monitor to use for this parser */
+    protected ParserMonitor monitor = new ParserMonitorAdapter();
 
     /** the antlr generated parser being wrapped */
     protected ReusableAntlrSchemaParser parser;
 
     /** the antlr generated lexer being wrapped */
     protected ReusableAntlrSchemaLexer lexer;
-    
-    
-    protected AbstractSchemaParser() 
+
+
+    protected AbstractSchemaParser()
     {
         lexer = new ReusableAntlrSchemaLexer( new StringReader( "" ) );
         parser = new ReusableAntlrSchemaParser( lexer );
     }
-    
+
+
     /**
      * Initializes the plumbing by creating a pipe and coupling the parser/lexer
      * pair with it. param spec the specification to be parsed
@@ -51,7 +65,45 @@
         lexer.prepareNextInput( in );
         parser.resetState();
     }
-    
+
+
+    /**
+     * Sets the parser monitor.
+     * 
+     * @param monitor the new parser monitor
+     */
+    public void setParserMonitor( ParserMonitor monitor )
+    {
+        this.monitor = monitor;
+        parser.setParserMonitor( monitor );
+    }
+
+
+    /**
+     * Sets the quirks mode. 
+     * 
+     * If enabled the parser accepts non-numeric OIDs and some 
+     * special characters in descriptions.
+     * 
+     * @param enabled the new quirks mode
+     */
+    public void setQuirksMode( boolean enabled )
+    {
+        parser.setQuirksMode( enabled );
+    }
+
+
+    /**
+     * Checks if quirks mode is enabled.
+     * 
+     * @return true, if is quirks mode is enabled
+     */
+    public boolean isQuirksMode()
+    {
+        return parser.isQuirksMode();
+    }
+
+
     public abstract AbstractSchemaDescription parse( String schemaDescription ) throws ParseException;
-    
+
 }

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/AttributeTypeDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/AttributeTypeDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/AttributeTypeDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/AttributeTypeDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -27,12 +27,14 @@
 
 import antlr.RecognitionException;
 import antlr.TokenStreamException;
+import antlr.TokenStreamRecognitionException;
 
 
 /**
  * A parser for RFC 4512 attribute type descriptions.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class AttributeTypeDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +44,6 @@
      */
     public AttributeTypeDescriptionSchemaParser()
     {
-        super();
     }
     
 
@@ -102,6 +103,12 @@
             msg += "\nAntlr column: " + re.getColumn();
             throw new ParseException( msg, re.getColumn() );
         }
+        catch ( TokenStreamRecognitionException tsre )
+        {
+            String msg = "Parser failure on attribute type description:\n\t" + attributeTypeDescription;
+            msg += "\nAntlr message: " + tsre.getMessage();
+            throw new ParseException( msg, 0 );
+        }
         catch ( TokenStreamException tse )
         {
             String msg = "Parser failure on attribute type description:\n\t" + attributeTypeDescription;

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ComparatorDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ComparatorDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ComparatorDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ComparatorDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -33,6 +33,7 @@
  * A parser for ApacheDS comparator descriptions.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class ComparatorDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +43,6 @@
      */
     public ComparatorDescriptionSchemaParser()
     {
-        super();
     }
 
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/DITContentRuleDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/DITContentRuleDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/DITContentRuleDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/DITContentRuleDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -33,6 +33,7 @@
  * A parser for RFC 4512 DIT content rule descriptons
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class DITContentRuleDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +43,6 @@
      */
     public DITContentRuleDescriptionSchemaParser()
     {
-        super();
     }
 
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/DITStructureRuleDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/DITStructureRuleDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/DITStructureRuleDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/DITStructureRuleDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -33,6 +33,7 @@
  * A parser for RFC 4512 DIT structure rule descriptons
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class DITStructureRuleDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +43,6 @@
      */
     public DITStructureRuleDescriptionSchemaParser()
     {
-        super();
     }
 
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/LdapSyntaxDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/LdapSyntaxDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/LdapSyntaxDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/LdapSyntaxDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -33,6 +33,7 @@
  * A parser for RFC 4512 LDAP syntx descriptions.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class LdapSyntaxDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +43,6 @@
      */
     public LdapSyntaxDescriptionSchemaParser()
     {
-        super();
     }
 
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/MatchingRuleDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/MatchingRuleDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/MatchingRuleDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/MatchingRuleDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -33,6 +33,7 @@
  * A parser for RFC 4512 matching rule descriptions.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class MatchingRuleDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +43,6 @@
      */
     public MatchingRuleDescriptionSchemaParser()
     {
-        super();
     }
 
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/MatchingRuleUseDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/MatchingRuleUseDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/MatchingRuleUseDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/MatchingRuleUseDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -33,6 +33,7 @@
  * A parser for RFC 4512 matching rule use descriptions.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class MatchingRuleUseDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +43,6 @@
      */
     public MatchingRuleUseDescriptionSchemaParser()
     {
-        super();
     }
 
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/NameFormDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/NameFormDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/NameFormDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/NameFormDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -33,6 +33,7 @@
  * A parser for RFC 4512 name form descriptons
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class NameFormDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +43,6 @@
      */
     public NameFormDescriptionSchemaParser()
     {
-        super();
     }
 
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/NormalizerDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/NormalizerDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/NormalizerDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/NormalizerDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -33,6 +33,7 @@
  * A parser for ApacheDS normalizer descriptions.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class NormalizerDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +43,6 @@
      */
     public NormalizerDescriptionSchemaParser()
     {
-        super();
     }
 
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ObjectClassDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ObjectClassDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ObjectClassDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ObjectClassDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -33,6 +33,7 @@
  * A parser for RFC 4512 object class descriptons
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class ObjectClassDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +43,6 @@
      */
     public ObjectClassDescriptionSchemaParser()
     {
-        super();
     }
 
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ReusableAntlrSchemaLexer.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ReusableAntlrSchemaLexer.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ReusableAntlrSchemaLexer.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ReusableAntlrSchemaLexer.java Fri Jun  6 23:28:06 2008
@@ -35,8 +35,9 @@
  * a Antlr Interest Group mail</a> .
  * 
  * @see <a href="http://www.faqs.org/rfcs/rfc3672.html">RFC 3672</a>
+ * @version $Rev$, $Date$
  */
-class ReusableAntlrSchemaLexer extends AntlrSchemaLexer
+public class ReusableAntlrSchemaLexer extends AntlrSchemaLexer
 {
     private boolean savedCaseSensitive;
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ReusableAntlrSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ReusableAntlrSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ReusableAntlrSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/ReusableAntlrSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -32,8 +32,9 @@
  * a Antlr Interest Group mail</a> .
  * 
  * @see <a href="http://www.faqs.org/rfcs/rfc3672.html">RFC 3672</a>
+ * @version $Rev$, $Date$
  */
-class ReusableAntlrSchemaParser extends AntlrSchemaParser
+public class ReusableAntlrSchemaParser extends AntlrSchemaParser
 {
     /**
      * Creates a ReusableAntlrSchemaParser instance.

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/SyntaxCheckerDescriptionSchemaParser.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/SyntaxCheckerDescriptionSchemaParser.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/SyntaxCheckerDescriptionSchemaParser.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/schema/syntax/parser/SyntaxCheckerDescriptionSchemaParser.java Fri Jun  6 23:28:06 2008
@@ -33,6 +33,7 @@
  * A parser for ApacheDS syntax checker descriptions.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev$, $Date$
  */
 public class SyntaxCheckerDescriptionSchemaParser extends AbstractSchemaParser
 {
@@ -42,7 +43,6 @@
      */
     public SyntaxCheckerDescriptionSchemaParser()
     {
-        super();
     }
 
 

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/subtree/BaseSubtreeSpecification.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/subtree/BaseSubtreeSpecification.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/subtree/BaseSubtreeSpecification.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/subtree/BaseSubtreeSpecification.java Fri Jun  6 23:28:06 2008
@@ -333,7 +333,7 @@
                 // Must use a tempBuffer here because the 
                 // exception could occur after some characters
                 // were added to the buffer.
-            	StringBuilder tempBuffer = new StringBuilder();
+                StringBuilder tempBuffer = new StringBuilder();
                 refinement.printRefinementToBuffer( tempBuffer );
                 buffer.append( tempBuffer );
             }

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/ActionTime.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/ActionTime.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/ActionTime.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/ActionTime.java Fri Jun  6 23:28:06 2008
@@ -64,8 +64,9 @@
     }
 
 
-    /* (non-Javadoc)
+    /**
      * @see java.lang.Object#hashCode()
+     * @return the instance's hash code 
      */
     public int hashCode()
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/LdapOperation.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/LdapOperation.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/LdapOperation.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/LdapOperation.java Fri Jun  6 23:28:06 2008
@@ -68,8 +68,9 @@
     }
 
 
-    /* (non-Javadoc)
+    /**
      * @see java.lang.Object#hashCode()
+     * @return the instance's hash code 
      */
     public int hashCode()
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/SearchScope.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/SearchScope.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/SearchScope.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/SearchScope.java Fri Jun  6 23:28:06 2008
@@ -59,8 +59,9 @@
     }
     
 
-    /* (non-Javadoc)
+    /**
      * @see java.lang.Object#hashCode()
+     * @return the instance's hash code 
      */
     public int hashCode()
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureLanguageSchemeOption.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureLanguageSchemeOption.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureLanguageSchemeOption.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureLanguageSchemeOption.java Fri Jun  6 23:28:06 2008
@@ -50,8 +50,9 @@
         return "language " + "\"" + language + "\"";
     }
 
-    /* (non-Javadoc)
+    /**
      * @see java.lang.Object#hashCode()
+     * @return the instance's hash code 
      */
     public int hashCode()
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureParameter.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureParameter.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureParameter.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureParameter.java Fri Jun  6 23:28:06 2008
@@ -99,8 +99,9 @@
     }
     
 
-    /* (non-Javadoc)
+    /**
      * @see java.lang.Object#hashCode()
+     * @return the instance's hash code 
      */
     public int hashCode()
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureSearchContextOption.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureSearchContextOption.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureSearchContextOption.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureSearchContextOption.java Fri Jun  6 23:28:06 2008
@@ -62,8 +62,9 @@
         return "searchContext { scope " + searchScope + " } \"" + baseObject + "\""; 
     }
 
-    /* (non-Javadoc)
+    /**
      * @see java.lang.Object#hashCode()
+     * @return the instance's hash code 
      */
     public int hashCode()
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecification.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecification.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecification.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecification.java Fri Jun  6 23:28:06 2008
@@ -51,7 +51,7 @@
         }
         if ( spSpecs.size() == 0 )
         {
-        	throw new IllegalArgumentException( "TriggerSpecification cannot be initialized with emtpy SPSPec list." );
+            throw new IllegalArgumentException( "TriggerSpecification cannot be initialized with emtpy SPSPec list." );
         }
         this.ldapOperation = ldapOperation;
         this.actionTime = actionTime;
@@ -69,72 +69,76 @@
     }
 
     public List<SPSpec> getSPSpecs() {
-		return spSpecs;
-	}
+        return spSpecs;
+    }
     
     public static class SPSpec
     {
-    	private String name;
+        private String name;
         
         private List<StoredProcedureOption> options;
         
         private List<StoredProcedureParameter> parameters;
 
         public SPSpec(String name, List<StoredProcedureOption> options, List<StoredProcedureParameter> parameters) {
-			super();
-			this.name = name;
-			this.options = options;
-			this.parameters = parameters;
-		}
+            super();
+            this.name = name;
+            this.options = options;
+            this.parameters = parameters;
+        }
         
-		public String getName() {
-			return name;
-		}
-
-		public List<StoredProcedureOption> getOptions() {
-			return options;
-		}
-
-		public List<StoredProcedureParameter> getParameters() {
-			return parameters;
-		}
-
-		@Override
-		public int hashCode() {
-			int h = 37;
-			
-			h = h*17 + ((name == null) ? 0 : name.hashCode());
-			h = h*17 + ((options == null) ? 0 : options.hashCode());
-			h = h*17 + ((parameters == null) ? 0 : parameters.hashCode());
-			return h;
-		}
-
-		@Override
-		public boolean equals(Object obj) {
-			if (this == obj)
-				return true;
-			if (obj == null)
-				return false;
-			if (getClass() != obj.getClass())
-				return false;
-			final SPSpec other = (SPSpec) obj;
-			if (name == null) {
-				if (other.name != null)
-					return false;
-			} else if (!name.equals(other.name))
-				return false;
-			if (options == null) {
-				if (other.options != null)
-					return false;
-			} else if (!options.equals(other.options))
-				return false;
-			if (parameters == null) {
-				if (other.parameters != null)
-					return false;
-			} else if (!parameters.equals(other.parameters))
-				return false;
-			return true;
-		}
+        public String getName() {
+            return name;
+        }
+
+        public List<StoredProcedureOption> getOptions() {
+            return options;
+        }
+
+        public List<StoredProcedureParameter> getParameters() {
+            return parameters;
+        }
+
+        @Override
+        /**
+         * Compute the instance's hash code
+         * @return the instance's hash code 
+         */
+        public int hashCode() {
+            int h = 37;
+            
+            h = h*17 + ((name == null) ? 0 : name.hashCode());
+            h = h*17 + ((options == null) ? 0 : options.hashCode());
+            h = h*17 + ((parameters == null) ? 0 : parameters.hashCode());
+            return h;
+        }
+
+        @Override
+        public boolean equals(Object obj) {
+            if (this == obj)
+                return true;
+            if (obj == null)
+                return false;
+            if (getClass() != obj.getClass())
+                return false;
+            final SPSpec other = (SPSpec) obj;
+            if (name == null) {
+                if (other.name != null)
+                    return false;
+            } else if (!name.equals(other.name))
+                return false;
+            if (options == null) {
+                if (other.options != null)
+                    return false;
+            } else if (!options.equals(other.options))
+                return false;
+            if (parameters == null) {
+                if (other.parameters != null)
+                    return false;
+            } else if (!parameters.equals(other.parameters))
+                return false;
+            return true;
+        }
 
     }
     

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/AttributeSerializerUtils.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/AttributeSerializerUtils.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/AttributeSerializerUtils.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/AttributeSerializerUtils.java Fri Jun  6 23:28:06 2008
@@ -39,8 +39,6 @@
  */
 public class AttributeSerializerUtils
 {
-    private static final long serialVersionUID = -3756830073760754086L;
-  
     static final byte[] EMPTY_BYTE_ARRAY = new byte[0];
 
     /** value for type parameter for string (non-binary) attributes */
@@ -50,38 +48,6 @@
     static final byte BYTE_ARRAY_TYPE = 0x01;
     
     /*
-    private class ExtensibleByteArray
-    {
-    	private static final int EXTENSION = 2048;
-    	private List<byte[]> array;
-    	private byte[] currentData;
-    	private int pos = 0;
-    	private int limit = EXTENSION;
-    	
-    	private ExtensibleByteArray()
-    	{
-    		array = new ArrayList<byte[]>();
-    		currentData = new byte[EXTENSION];
-    		array.add( currentData );
-    	}
-    	
-    	private void extend()
-    	{
-    		limit += EXTENSION;
-    		array.add( new byte[EXTENSION] );
-    	}
-    	
-    	private void put( byte b )
-    	{
-    		if ( pos == limit )
-    		{
-    			extend();
-    			currentData = 
-    		}
-    		
-    		
-    	}
-    }*/
     
 
     // -----------------------------------------------------------------------

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/AttributeUtils.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/AttributeUtils.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/AttributeUtils.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/AttributeUtils.java Fri Jun  6 23:28:06 2008
@@ -20,13 +20,10 @@
 package org.apache.directory.shared.ldap.util;
 
 
-import org.apache.directory.shared.ldap.message.AttributeImpl;
-import org.apache.directory.shared.ldap.message.AttributesImpl;
-import org.apache.directory.shared.ldap.message.ModificationItemImpl;
-import org.apache.directory.shared.ldap.schema.AttributeType;
-import org.apache.directory.shared.ldap.schema.MatchingRule;
-import org.apache.directory.shared.ldap.schema.NoOpNormalizer;
-import org.apache.directory.shared.ldap.schema.Normalizer;
+import java.text.ParseException;
+
+import java.util.Arrays;
+import java.util.List;
 
 import javax.naming.NamingEnumeration;
 import javax.naming.NamingException;
@@ -35,9 +32,14 @@
 import javax.naming.directory.BasicAttributes;
 import javax.naming.directory.DirContext;
 import javax.naming.directory.ModificationItem;
-import java.text.ParseException;
-import java.util.Arrays;
-import java.util.List;
+
+import org.apache.directory.shared.ldap.message.AttributeImpl;
+import org.apache.directory.shared.ldap.message.AttributesImpl;
+import org.apache.directory.shared.ldap.message.ModificationItemImpl;
+import org.apache.directory.shared.ldap.schema.AttributeType;
+import org.apache.directory.shared.ldap.schema.MatchingRule;
+import org.apache.directory.shared.ldap.schema.NoOpNormalizer;
+import org.apache.directory.shared.ldap.schema.Normalizer;
 
 
 /**
@@ -54,17 +56,19 @@
      * @param type the attributeType of the attribute to remove
      * @param entry the entry to remove the attribute from 
      * @return the Attribute that is removed
-     * @throws NamingException if there are problems accessing the attribute
      */
     public static Attribute removeAttribute( AttributeType type, Attributes entry )
     {
         Attribute attr = entry.get( type.getOid() );
+        
         if ( attr == null )
         {
-            String[] aliases = type.getNames();
-            for ( int ii = 0; ii < aliases.length; ii++ )
+            String[] aliases = type.getNamesRef();
+            
+            for ( String alias:aliases )
             {
-                attr = entry.get( aliases[ii] );
+                attr = entry.get( alias );
+
                 if ( attr != null )
                 {
                     return entry.remove( attr.getID() );
@@ -242,9 +246,9 @@
         }
 
         // optimization bypass to avoid cost of the loop below
-        if ( type.getNames().length == 1 )
+        if ( type.getNamesRef().length == 1 )
         {
-            attr = attrs.get( type.getNames()[0] );
+            attr = attrs.get( type.getNamesRef()[0] );
             
             if ( attr != null )
             {
@@ -253,7 +257,7 @@
         }
         
         // iterate through aliases
-        for ( String alias:type.getNames() )
+        for ( String alias:type.getNamesRef() )
         {
             attr = attrs.get( alias );
             
@@ -277,11 +281,11 @@
     public static final ModificationItem getModificationItem( List<ModificationItemImpl> mods, AttributeType type )
     {
         // optimization bypass to avoid cost of the loop below
-        if ( type.getNames().length == 1 )
+        if ( type.getNamesRef().length == 1 )
         {
             for ( ModificationItem mod:mods )
             {
-                if ( mod.getAttribute().getID().equalsIgnoreCase( type.getNames()[0] ) )
+                if ( mod.getAttribute().getID().equalsIgnoreCase( type.getNamesRef()[0] ) )
                 {
                     return mod;
                 }
@@ -298,11 +302,11 @@
         }
         
         // iterate through aliases
-        for ( int ii = 0; ii < type.getNames().length; ii++ )
+        for ( int ii = 0; ii < type.getNamesRef().length; ii++ )
         {
             for ( ModificationItem mod:mods )
             {
-                if ( mod.getAttribute().getID().equalsIgnoreCase( type.getNames()[ii] ) )
+                if ( mod.getAttribute().getID().equalsIgnoreCase( type.getNamesRef()[ii] ) )
                 {
                     return mod;
                 }
@@ -410,6 +414,7 @@
                             pos++;
                             
                             state = 1;
+                            break;
                     }
                 }
             }
@@ -444,7 +449,6 @@
      * @param attr The attribute to check
      * @param value The value to look for
      * @return true if the value is present in the attribute
-     * @throws NamingException
      */
     public static boolean containsValueCaseIgnore( Attribute attr, Object value )
     {
@@ -509,9 +513,9 @@
         throws NamingException
     {
         // quick bypass test
-        for ( int ii = 0; ii < compared.length; ii++ )
+        for ( Object object:compared )
         {
-            if ( attr.contains( compared ) )
+            if ( attr.contains( object ) )
             {
                 return true;
             }
@@ -521,12 +525,14 @@
 
         if ( type.getSyntax().isHumanReadable() )
         {
-            for ( int jj = 0; jj < compared.length; jj++ )
+            for ( Object object:compared )
             {
-                String comparedStr = ( String ) normalizer.normalize( compared[jj] );
+                String comparedStr = ( String ) normalizer.normalize( object );
+                
                 for ( int ii = attr.size(); ii >= 0; ii-- )
                 {
                     String value = ( String ) attr.get( ii );
+                    
                     if ( comparedStr.equals( normalizer.normalize( value ) ) )
                     {
                         return true;
@@ -536,9 +542,10 @@
         }
         else
         {
-            for ( int jj = 0; jj < compared.length; jj++ )
+            for ( Object object:compared )
             {
-                byte[] comparedBytes = ( byte[] ) compared[jj];
+                byte[] comparedBytes = ( byte[] )object;
+                
                 for ( int ii = attr.size(); ii >= 0; ii-- )
                 {
                     if ( ArrayUtils.isEquals( comparedBytes, attr.get( ii ) ) )
@@ -572,7 +579,7 @@
     {
         String id;
 
-        if ( attr0 == null && attr1 == null )
+        if ( ( attr0 == null ) && ( attr1 == null ) )
         {
             throw new IllegalArgumentException( "Cannot figure out attribute ID if both args are null" );
         }
@@ -595,20 +602,14 @@
 
         Attribute attr = new AttributeImpl( id );
 
-        if ( attr0 != null )
+        for ( int ii = 0; ii < attr0.size(); ii++ )
         {
-            for ( int ii = 0; ii < attr0.size(); ii++ )
-            {
-                attr.add( attr0.get( ii ) );
-            }
+            attr.add( attr0.get( ii ) );
         }
 
-        if ( attr1 != null )
+        for ( int ii = 0; ii < attr1.size(); ii++ )
         {
-            for ( int ii = 0; ii < attr1.size(); ii++ )
-            {
-                attr.remove( attr1.get( ii ) );
-            }
+            attr.remove( attr1.get( ii ) );
         }
 
         return attr;
@@ -924,14 +925,14 @@
         parseNumber( str, pos );
         
         // We must have at least one '.' number
-        if ( StringTools.isCharASCII( str, pos.start, '.' ) == false )
+        if ( !StringTools.isCharASCII( str, pos.start, '.' ) )
         {
             throw new ParseException( "Invalid OID, missing '.'", pos.start );
         }
         
         pos.start++;
         
-        if ( parseNumber( str, pos ) == false )
+        if ( !parseNumber( str, pos ) )
         {
             throw new ParseException( "Invalid OID, missing a number after a '.'", pos.start );
         }
@@ -939,14 +940,14 @@
         while ( true )
         {
             // Break if we get something which is not a '.'
-            if ( StringTools.isCharASCII( str, pos.start, '.' ) == false )
+            if ( !StringTools.isCharASCII( str, pos.start, '.' ) )
             {
                 break;
             }
             
             pos.start++;
             
-            if ( parseNumber( str, pos ) == false )
+            if ( !parseNumber( str, pos ) )
             {
                 throw new ParseException( "Invalid OID, missing a number after a '.'", pos.start );
             }
@@ -1230,6 +1231,7 @@
                             pos++;
 
                             state = 1;
+                            break;
                     }
                 }
             }

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/Base64.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/Base64.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/Base64.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/Base64.java Fri Jun  6 23:28:06 2008
@@ -89,7 +89,7 @@
      *            data to decode.
      * @return the decoded binary data.
      */
-    public static byte[] decode( char[] a_data )
+    public static byte[] decode( char[] data )
     {
         // as our input could contain non-BASE64 data (newlines,
         // whitespace of any sort, whatever) we must first adjust
@@ -98,12 +98,13 @@
         // (b) think that we miscalculated our data length
         // just because of extraneous throw-away junk
 
-        int l_tempLen = a_data.length;
-        for ( int ii = 0; ii < a_data.length; ii++ )
+        int tempLen = data.length;
+        
+        for ( char c:data)
         {
-            if ( ( a_data[ii] > 255 ) || s_codes[a_data[ii]] < 0 )
+            if ( ( c > 255 ) || s_codes[c] < 0 )
             {
-                --l_tempLen; // ignore non-valid chars and padding
+                --tempLen; // ignore non-valid chars and padding
             }
         }
         // calculate required length:
@@ -111,14 +112,14 @@
         // -- plus 2 bytes if there are 3 extra base64 chars,
         // or plus 1 byte if there are 2 extra.
 
-        int l_len = ( l_tempLen / 4 ) * 3;
+        int l_len = ( tempLen / 4 ) * 3;
 
-        if ( ( l_tempLen % 4 ) == 3 )
+        if ( ( tempLen % 4 ) == 3 )
         {
             l_len += 2;
         }
 
-        if ( ( l_tempLen % 4 ) == 2 )
+        if ( ( tempLen % 4 ) == 2 )
         {
             l_len += 1;
         }
@@ -130,9 +131,9 @@
         int l_index = 0;
 
         // we now go through the entire array (NOT using the 'tempLen' value)
-        for ( int ii = 0; ii < a_data.length; ii++ )
+        for ( char c:data )
         {
-            int l_value = ( a_data[ii] > 255 ) ? -1 : s_codes[a_data[ii]];
+            int l_value = ( c > 255 ) ? -1 : s_codes[c];
 
             if ( l_value >= 0 ) // skip over non-code
             {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/DummySSLSocketFactory.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/DummySSLSocketFactory.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/DummySSLSocketFactory.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/DummySSLSocketFactory.java Fri Jun  6 23:28:06 2008
@@ -17,7 +17,6 @@
  *  under the License. 
  *  
  */
-
 package org.apache.directory.shared.ldap.util;
 
 
@@ -209,5 +208,4 @@
             throw e;
         }
     }
-
 }

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/LongComparator.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/LongComparator.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/LongComparator.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/LongComparator.java Fri Jun  6 23:28:06 2008
@@ -49,22 +49,22 @@
      */
     public int compare( Object obj1, Object obj2 )
     {
-    	try
-    	{
+        try
+        {
             Long long1 = (Long)obj1;
             Long long2 = (Long)obj2;
             return long1.compareTo( long2 );
-    	}
-    	catch ( NullPointerException npe )
-    	{
-	        if ( obj1 == null )
-	        {
-	            throw new IllegalArgumentException( "Argument 'obj1' is null" );
-	        }
-	        else
-	        {
-	            throw new IllegalArgumentException( "Argument 'obj2' is null" );
-	        }
-    	}
+        }
+        catch ( NullPointerException npe )
+        {
+            if ( obj1 == null )
+            {
+                throw new IllegalArgumentException( "Argument 'obj1' is null" );
+            }
+            else
+            {
+                throw new IllegalArgumentException( "Argument 'obj2' is null" );
+            }
+        }
     }
 }

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/MultiMap.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/MultiMap.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/MultiMap.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/MultiMap.java Fri Jun  6 23:28:06 2008
@@ -53,7 +53,7 @@
  * @version $Revision$ $Date$
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public interface MultiMap extends Map
+public interface MultiMap<K,V> extends Map<K,V>
 {
 
     /**
@@ -78,7 +78,7 @@
      * @throws NullPointerException
      *             if the key or value is null and null is invalid
      */
-    public Object remove( Object key, Object item );
+    Object remove( K key, V item );
 
 
     // -----------------------------------------------------------------------
@@ -117,7 +117,7 @@
      * @throws NullPointerException
      *             if the key is null and null keys are invalid
      */
-    Object get( Object key );
+    V get( K key );
 
 
     /**
@@ -135,7 +135,7 @@
      * @throws NullPointerException
      *             if the value is null and null value are invalid
      */
-    boolean containsValue( Object value );
+    boolean containsValue( V value );
 
 
     /**
@@ -161,7 +161,7 @@
      * @throws IllegalArgumentException
      *             if the key or value is invalid
      */
-    Object put( Object key, Object value );
+    V put( K key, V value );
 
 
     /**
@@ -183,7 +183,7 @@
      * @throws NullPointerException
      *             if the key is null and null keys are invalid
      */
-    Object remove( Object key );
+    V remove( K key );
 
 
     /**
@@ -195,6 +195,5 @@
      * 
      * @return a collection view of the values contained in this map
      */
-    Collection values();
-
+    Collection<V> values();
 }

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/PropertiesUtils.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/PropertiesUtils.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/PropertiesUtils.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/PropertiesUtils.java Fri Jun  6 23:28:06 2008
@@ -589,7 +589,7 @@
         
         if ( entry != null )
         {
-        	values = entry.getAttributes();
+            values = entry.getAttributes();
         }
         return values;
     }

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/SequencedHashMap.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/SequencedHashMap.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/SequencedHashMap.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/SequencedHashMap.java Fri Jun  6 23:28:06 2008
@@ -119,6 +119,10 @@
         }
 
 
+        /**
+         * Compute the instance's hash code
+         * @return the instance's hash code 
+         */
         public int hashCode()
         {
             // implemented per api docs for Map.Entry.hashCode()
@@ -622,6 +626,7 @@
 
     /**
      * Implements {@link Map#hashCode()}.
+     * @return the instance's hash code 
      */
     public int hashCode()
     {

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/StringTools.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/StringTools.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/StringTools.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/StringTools.java Fri Jun  6 23:28:06 2008
@@ -48,8 +48,8 @@
 public class StringTools
 {
     /** The default charset, because it's not provided by JDK 1.5 */
-	static String defaultCharset = null;
-	
+    static String defaultCharset = null;
+    
 
     
     // ~ Static fields/initializers
@@ -313,38 +313,38 @@
     
     private static final char[] TO_LOWER_CASE =
     {
-    	0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
-    	0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
-    	0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17,
-    	0x18, 0x19, 0x1A, 0x1B, 0x1C, 0x1D, 0x1E, 0x1F,
-    	' ',  0x21, 0x22, 0x23, 0x24, 0x25, 0x26, '\'',
-    	'(',  ')',  0x2A, '+',  ',',  '-',  '.',  '/',
-    	'0',  '1',  '2',  '3',  '4',  '5',  '6',  '7',  
-    	'8',  '9',  ':',  0x3B, 0x3C, '=',  0x3E, '?',
-    	0x40, 'a',  'b',  'c',  'd',  'e',  'f',  'g', 
-    	'h',  'i',  'j',  'k',  'l',  'm',  'n',  'o',
-    	'p',  'q',  'r',  's',  't',  'u',  'v',  'w',
-    	'x',  'y',  'z',  0x5B, 0x5C, 0x5D, 0x5E, 0x5F,
-    	0x60, 'a',  'b',  'c',  'd',  'e',  'f',  'g',
-    	'h',  'i',  'j',  'k',  'l',  'm',  'n',  'o',
-    	'p',  'q',  'r',  's',  't',  'u',  'v',  'w',
-    	'x',  'y',  'z',  0x7B, 0x7C, 0x7D, 0x7E, 0x7F,
-    	0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87,
-    	0x88, 0x89, 0x8A, 0x8B, 0x8C, 0x8D, 0x8E, 0x8F,
-    	0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97,
-    	0x98, 0x99, 0x9A, 0x9B, 0x9C, 0x9D, 0x9E, 0x9F,
-    	0xA0, 0xA1, 0xA2, 0xA3, 0xA4, 0xA5, 0xA6, 0xA7,
-    	0xA8, 0xA9, 0xAA, 0xAB, 0xAC, 0xAD, 0xAE, 0xAF,
-    	0xB0, 0xB1, 0xB2, 0xB3, 0xB4, 0xB5, 0xB6, 0xB7,
-    	0xB8, 0xB9, 0xBA, 0xBB, 0xBC, 0xBD, 0xBE, 0xBF,
-    	0xC0, 0xC1, 0xC2, 0xC3, 0xC4, 0xC5, 0xC6, 0xC7,
-    	0xC8, 0xC9, 0xCA, 0xCB, 0xCC, 0xCD, 0xCE, 0xCF,
-    	0xD0, 0xD1, 0xD2, 0xD3, 0xD4, 0xD5, 0xD6, 0xD7,
-    	0xD8, 0xD9, 0xDA, 0xDB, 0xDC, 0xDD, 0xDE, 0xDF,
-    	0xE0, 0xE1, 0xE2, 0xE3, 0xE4, 0xE5, 0xE6, 0xE7,
-    	0xE8, 0xE9, 0xEA, 0xEB, 0xEC, 0xED, 0xEE, 0xEF,
-    	0xF0, 0xF1, 0xF2, 0xF3, 0xF4, 0xF5, 0xF6, 0xF7,
-    	0xF8, 0xF9, 0xFA, 0xFB, 0xFC, 0xFD, 0xFE, 0xFF,
+        0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+        0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
+        0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17,
+        0x18, 0x19, 0x1A, 0x1B, 0x1C, 0x1D, 0x1E, 0x1F,
+        ' ',  0x21, 0x22, 0x23, 0x24, 0x25, 0x26, '\'',
+        '(',  ')',  0x2A, '+',  ',',  '-',  '.',  '/',
+        '0',  '1',  '2',  '3',  '4',  '5',  '6',  '7',  
+        '8',  '9',  ':',  0x3B, 0x3C, '=',  0x3E, '?',
+        0x40, 'a',  'b',  'c',  'd',  'e',  'f',  'g', 
+        'h',  'i',  'j',  'k',  'l',  'm',  'n',  'o',
+        'p',  'q',  'r',  's',  't',  'u',  'v',  'w',
+        'x',  'y',  'z',  0x5B, 0x5C, 0x5D, 0x5E, 0x5F,
+        0x60, 'a',  'b',  'c',  'd',  'e',  'f',  'g',
+        'h',  'i',  'j',  'k',  'l',  'm',  'n',  'o',
+        'p',  'q',  'r',  's',  't',  'u',  'v',  'w',
+        'x',  'y',  'z',  0x7B, 0x7C, 0x7D, 0x7E, 0x7F,
+        0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87,
+        0x88, 0x89, 0x8A, 0x8B, 0x8C, 0x8D, 0x8E, 0x8F,
+        0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97,
+        0x98, 0x99, 0x9A, 0x9B, 0x9C, 0x9D, 0x9E, 0x9F,
+        0xA0, 0xA1, 0xA2, 0xA3, 0xA4, 0xA5, 0xA6, 0xA7,
+        0xA8, 0xA9, 0xAA, 0xAB, 0xAC, 0xAD, 0xAE, 0xAF,
+        0xB0, 0xB1, 0xB2, 0xB3, 0xB4, 0xB5, 0xB6, 0xB7,
+        0xB8, 0xB9, 0xBA, 0xBB, 0xBC, 0xBD, 0xBE, 0xBF,
+        0xC0, 0xC1, 0xC2, 0xC3, 0xC4, 0xC5, 0xC6, 0xC7,
+        0xC8, 0xC9, 0xCA, 0xCB, 0xCC, 0xCD, 0xCE, 0xCF,
+        0xD0, 0xD1, 0xD2, 0xD3, 0xD4, 0xD5, 0xD6, 0xD7,
+        0xD8, 0xD9, 0xDA, 0xDB, 0xDC, 0xDD, 0xDE, 0xDF,
+        0xE0, 0xE1, 0xE2, 0xE3, 0xE4, 0xE5, 0xE6, 0xE7,
+        0xE8, 0xE9, 0xEA, 0xEB, 0xEC, 0xED, 0xEE, 0xEF,
+        0xF0, 0xF1, 0xF2, 0xF3, 0xF4, 0xF5, 0xF6, 0xF7,
+        0xF8, 0xF9, 0xFA, 0xFB, 0xFC, 0xFD, 0xFE, 0xFF,
     };
     
 
@@ -1535,7 +1535,7 @@
         }
         else
         {
-        	return string.substring( index ).startsWith( text );
+            return string.substring( index ).startsWith( text );
         }
     }
     
@@ -3025,7 +3025,7 @@
         
         for ( char c:chars )
         {
-        	chars[pos++] = TO_LOWER_CASE[c];
+            chars[pos++] = TO_LOWER_CASE[c];
         }
         
         return new String( chars );
@@ -3301,22 +3301,22 @@
      */
     public static final String getDefaultCharsetName()
     {
-    	if ( null == defaultCharset ) 
-    	{
-    		try 
-    		{
-    			// Try with jdk 1.5 method, if we are using a 1.5 jdk :)
-    			Method method = Charset.class.getMethod( "defaultCharset", new Class[0] );
-    			defaultCharset = ((Charset) method.invoke( null, new Object[0]) ).name();
-    		} 
-    		catch (Exception e) 
-    		{
-    			// fall back to old method
-    			defaultCharset = new OutputStreamWriter( new ByteArrayOutputStream() ).getEncoding();
-    		}
-    	}
+        if ( null == defaultCharset ) 
+        {
+            try 
+            {
+                // Try with jdk 1.5 method, if we are using a 1.5 jdk :)
+                Method method = Charset.class.getMethod( "defaultCharset", new Class[0] );
+                defaultCharset = ((Charset) method.invoke( null, new Object[0]) ).name();
+            } 
+            catch (Exception e) 
+            {
+                // fall back to old method
+                defaultCharset = new OutputStreamWriter( new ByteArrayOutputStream() ).getEncoding();
+            }
+        }
 
-    	return defaultCharset;
+        return defaultCharset;
     }
     
     
@@ -3473,17 +3473,17 @@
      */
     public static String getType( byte[] bytes)
     {
-    	if ( bytes == null )
-    	{
-    		return null;
-    	}
-    	
-    	char[] chars = new char[bytes.length];
+        if ( bytes == null )
+        {
+            return null;
+        }
+        
+        char[] chars = new char[bytes.length];
         int pos = 0;
         
         for ( byte b:bytes )
         {
-        	chars[pos++] = TO_LOWER_CASE[b];
+            chars[pos++] = TO_LOWER_CASE[b];
         }
         
         return new String( chars );

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/UnixCrypt.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/UnixCrypt.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/UnixCrypt.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/util/UnixCrypt.java Fri Jun  6 23:28:06 2008
@@ -19,7 +19,7 @@
  */
 
 /*
- * @(#)UnixCrypt.java	0.9 96/11/25
+ * @(#)UnixCrypt.java    0.9 96/11/25
  *
  * Copyright (c) 1996 Aki Yoshida. All rights reserved.
  *
@@ -32,8 +32,8 @@
 /**
  * Unix crypt(3C) utility
  *
- * @version 	0.9, 11/25/96
- * @author 	Aki Yoshida
+ * @version     0.9, 11/25/96
+ * @author     Aki Yoshida
  */
 
 /**

Modified: directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/codec/util/LdapUrlTest.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/codec/util/LdapUrlTest.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/codec/util/LdapUrlTest.java (original)
+++ directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/codec/util/LdapUrlTest.java Fri Jun  6 23:28:06 2008
@@ -20,11 +20,18 @@
 package org.apache.directory.shared.ldap.codec.util;
 
 
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.naming.InvalidNameException;
+import javax.naming.directory.SearchControls;
+
 import junit.framework.Assert;
 import junit.framework.TestCase;
 
 import org.apache.directory.shared.ldap.codec.util.LdapURL;
 import org.apache.directory.shared.ldap.codec.util.LdapURLEncodingException;
+import org.apache.directory.shared.ldap.name.LdapDN;
 
 
 /**
@@ -600,4 +607,184 @@
         Assert.assertEquals( "ldap:///??sub??!bindname=cn=Manager%2co=Foo", new LdapURL(
             "ldap:///??sub??!bindname=cn=Manager%2co=Foo" ).toString() );
     }
+
+
+    /**
+     * test an empty ldaps:// LdapURL
+     */
+    public void testLdapDNEmptyLdaps() throws LdapURLEncodingException
+    {
+        Assert.assertEquals( "ldaps:///", new LdapURL( "ldaps:///" ).toString() );
+    }
+
+
+    /**
+     * test an simple ldaps:// LdapURL
+     */
+    public void testLdapDNSimpleLdaps() throws LdapURLEncodingException
+    {
+        Assert.assertEquals( "ldaps://directory.apache.org:80/", new LdapURL( "ldaps://directory.apache.org:80/" )
+            .toString() );
+    }
+
+
+    /**
+     * test the setScheme() method
+     */
+    public void testLdapDNSetScheme() throws LdapURLEncodingException
+    {
+        LdapURL url = new LdapURL();
+        Assert.assertEquals( "ldap://", url.getScheme() );
+
+        url.setScheme( "invalid" );
+        Assert.assertEquals( "ldap://", url.getScheme() );
+
+        url.setScheme( "ldap://" );
+        Assert.assertEquals( "ldap://", url.getScheme() );
+
+        url.setScheme( "ldaps://" );
+        Assert.assertEquals( "ldaps://", url.getScheme() );
+
+        url.setScheme( null );
+        Assert.assertEquals( "ldap://", url.getScheme() );
+    }
+
+
+    /**
+     * test the setHost() method
+     */
+    public void testLdapDNSetHost() throws LdapURLEncodingException
+    {
+        LdapURL url = new LdapURL();
+        Assert.assertNull( url.getHost() );
+
+        url.setHost( "ldap.apache.org" );
+        Assert.assertEquals( "ldap.apache.org", url.getHost() );
+        Assert.assertEquals( "ldap://ldap.apache.org/", url.toString() );
+
+        url.setHost( null );
+        Assert.assertNull( url.getHost() );
+        Assert.assertEquals( "ldap:///", url.toString() );
+    }
+
+
+    /**
+     * test the setPort() method
+     */
+    public void testLdapDNSetPort() throws LdapURLEncodingException
+    {
+        LdapURL url = new LdapURL();
+        Assert.assertEquals( -1, url.getPort() );
+
+        url.setPort( 389 );
+        Assert.assertEquals( 389, url.getPort() );
+        Assert.assertEquals( "ldap://:389/", url.toString() );
+
+        url.setPort( 0 );
+        Assert.assertEquals( -1, url.getPort() );
+        Assert.assertEquals( "ldap:///", url.toString() );
+
+        url.setPort( 65536 );
+        Assert.assertEquals( -1, url.getPort() );
+        Assert.assertEquals( "ldap:///", url.toString() );
+    }
+
+
+    /**
+     * test the setDn() method
+     */
+    public void testLdapDNSetDn() throws LdapURLEncodingException, InvalidNameException
+    {
+        LdapURL url = new LdapURL();
+        Assert.assertNull( url.getDn() );
+
+        LdapDN dn = new LdapDN( "dc=example,dc=com" );
+        url.setDn( dn );
+        Assert.assertEquals( dn, url.getDn() );
+        Assert.assertEquals( "ldap:///dc=example,dc=com", url.toString() );
+
+        url.setDn( null );
+        Assert.assertNull( url.getDn() );
+        Assert.assertEquals( "ldap:///", url.toString() );
+    }
+
+
+    /**
+     * test the setAttributes() method
+     */
+    public void testLdapDNSetAttributes() throws LdapURLEncodingException, InvalidNameException
+    {
+        LdapURL url = new LdapURL();
+        Assert.assertNotNull( url.getAttributes() );
+        Assert.assertTrue( url.getAttributes().isEmpty() );
+
+        List<String> attributes = new ArrayList<String>();
+        url.setDn( new LdapDN( "dc=example,dc=com" ) );
+
+        url.setAttributes( null );
+        Assert.assertNotNull( url.getAttributes() );
+        Assert.assertTrue( url.getAttributes().isEmpty() );
+        Assert.assertEquals( "ldap:///dc=example,dc=com", url.toString() );
+
+        attributes.add( "cn" );
+        url.setAttributes( attributes );
+        Assert.assertNotNull( url.getAttributes() );
+        Assert.assertEquals( 1, url.getAttributes().size() );
+        Assert.assertEquals( "ldap:///dc=example,dc=com?cn", url.toString() );
+
+        attributes.add( "userPassword;binary" );
+        url.setAttributes( attributes );
+        Assert.assertNotNull( url.getAttributes() );
+        Assert.assertEquals( 2, url.getAttributes().size() );
+        Assert.assertEquals( "ldap:///dc=example,dc=com?cn,userPassword;binary", url.toString() );
+    }
+
+
+    /**
+     * test the setScope() method
+     */
+    public void testLdapDNSetScope() throws LdapURLEncodingException, InvalidNameException
+    {
+        LdapURL url = new LdapURL();
+        Assert.assertEquals( SearchControls.OBJECT_SCOPE, url.getScope() );
+
+        url.setDn( new LdapDN( "dc=example,dc=com" ) );
+
+        url.setScope( SearchControls.ONELEVEL_SCOPE );
+        Assert.assertEquals( SearchControls.ONELEVEL_SCOPE, url.getScope() );
+        Assert.assertEquals( "ldap:///dc=example,dc=com??one", url.toString() );
+
+        url.setScope( SearchControls.SUBTREE_SCOPE );
+        Assert.assertEquals( SearchControls.SUBTREE_SCOPE, url.getScope() );
+        Assert.assertEquals( "ldap:///dc=example,dc=com??sub", url.toString() );
+
+        url.setScope( -1 );
+        Assert.assertEquals( SearchControls.OBJECT_SCOPE, url.getScope() );
+        Assert.assertEquals( "ldap:///dc=example,dc=com", url.toString() );
+    }
+
+
+    /**
+     * test the setFilter() method
+     */
+    public void testLdapDNSetFilter() throws LdapURLEncodingException, InvalidNameException
+    {
+        LdapURL url = new LdapURL();
+        Assert.assertNull( url.getFilter() );
+
+        url.setDn( new LdapDN( "dc=example,dc=com" ) );
+
+        url.setFilter( "(objectClass=person)" );
+        Assert.assertEquals( "(objectClass=person)", url.getFilter() );
+        Assert.assertEquals( "ldap:///dc=example,dc=com???(objectClass=person)", url.toString() );
+
+        url.setFilter( "(cn=Babs Jensen)" );
+        Assert.assertEquals( "(cn=Babs Jensen)", url.getFilter() );
+        Assert.assertEquals( "ldap:///dc=example,dc=com???(cn=Babs%20Jensen)", url.toString() );
+
+        url.setFilter( null );
+        Assert.assertNull( url.getFilter() );
+        Assert.assertEquals( "ldap:///dc=example,dc=com", url.toString() );
+    }
+
 }

Modified: directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/entry/client/ClientBinaryValueTest.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/entry/client/ClientBinaryValueTest.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/entry/client/ClientBinaryValueTest.java (original)
+++ directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/entry/client/ClientBinaryValueTest.java Fri Jun  6 23:28:06 2008
@@ -51,7 +51,7 @@
     
     private static final Normalizer BINARY_NORMALIZER = new Normalizer()
     {
-        public static final long serialVersionUID = 1L;
+        private static final long serialVersionUID = 1L;
         
         public Object normalize( Object value ) throws NamingException
         {

Modified: directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/ldif/LdifReaderTest.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/ldif/LdifReaderTest.java?rev=664290&r1=664289&r2=664290&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/ldif/LdifReaderTest.java (original)
+++ directory/shared/branches/bigbang/ldap/src/test/java/org/apache/directory/shared/ldap/ldif/LdifReaderTest.java Fri Jun  6 23:28:06 2008
@@ -139,7 +139,7 @@
             " is is still a comment\n" + 
             "\n" + 
             "version:\n" + 
-	    " 1\n" + 
+            " 1\n" + 
             "# end";
 
         LdifReader reader = new LdifReader();
@@ -259,7 +259,7 @@
         testReaderAttrIdCaseInsensitive( ldif );
     }
 
-    private void testReaderAttrIdCaseInsensitive( String ldif )
+    public void testReaderAttrIdCaseInsensitive( String ldif )
             throws NamingException
     {
         LdifReader reader = new LdifReader();



Mime
View raw message