directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r1068723 [1/3] - in /directory/shared/branches/m1: asn1-ber/src/main/java/org/apache/directory/shared/asn1/ber/grammar/ ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/ ldap-codec/src/main/java/org/apache/directory/shared/ld...
Date Wed, 09 Feb 2011 01:34:33 GMT
Author: elecharny
Date: Wed Feb  9 01:34:33 2011
New Revision: 1068723

URL: http://svn.apache.org/viewvc?rev=1068723&view=rev
Log:
o Added a method in GrammarTransition to avoid passing a null parameter
o Moved some more actions
o Reformated LdapGrammar

Added:
    directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/AllowGrammarEnd.java
    directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/searchResultEntry/
    directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/searchResultEntry/InitSearchResultEntry.java
    directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/actions/searchResultEntry/StoreObjectName.java
Modified:
    directory/shared/branches/m1/asn1-ber/src/main/java/org/apache/directory/shared/asn1/ber/grammar/GrammarTransition.java
    directory/shared/branches/m1/ldap-codec/src/main/java/org/apache/directory/shared/ldap/codec/LdapMessageGrammar.java

Modified: directory/shared/branches/m1/asn1-ber/src/main/java/org/apache/directory/shared/asn1/ber/grammar/GrammarTransition.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/m1/asn1-ber/src/main/java/org/apache/directory/shared/asn1/ber/grammar/GrammarTransition.java?rev=1068723&r1=1068722&r2=1068723&view=diff
==============================================================================
--- directory/shared/branches/m1/asn1-ber/src/main/java/org/apache/directory/shared/asn1/ber/grammar/GrammarTransition.java
(original)
+++ directory/shared/branches/m1/asn1-ber/src/main/java/org/apache/directory/shared/asn1/ber/grammar/GrammarTransition.java
Wed Feb  9 01:34:33 2011
@@ -6,16 +6,16 @@
  *  to you under the Apache License, Version 2.0 (the
  *  "License"); you may not use this file except in compliance
  *  with the License.  You may obtain a copy of the License at
- *  
+ *
  *    http://www.apache.org/licenses/LICENSE-2.0
- *  
+ *
  *  Unless required by applicable law or agreed to in writing,
  *  software distributed under the License is distributed on an
  *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  *  KIND, either express or implied.  See the License for the
  *  specific language governing permissions and limitations
- *  under the License. 
- *  
+ *  under the License.
+ *
  */
 package org.apache.directory.shared.asn1.ber.grammar;
 
@@ -27,7 +27,7 @@ import org.apache.directory.shared.asn1.
 /**
  * Define a transition between two states of a grammar. It stores the next
  * state, and the action to execute while executing the transition.
- * 
+ *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public class GrammarTransition<E extends Asn1Container>
@@ -47,7 +47,7 @@ public class GrammarTransition<E extends
 
     /**
      * Creates a new GrammarTransition object.
-     * 
+     *
      * @param previousState the previous state
      * @param currentState The current state
      * @param currentTag the current TLV's tag
@@ -63,8 +63,23 @@ public class GrammarTransition<E extends
 
 
     /**
+     * Creates a new GrammarTransition object.
+     *
+     * @param previousState the previous state
+     * @param currentState The current state
+     * @param currentTag the current TLV's tag
+     */
+    public GrammarTransition( Enum<?> previousState, Enum<?> currentState, int
currentTag )
+    {
+        this.previousState = previousState;
+        this.currentState = currentState;
+        this.currentTag = currentTag;
+    }
+
+
+    /**
      * Tells if the transition has an associated action.
-     * 
+     *
      * @return <code>true</code> if an action has been associated to the transition
      */
     public boolean hasAction()
@@ -104,6 +119,7 @@ public class GrammarTransition<E extends
      * @param statesEnum Starting state.
      * @return A representation of the transition as a string.
      */
+    @Override
     public String toString( )
     {
         StringBuilder sb = new StringBuilder();



Mime
View raw message