directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seelm...@apache.org
Subject svn commit: r1004185 - in /directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger: StoredProcedureLanguageSchemeOption.java StoredProcedureSearchContextOption.java TriggerSpecification.java TriggerSpecificationParser.java
Date Mon, 04 Oct 2010 10:15:09 GMT
Author: seelmann
Date: Mon Oct  4 10:15:08 2010
New Revision: 1004185

URL: http://svn.apache.org/viewvc?rev=1004185&view=rev
Log:
Javadoc and formatting

Modified:
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureLanguageSchemeOption.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureSearchContextOption.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecification.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecificationParser.java

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureLanguageSchemeOption.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureLanguageSchemeOption.java?rev=1004185&r1=1004184&r2=1004185&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureLanguageSchemeOption.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureLanguageSchemeOption.java
Mon Oct  4 10:15:08 2010
@@ -22,65 +22,92 @@ package org.apache.directory.shared.ldap
 
 
 /**
+ * The language schema option of triggered stored procedure.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public class StoredProcedureLanguageSchemeOption implements StoredProcedureOption
 {
-    
+
     private String language;
-    
+
+
+    /**
+     * Instantiates a new stored procedure language scheme option.
+     *
+     * @param language the language
+     */
     public StoredProcedureLanguageSchemeOption( String language )
     {
         this.language = language;
     }
-    
+
+
+    /**
+     * Gets the language.
+     *
+     * @return the language
+     */
     public String getLanguage()
     {
         return language;
     }
-    
+
 
     /**
-     * @see java.lang.Object#toString()
+     * {@inheritDoc}
      */
+    @Override
     public String toString()
     {
         return "language " + "\"" + language + "\"";
     }
 
+
     /**
-     * @see java.lang.Object#hashCode()
-     * @return the instance's hash code 
+     * {@inheritDoc}
      */
+    @Override
     public int hashCode()
     {
         int h = 37;
-        
-        h = h*17 + ( ( language == null ) ? 0 : language.hashCode() );
-        
+
+        h = h * 17 + ( ( language == null ) ? 0 : language.hashCode() );
+
         return h;
     }
 
+
     /**
-     * @see java.lang.Object#equals(java.lang.Object)
+     * {@inheritDoc}
      */
+    @Override
     public boolean equals( Object obj )
     {
         if ( this == obj )
+        {
             return true;
+        }
         if ( obj == null )
+        {
             return false;
+        }
         if ( getClass() != obj.getClass() )
+        {
             return false;
+        }
         final StoredProcedureLanguageSchemeOption other = ( StoredProcedureLanguageSchemeOption
) obj;
         if ( language == null )
         {
             if ( other.language != null )
+            {
                 return false;
+            }
         }
         else if ( !language.equals( other.language ) )
+        {
             return false;
+        }
         return true;
     }
 

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureSearchContextOption.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureSearchContextOption.java?rev=1004185&r1=1004184&r2=1004185&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureSearchContextOption.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/StoredProcedureSearchContextOption.java
Mon Oct  4 10:15:08 2010
@@ -20,89 +20,137 @@
 
 package org.apache.directory.shared.ldap.trigger;
 
+
 import org.apache.directory.shared.ldap.filter.SearchScope;
 import org.apache.directory.shared.ldap.name.DN;
 
 
 /**
+ * The search context option of the triggered stored procedure.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public class StoredProcedureSearchContextOption implements StoredProcedureOption
 {
-    
+
     private final DN baseObject;
     private SearchScope searchScope;
 
-    
+
+    /**
+     * Instantiates a new stored procedure search context option.
+     *
+     * @param baseObject the base object
+     */
     public StoredProcedureSearchContextOption( DN baseObject )
     {
         // the default search scope is "base"
         this( baseObject, SearchScope.OBJECT );
     }
-    
+
+
+    /**
+     * Instantiates a new stored procedure search context option.
+     *
+     * @param baseObject the base object
+     * @param searchScope the search scope
+     */
     public StoredProcedureSearchContextOption( DN baseObject, SearchScope searchScope )
     {
         this.baseObject = baseObject;
         this.searchScope = searchScope;
     }
 
+
+    /**
+     * Gets the base object.
+     *
+     * @return the base object
+     */
     public DN getBaseObject()
     {
         return baseObject;
     }
-    
+
+
+    /**
+     * Gets the search scope.
+     *
+     * @return the search scope
+     */
     public SearchScope getSearchScope()
     {
         return searchScope;
     }
 
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
     public String toString()
     {
-        return "searchContext { scope " + searchScope + " } \"" + baseObject + "\""; 
+        return "searchContext { scope " + searchScope + " } \"" + baseObject + "\"";
     }
 
+
     /**
-     * @see java.lang.Object#hashCode()
-     * @return the instance's hash code 
+     * {@inheritDoc}
      */
+    @Override
     public int hashCode()
     {
         int h = 37;
-        
-        h = h*17 + ( ( baseObject == null ) ? 0 : baseObject.hashCode() );
-        h = h*17 + ( ( searchScope == null ) ? 0 : searchScope.hashCode() );
-        
+
+        h = h * 17 + ( ( baseObject == null ) ? 0 : baseObject.hashCode() );
+        h = h * 17 + ( ( searchScope == null ) ? 0 : searchScope.hashCode() );
+
         return h;
     }
 
+
     /**
-     * @see java.lang.Object#equals(java.lang.Object)
+     * {@inheritDoc}
      */
+    @Override
     public boolean equals( Object obj )
     {
         if ( this == obj )
+        {
             return true;
+        }
         if ( obj == null )
+        {
             return false;
+        }
         if ( getClass() != obj.getClass() )
+        {
             return false;
+        }
         final StoredProcedureSearchContextOption other = ( StoredProcedureSearchContextOption
) obj;
         if ( baseObject == null )
         {
             if ( other.baseObject != null )
+            {
                 return false;
+            }
         }
         else if ( !baseObject.equals( other.baseObject ) )
+        {
             return false;
+        }
         if ( searchScope == null )
         {
             if ( other.searchScope != null )
+            {
                 return false;
+            }
         }
         else if ( !searchScope.equals( other.searchScope ) )
+        {
             return false;
+        }
         return true;
     }
-    
+
 }

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecification.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecification.java?rev=1004185&r1=1004184&r2=1004185&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecification.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecification.java
Mon Oct  4 10:15:08 2010
@@ -20,11 +20,13 @@
 
 package org.apache.directory.shared.ldap.trigger;
 
+
 import java.util.List;
 
 import org.apache.commons.lang.NullArgumentException;
 import org.apache.directory.shared.i18n.I18n;
 
+
 /**
  * The Trigger Specification Bean.
  * 
@@ -32,14 +34,21 @@ import org.apache.directory.shared.i18n.
  */
 public class TriggerSpecification
 {
-    
+
     private LdapOperation ldapOperation;
-    
+
     private ActionTime actionTime;
-    
-    private List<SPSpec> spSpecs; 
-    
-    
+
+    private List<SPSpec> spSpecs;
+
+
+    /**
+     * Instantiates a new trigger specification.
+     *
+     * @param ldapOperation the LDAP operation
+     * @param actionTime the action time
+     * @param spSpecs the stored procedure specs
+     */
     public TriggerSpecification( LdapOperation ldapOperation, ActionTime actionTime, List<SPSpec>
spSpecs )
     {
         super();
@@ -58,88 +67,170 @@ public class TriggerSpecification
         this.spSpecs = spSpecs;
     }
 
+
+    /**
+     * Gets the action time.
+     *
+     * @return the action time
+     */
     public ActionTime getActionTime()
     {
         return actionTime;
     }
 
+
+    /**
+     * Gets the LDAP operation.
+     *
+     * @return the LDAP operation
+     */
     public LdapOperation getLdapOperation()
     {
         return ldapOperation;
     }
 
-    public List<SPSpec> getSPSpecs() {
+
+    /**
+     * Gets the stored procedure specs.
+     *
+     * @return the stored procedure specs
+     */
+    public List<SPSpec> getSPSpecs()
+    {
         return spSpecs;
     }
-    
+
+    /**
+     * The stored procedure spec bean.
+     */
     public static class SPSpec
     {
         private String name;
-        
+
         private List<StoredProcedureOption> options;
-        
+
         private List<StoredProcedureParameter> parameters;
 
-        public SPSpec(String name, List<StoredProcedureOption> options, List<StoredProcedureParameter>
parameters) {
+
+        /**
+         * Instantiates a new stored procedure spec.
+         *
+         * @param name the name
+         * @param options the options
+         * @param parameters the parameters
+         */
+        public SPSpec( String name, List<StoredProcedureOption> options, List<StoredProcedureParameter>
parameters )
+        {
             super();
             this.name = name;
             this.options = options;
             this.parameters = parameters;
         }
-        
-        public String getName() {
+
+
+        /**
+         * Gets the name.
+         *
+         * @return the name
+         */
+        public String getName()
+        {
             return name;
         }
 
-        public List<StoredProcedureOption> getOptions() {
+
+        /**
+         * Gets the options.
+         *
+         * @return the options
+         */
+        public List<StoredProcedureOption> getOptions()
+        {
             return options;
         }
 
-        public List<StoredProcedureParameter> getParameters() {
+
+        /**
+         * Gets the parameters.
+         *
+         * @return the parameters
+         */
+        public List<StoredProcedureParameter> getParameters()
+        {
             return parameters;
         }
 
-        @Override
+
         /**
-         * Compute the instance's hash code
-         * @return the instance's hash code 
+         * {@inheritDoc}
          */
-        public int hashCode() {
+        @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());
+
+            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;
         }
 
+
+        /**
+         * {@inheritDoc}
+         */
         @Override
-        public boolean equals(Object obj) {
-            if (this == obj)
+        public boolean equals( Object obj )
+        {
+            if ( this == obj )
+            {
                 return true;
-            if (obj == null)
+            }
+            if ( obj == null )
+            {
                 return false;
-            if (getClass() != obj.getClass())
+            }
+            if ( getClass() != obj.getClass() )
+            {
                 return false;
-            final SPSpec other = (SPSpec) obj;
-            if (name == null) {
-                if (other.name != null)
+            }
+            final SPSpec other = ( SPSpec ) obj;
+            if ( name == null )
+            {
+                if ( other.name != null )
+                {
                     return false;
-            } else if (!name.equals(other.name))
+                }
+            }
+            else if ( !name.equals( other.name ) )
+            {
                 return false;
-            if (options == null) {
-                if (other.options != null)
+            }
+            if ( options == null )
+            {
+                if ( other.options != null )
+                {
                     return false;
-            } else if (!options.equals(other.options))
+                }
+            }
+            else if ( !options.equals( other.options ) )
+            {
                 return false;
-            if (parameters == null) {
-                if (other.parameters != null)
+            }
+            if ( parameters == null )
+            {
+                if ( other.parameters != null )
+                {
                     return false;
-            } else if (!parameters.equals(other.parameters))
+                }
+            }
+            else if ( !parameters.equals( other.parameters ) )
+            {
                 return false;
+            }
             return true;
         }
 
     }
-    
+
 }

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecificationParser.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecificationParser.java?rev=1004185&r1=1004184&r2=1004185&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecificationParser.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/trigger/TriggerSpecificationParser.java
Mon Oct  4 10:15:08 2010
@@ -65,6 +65,8 @@ public class TriggerSpecificationParser
 
     /**
      * Creates a normalizing TriggerSpecification parser.
+     *
+     * @param resolver the resolver
      */
     public TriggerSpecificationParser( NormalizerMappingResolver resolver )
     {



Mime
View raw message