directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r1064988 [2/2] - in /directory: apacheds/trunk/core-jndi/src/main/java/org/apache/directory/server/core/jndi/ apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/ apacheds/trunk/protocol-ldap/src/main/java/org/apach...
Date Sat, 29 Jan 2011 09:45:19 GMT
Copied: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueGrammar.java (from r1064846, directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueControlGrammar.java)
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueGrammar.java?p2=directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueGrammar.java&p1=directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueControlGrammar.java&r1=1064846&r2=1064988&rev=1064988&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueControlGrammar.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueGrammar.java Sat Jan 29 09:45:18 2011
@@ -21,7 +21,6 @@ package org.apache.directory.shared.ldap
 
 
 import org.apache.directory.shared.asn1.DecoderException;
-import org.apache.directory.shared.asn1.ber.Asn1Container;
 import org.apache.directory.shared.asn1.ber.grammar.AbstractGrammar;
 import org.apache.directory.shared.asn1.ber.grammar.Grammar;
 import org.apache.directory.shared.asn1.ber.grammar.GrammarAction;
@@ -62,27 +61,27 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public final class SyncInfoValueControlGrammar extends AbstractGrammar
+public final class SyncInfoValueGrammar extends AbstractGrammar
 {
     /** The logger */
-    static final Logger LOG = LoggerFactory.getLogger( SyncInfoValueControlGrammar.class );
+    static final Logger LOG = LoggerFactory.getLogger( SyncInfoValueGrammar.class );
 
     /** Speedup for logs */
     static final boolean IS_DEBUG = LOG.isDebugEnabled();
 
     /** The instance of grammar. SyncInfoValueControlGrammar is a singleton */
-    private static Grammar instance = new SyncInfoValueControlGrammar();
+    private static Grammar instance = new SyncInfoValueGrammar();
 
 
     /**
      * Creates a new SyncInfoValueControlGrammar object.
      */
-    private SyncInfoValueControlGrammar()
+    private SyncInfoValueGrammar()
     {
-        setName( SyncInfoValueControlGrammar.class.getName() );
+        setName( SyncInfoValueGrammar.class.getName() );
 
         // Create the transitions table
-        super.transitions = new GrammarTransition[SyncInfoValueControlStatesEnum.LAST_SYNC_INFO_VALUE_STATE.ordinal()][256];
+        super.transitions = new GrammarTransition[SyncInfoValueStatesEnum.LAST_SYNC_INFO_VALUE_STATE.ordinal()][256];
 
         /** 
          * Transition from initial state to SyncInfoValue newCookie choice
@@ -92,20 +91,18 @@ public final class SyncInfoValueControlG
          *     
          * Initialize the syncInfoValue object
          */
-        super.transitions[SyncInfoValueControlStatesEnum.START_STATE.ordinal()][SyncInfoValueTags.NEW_COOKIE_TAG.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.START_STATE, 
-                                    SyncInfoValueControlStatesEnum.NEW_COOKIE_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.START_STATE.ordinal()][SyncInfoValueTags.NEW_COOKIE_TAG.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.START_STATE, 
+                                    SyncInfoValueStatesEnum.NEW_COOKIE_STATE, 
                                     SyncInfoValueTags.NEW_COOKIE_TAG.getValue(), 
-                new GrammarAction( "NewCookie choice for SyncInfoValueControl" )
+                new GrammarAction<SyncInfoValueContainer>( "NewCookie choice for SyncInfoValueControl" )
             {
-                public void action( Asn1Container container )
+                public void action( SyncInfoValueContainer container )
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = 
-                        new SyncInfoValueControl( SynchronizationInfoEnum.NEW_COOKIE);
+                    SyncInfoValueDecorator control = 
+                        new SyncInfoValueDecorator( SynchronizationInfoEnum.NEW_COOKIE);
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     byte[] newCookie = value.getData();
 
@@ -117,9 +114,9 @@ public final class SyncInfoValueControlG
                     control.setCookie( newCookie );
 
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                     
-                    syncInfoValueContainer.setSyncInfoValueControl( control );
+                    container.setSyncInfoValueControl( control );
                 }
             } );
 
@@ -133,23 +130,21 @@ public final class SyncInfoValueControlG
          *     
          * Initialize the syncInfoValue object
          */
-        super.transitions[SyncInfoValueControlStatesEnum.START_STATE.ordinal()][SyncInfoValueTags.REFRESH_DELETE_TAG.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.START_STATE, 
-                                    SyncInfoValueControlStatesEnum.REFRESH_DELETE_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.START_STATE.ordinal()][SyncInfoValueTags.REFRESH_DELETE_TAG.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.START_STATE, 
+                                    SyncInfoValueStatesEnum.REFRESH_DELETE_STATE, 
                                     SyncInfoValueTags.REFRESH_DELETE_TAG.getValue(), 
-                new GrammarAction( "RefreshDelete choice for SyncInfoValueControl" )
+                new GrammarAction<SyncInfoValueContainer>( "RefreshDelete choice for SyncInfoValueControl" )
             {
-                public void action( Asn1Container container )
+                public void action( SyncInfoValueContainer container )
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = 
-                        new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_DELETE);
+                    SyncInfoValueDecorator control = 
+                        new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_DELETE);
                     
-                    syncInfoValueContainer.setSyncInfoValueControl( control );
+                    container.setSyncInfoValueControl( control );
 
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
 
@@ -162,19 +157,17 @@ public final class SyncInfoValueControlG
          *     
          * Load the cookie object
          */
-        super.transitions[SyncInfoValueControlStatesEnum.REFRESH_DELETE_STATE.ordinal()][UniversalTag.OCTET_STRING.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.REFRESH_DELETE_STATE, 
-                                    SyncInfoValueControlStatesEnum.REFRESH_DELETE_COOKIE_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.REFRESH_DELETE_STATE.ordinal()][UniversalTag.OCTET_STRING.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.REFRESH_DELETE_STATE, 
+                                    SyncInfoValueStatesEnum.REFRESH_DELETE_COOKIE_STATE, 
                                     UniversalTag.OCTET_STRING.getValue(), 
-                new GrammarAction( "RefreshDelete cookie" )
+                new GrammarAction<SyncInfoValueContainer>( "RefreshDelete cookie" )
             {
-                public void action( Asn1Container container )
+                public void action( SyncInfoValueContainer container )
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    SyncInfoValueDecorator control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     byte[] cookie = value.getData();
 
@@ -183,11 +176,11 @@ public final class SyncInfoValueControlG
                         LOG.debug( "cookie = " + Strings.dumpBytes(cookie) );
                     }
 
-                    syncInfoValueContainer.getSyncInfoValueControl().setCookie( cookie );
-                    syncInfoValueContainer.setSyncInfoValueControl( control );
+                    container.getSyncInfoValueControl().setCookie( cookie );
+                    container.setSyncInfoValueControl( control );
 
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
 
@@ -201,19 +194,17 @@ public final class SyncInfoValueControlG
          *     
          * Load the refreshDone flag
          */
-        super.transitions[SyncInfoValueControlStatesEnum.REFRESH_DELETE_COOKIE_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.REFRESH_DELETE_COOKIE_STATE, 
-                                    SyncInfoValueControlStatesEnum.LAST_SYNC_INFO_VALUE_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.REFRESH_DELETE_COOKIE_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.REFRESH_DELETE_COOKIE_STATE, 
+                                    SyncInfoValueStatesEnum.LAST_SYNC_INFO_VALUE_STATE, 
                                     UniversalTag.BOOLEAN.getValue(), 
-                new GrammarAction( "RefreshDelete refreshDone flag" )
+                new GrammarAction<SyncInfoValueContainer>( "RefreshDelete refreshDone flag" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    SyncInfoValueDecorator control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     try
                     {
@@ -226,10 +217,10 @@ public final class SyncInfoValueControlG
 
                         control.setRefreshDone( refreshDone );
 
-                        syncInfoValueContainer.setSyncInfoValueControl( control );
+                        container.setSyncInfoValueControl( control );
 
                         // the END transition for grammar
-                        syncInfoValueContainer.setGrammarEndAllowed( true );
+                        container.setGrammarEndAllowed( true );
                     }
                     catch ( BooleanDecoderException be )
                     {
@@ -240,7 +231,7 @@ public final class SyncInfoValueControlG
 
 
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
 
@@ -254,19 +245,17 @@ public final class SyncInfoValueControlG
          *     
          * Load the refreshDone flag
          */
-        super.transitions[SyncInfoValueControlStatesEnum.REFRESH_DELETE_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.REFRESH_DELETE_STATE, 
-                                    SyncInfoValueControlStatesEnum.LAST_SYNC_INFO_VALUE_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.REFRESH_DELETE_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.REFRESH_DELETE_STATE, 
+                                    SyncInfoValueStatesEnum.LAST_SYNC_INFO_VALUE_STATE, 
                                     UniversalTag.BOOLEAN.getValue(), 
-                new GrammarAction( "RefreshDelete refreshDone flag" )
+                new GrammarAction<SyncInfoValueContainer>( "RefreshDelete refreshDone flag" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    SyncInfoValueDecorator control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     try
                     {
@@ -279,10 +268,10 @@ public final class SyncInfoValueControlG
 
                         control.setRefreshDone( refreshDone );
 
-                        syncInfoValueContainer.setSyncInfoValueControl( control );
+                        container.setSyncInfoValueControl( control );
 
                         // the END transition for grammar
-                        syncInfoValueContainer.setGrammarEndAllowed( true );
+                        container.setGrammarEndAllowed( true );
                     }
                     catch ( BooleanDecoderException be )
                     {
@@ -293,7 +282,7 @@ public final class SyncInfoValueControlG
 
 
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
         
@@ -307,23 +296,21 @@ public final class SyncInfoValueControlG
          *     
          * Initialize the syncInfoValue object
          */
-        super.transitions[SyncInfoValueControlStatesEnum.START_STATE.ordinal()][SyncInfoValueTags.REFRESH_PRESENT_TAG.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.START_STATE, 
-                                    SyncInfoValueControlStatesEnum.REFRESH_PRESENT_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.START_STATE.ordinal()][SyncInfoValueTags.REFRESH_PRESENT_TAG.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.START_STATE, 
+                                    SyncInfoValueStatesEnum.REFRESH_PRESENT_STATE, 
                                     SyncInfoValueTags.REFRESH_PRESENT_TAG.getValue(), 
-                new GrammarAction( "RefreshDelete choice for SyncInfoValueControl" )
+                new GrammarAction<SyncInfoValueContainer>( "RefreshDelete choice for SyncInfoValueControl" )
             {
-                public void action( Asn1Container container )
+                public void action( SyncInfoValueContainer container )
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = 
-                        new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_PRESENT);
+                    SyncInfoValueDecorator control = 
+                        new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_PRESENT);
                     
-                    syncInfoValueContainer.setSyncInfoValueControl( control );
+                    container.setSyncInfoValueControl( control );
 
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
 
@@ -336,19 +323,17 @@ public final class SyncInfoValueControlG
          *     
          * Load the cookie object
          */
-        super.transitions[SyncInfoValueControlStatesEnum.REFRESH_PRESENT_STATE.ordinal()][UniversalTag.OCTET_STRING.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.REFRESH_PRESENT_STATE, 
-                                    SyncInfoValueControlStatesEnum.REFRESH_PRESENT_COOKIE_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.REFRESH_PRESENT_STATE.ordinal()][UniversalTag.OCTET_STRING.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.REFRESH_PRESENT_STATE, 
+                                    SyncInfoValueStatesEnum.REFRESH_PRESENT_COOKIE_STATE, 
                                     UniversalTag.OCTET_STRING.getValue(), 
-                new GrammarAction( "RefreshPresent cookie" )
+                new GrammarAction<SyncInfoValueContainer>( "RefreshPresent cookie" )
             {
-                public void action( Asn1Container container )
+                public void action( SyncInfoValueContainer container )
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    SyncInfoValueDecorator control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     byte[] cookie = value.getData();
 
@@ -357,11 +342,11 @@ public final class SyncInfoValueControlG
                         LOG.debug( "cookie = " + Strings.dumpBytes(cookie) );
                     }
 
-                    syncInfoValueContainer.getSyncInfoValueControl().setCookie( cookie );
-                    syncInfoValueContainer.setSyncInfoValueControl( control );
+                    container.getSyncInfoValueControl().setCookie( cookie );
+                    container.setSyncInfoValueControl( control );
 
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
         
@@ -377,19 +362,17 @@ public final class SyncInfoValueControlG
          *     
          * Load the refreshDone flag
          */
-        super.transitions[SyncInfoValueControlStatesEnum.REFRESH_PRESENT_COOKIE_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.REFRESH_PRESENT_COOKIE_STATE, 
-                                    SyncInfoValueControlStatesEnum.LAST_SYNC_INFO_VALUE_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.REFRESH_PRESENT_COOKIE_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.REFRESH_PRESENT_COOKIE_STATE, 
+                                    SyncInfoValueStatesEnum.LAST_SYNC_INFO_VALUE_STATE, 
                                     UniversalTag.BOOLEAN.getValue(), 
-                new GrammarAction( "RefreshPresent refreshDone flag" )
+                new GrammarAction<SyncInfoValueContainer>( "RefreshPresent refreshDone flag" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    SyncInfoValueDecorator control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     try
                     {
@@ -402,10 +385,10 @@ public final class SyncInfoValueControlG
 
                         control.setRefreshDone( refreshDone );
 
-                        syncInfoValueContainer.setSyncInfoValueControl( control );
+                        container.setSyncInfoValueControl( control );
 
                         // the END transition for grammar
-                        syncInfoValueContainer.setGrammarEndAllowed( true );
+                        container.setGrammarEndAllowed( true );
                     }
                     catch ( BooleanDecoderException be )
                     {
@@ -416,7 +399,7 @@ public final class SyncInfoValueControlG
 
 
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
 
@@ -430,19 +413,17 @@ public final class SyncInfoValueControlG
          *     
          * Load the refreshDone flag
          */
-        super.transitions[SyncInfoValueControlStatesEnum.REFRESH_PRESENT_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.REFRESH_PRESENT_STATE, 
-                                    SyncInfoValueControlStatesEnum.LAST_SYNC_INFO_VALUE_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.REFRESH_PRESENT_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.REFRESH_PRESENT_STATE, 
+                                    SyncInfoValueStatesEnum.LAST_SYNC_INFO_VALUE_STATE, 
                                     UniversalTag.BOOLEAN.getValue(), 
-                new GrammarAction( "RefreshPresent refreshDone flag" )
+                new GrammarAction<SyncInfoValueContainer>( "RefreshPresent refreshDone flag" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    SyncInfoValueDecorator control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     try
                     {
@@ -455,10 +436,10 @@ public final class SyncInfoValueControlG
 
                         control.setRefreshDone( refreshDone );
 
-                        syncInfoValueContainer.setSyncInfoValueControl( control );
+                        container.setSyncInfoValueControl( control );
 
                         // the END transition for grammar
-                        syncInfoValueContainer.setGrammarEndAllowed( true );
+                        container.setGrammarEndAllowed( true );
                     }
                     catch ( BooleanDecoderException be )
                     {
@@ -468,7 +449,7 @@ public final class SyncInfoValueControlG
                     }
 
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
         
@@ -482,20 +463,18 @@ public final class SyncInfoValueControlG
          *     
          * Initialize the syncInfoValue object
          */
-        super.transitions[SyncInfoValueControlStatesEnum.START_STATE.ordinal()][SyncInfoValueTags.SYNC_ID_SET_TAG.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.START_STATE, 
-                                    SyncInfoValueControlStatesEnum.SYNC_ID_SET_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.START_STATE.ordinal()][SyncInfoValueTags.SYNC_ID_SET_TAG.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.START_STATE, 
+                                    SyncInfoValueStatesEnum.SYNC_ID_SET_STATE, 
                                     SyncInfoValueTags.SYNC_ID_SET_TAG.getValue(), 
-                new GrammarAction( "SyncIdSet choice for SyncInfoValueControl" )
+                new GrammarAction<SyncInfoValueContainer>( "SyncIdSet choice for SyncInfoValueControl" )
             {
-                public void action( Asn1Container container )
+                public void action( SyncInfoValueContainer container )
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = 
-                        new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET);
+                    SyncInfoValueDecorator control = 
+                        new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET);
                     
-                    syncInfoValueContainer.setSyncInfoValueControl( control );
+                    container.setSyncInfoValueControl( control );
                 }
             } );
         
@@ -508,19 +487,17 @@ public final class SyncInfoValueControlG
          *     
          * Load the cookie object
          */
-        super.transitions[SyncInfoValueControlStatesEnum.SYNC_ID_SET_STATE.ordinal()][UniversalTag.OCTET_STRING.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.SYNC_ID_SET_STATE, 
-                                    SyncInfoValueControlStatesEnum.SYNC_ID_SET_COOKIE_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.SYNC_ID_SET_STATE.ordinal()][UniversalTag.OCTET_STRING.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.SYNC_ID_SET_STATE, 
+                                    SyncInfoValueStatesEnum.SYNC_ID_SET_COOKIE_STATE, 
                                     UniversalTag.OCTET_STRING.getValue(), 
-                new GrammarAction( "SyncIdSet cookie" )
+                new GrammarAction<SyncInfoValueContainer>( "SyncIdSet cookie" )
             {
-                public void action( Asn1Container container )
+                public void action( SyncInfoValueContainer container )
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    SyncInfoValueDecorator control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     byte[] cookie = value.getData();
 
@@ -529,8 +506,8 @@ public final class SyncInfoValueControlG
                         LOG.debug( "cookie = " + Strings.dumpBytes(cookie) );
                     }
 
-                    syncInfoValueContainer.getSyncInfoValueControl().setCookie( cookie );
-                    syncInfoValueContainer.setSyncInfoValueControl( control );
+                    container.getSyncInfoValueControl().setCookie( cookie );
+                    container.setSyncInfoValueControl( control );
                 }
             } );
         
@@ -544,19 +521,17 @@ public final class SyncInfoValueControlG
          *     
          * Load the refreshDeletes flag
          */
-        super.transitions[SyncInfoValueControlStatesEnum.SYNC_ID_SET_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.SYNC_ID_SET_STATE, 
-                                    SyncInfoValueControlStatesEnum.SYNC_ID_SET_REFRESH_DELETES_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.SYNC_ID_SET_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.SYNC_ID_SET_STATE, 
+                                    SyncInfoValueStatesEnum.SYNC_ID_SET_REFRESH_DELETES_STATE, 
                                     UniversalTag.BOOLEAN.getValue(), 
-                new GrammarAction( "SyncIdSet refreshDeletes" )
+                new GrammarAction<SyncInfoValueContainer>( "SyncIdSet refreshDeletes" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    SyncInfoValueDecorator control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     try
                     {
@@ -569,7 +544,7 @@ public final class SyncInfoValueControlG
 
                         control.setRefreshDeletes( refreshDeletes );
 
-                        syncInfoValueContainer.setSyncInfoValueControl( control );
+                        container.setSyncInfoValueControl( control );
                     }
                     catch ( BooleanDecoderException be )
                     {
@@ -590,19 +565,17 @@ public final class SyncInfoValueControlG
          *     
          * Load the refreshDeletes flag
          */
-        super.transitions[SyncInfoValueControlStatesEnum.SYNC_ID_SET_COOKIE_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.SYNC_ID_SET_COOKIE_STATE, 
-                                    SyncInfoValueControlStatesEnum.SYNC_ID_SET_REFRESH_DELETES_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.SYNC_ID_SET_COOKIE_STATE.ordinal()][UniversalTag.BOOLEAN.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.SYNC_ID_SET_COOKIE_STATE, 
+                                    SyncInfoValueStatesEnum.SYNC_ID_SET_REFRESH_DELETES_STATE, 
                                     UniversalTag.BOOLEAN.getValue(), 
-                new GrammarAction( "SyncIdSet refreshDeletes" )
+                new GrammarAction<SyncInfoValueContainer>( "SyncIdSet refreshDeletes" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    SyncInfoValueDecorator control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     try
                     {
@@ -615,7 +588,7 @@ public final class SyncInfoValueControlG
 
                         control.setRefreshDeletes( refreshDeletes );
 
-                        syncInfoValueContainer.setSyncInfoValueControl( control );
+                        container.setSyncInfoValueControl( control );
                     }
                     catch ( BooleanDecoderException be )
                     {
@@ -636,19 +609,16 @@ public final class SyncInfoValueControlG
          *     
          * Initialize the UUID set : no action associated, except allowing a grammar end
          */
-        super.transitions[SyncInfoValueControlStatesEnum.SYNC_ID_SET_STATE.ordinal()][UniversalTag.SET.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.SYNC_ID_SET_STATE, 
-                                    SyncInfoValueControlStatesEnum.SYNC_ID_SET_SET_OF_UUIDS_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.SYNC_ID_SET_STATE.ordinal()][UniversalTag.SET.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.SYNC_ID_SET_STATE, 
+                                    SyncInfoValueStatesEnum.SYNC_ID_SET_SET_OF_UUIDS_STATE, 
                                     UniversalTag.SET.getValue(), 
-                new GrammarAction( "SyncIdSet syncUUIDs" )
+                new GrammarAction<SyncInfoValueContainer>( "SyncIdSet syncUUIDs" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
         
@@ -662,19 +632,16 @@ public final class SyncInfoValueControlG
          *     
          * Initialize the UUID set : no action associated
          */
-        super.transitions[SyncInfoValueControlStatesEnum.SYNC_ID_SET_COOKIE_STATE.ordinal()][UniversalTag.SET.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.SYNC_ID_SET_COOKIE_STATE, 
-                                    SyncInfoValueControlStatesEnum.SYNC_ID_SET_SET_OF_UUIDS_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.SYNC_ID_SET_COOKIE_STATE.ordinal()][UniversalTag.SET.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.SYNC_ID_SET_COOKIE_STATE, 
+                                    SyncInfoValueStatesEnum.SYNC_ID_SET_SET_OF_UUIDS_STATE, 
                                     UniversalTag.SET.getValue(),
-                new GrammarAction( "SyncIdSet syncUUIDs" )
+                new GrammarAction<SyncInfoValueContainer>( "SyncIdSet syncUUIDs" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
           
@@ -688,19 +655,16 @@ public final class SyncInfoValueControlG
          *     
          * Initialize the UUID set : no action associated
          */
-        super.transitions[SyncInfoValueControlStatesEnum.SYNC_ID_SET_REFRESH_DELETES_STATE.ordinal()][UniversalTag.SET.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.SYNC_ID_SET_REFRESH_DELETES_STATE, 
-                                    SyncInfoValueControlStatesEnum.SYNC_ID_SET_SET_OF_UUIDS_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.SYNC_ID_SET_REFRESH_DELETES_STATE.ordinal()][UniversalTag.SET.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.SYNC_ID_SET_REFRESH_DELETES_STATE, 
+                                    SyncInfoValueStatesEnum.SYNC_ID_SET_SET_OF_UUIDS_STATE, 
                                     UniversalTag.SET.getValue(), 
-                new GrammarAction( "SyncIdSet syncUUIDs" )
+                new GrammarAction<SyncInfoValueContainer>( "SyncIdSet syncUUIDs" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
         
@@ -714,19 +678,17 @@ public final class SyncInfoValueControlG
          *     
          * Add the first UUID in the UUIDs list
          */
-        super.transitions[SyncInfoValueControlStatesEnum.SYNC_ID_SET_SET_OF_UUIDS_STATE.ordinal()][UniversalTag.OCTET_STRING.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.SYNC_ID_SET_SET_OF_UUIDS_STATE, 
-                                    SyncInfoValueControlStatesEnum.SYNC_ID_SET_UUID_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.SYNC_ID_SET_SET_OF_UUIDS_STATE.ordinal()][UniversalTag.OCTET_STRING.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.SYNC_ID_SET_SET_OF_UUIDS_STATE, 
+                                    SyncInfoValueStatesEnum.SYNC_ID_SET_UUID_STATE, 
                                     UniversalTag.OCTET_STRING.getValue(), 
-                new GrammarAction( "SyncIdSet first UUID" )
+                new GrammarAction<SyncInfoValueContainer>( "SyncIdSet first UUID" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    ISyncInfoValue control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     byte[] uuid = value.getData();
                     
@@ -747,7 +709,7 @@ public final class SyncInfoValueControlG
                     control.getSyncUUIDs().add( uuid );
                     
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
         
@@ -761,19 +723,17 @@ public final class SyncInfoValueControlG
          *     
          * Add a new UUID in the UUIDs list
          */
-        super.transitions[SyncInfoValueControlStatesEnum.SYNC_ID_SET_UUID_STATE.ordinal()][UniversalTag.OCTET_STRING.getValue()] = 
-            new GrammarTransition( SyncInfoValueControlStatesEnum.SYNC_ID_SET_UUID_STATE, 
-                                    SyncInfoValueControlStatesEnum.SYNC_ID_SET_UUID_STATE, 
+        super.transitions[SyncInfoValueStatesEnum.SYNC_ID_SET_UUID_STATE.ordinal()][UniversalTag.OCTET_STRING.getValue()] = 
+            new GrammarTransition( SyncInfoValueStatesEnum.SYNC_ID_SET_UUID_STATE, 
+                                    SyncInfoValueStatesEnum.SYNC_ID_SET_UUID_STATE, 
                                     UniversalTag.OCTET_STRING.getValue(), 
-                new GrammarAction( "SyncIdSet UUID" )
+                new GrammarAction<SyncInfoValueContainer>( "SyncIdSet UUID" )
             {
-                public void action( Asn1Container container ) throws DecoderException
+                public void action( SyncInfoValueContainer container ) throws DecoderException
                 {
-                    SyncInfoValueControlContainer syncInfoValueContainer = 
-                        ( SyncInfoValueControlContainer ) container;
-                    SyncInfoValueControl control = syncInfoValueContainer.getSyncInfoValueControl();
+                    ISyncInfoValue control = container.getSyncInfoValueControl();
                     
-                    Value value = syncInfoValueContainer.getCurrentTLV().getValue();
+                    Value value = container.getCurrentTLV().getValue();
 
                     byte[] uuid = value.getData();
                     
@@ -794,7 +754,7 @@ public final class SyncInfoValueControlG
                     control.getSyncUUIDs().add( uuid );
                     
                     // We can have an END transition
-                    syncInfoValueContainer.setGrammarEndAllowed( true );
+                    container.setGrammarEndAllowed( true );
                 }
             } );
     }

Copied: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueStatesEnum.java (from r1064846, directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueControlStatesEnum.java)
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueStatesEnum.java?p2=directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueStatesEnum.java&p1=directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueControlStatesEnum.java&r1=1064846&r2=1064988&rev=1064988&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueControlStatesEnum.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueStatesEnum.java Sat Jan 29 09:45:18 2011
@@ -30,7 +30,7 @@ import org.apache.directory.shared.asn1.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public enum SyncInfoValueControlStatesEnum implements States
+public enum SyncInfoValueStatesEnum implements States
 {
     // ~ Static fields/initializers
     // -----------------------------------------------------------------
@@ -104,7 +104,7 @@ public enum SyncInfoValueControlStatesEn
      */
     public String getGrammarName( Grammar grammar )
     {
-        if ( grammar instanceof SyncInfoValueControlGrammar )
+        if ( grammar instanceof SyncInfoValueGrammar )
         {
             return "SYNC_INFO_VALUE_GRAMMAR";
         }
@@ -137,7 +137,7 @@ public enum SyncInfoValueControlStatesEn
     /**
      * {@inheritDoc}
      */
-    public SyncInfoValueControlStatesEnum getStartState()
+    public SyncInfoValueStatesEnum getStartState()
     {
         return START_STATE;
     }

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueTags.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueTags.java?rev=1064988&r1=1064987&r2=1064988&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueTags.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncInfoValue/SyncInfoValueTags.java Sat Jan 29 09:45:18 2011
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.shared.ldap.codec.controls.replication.syncInfoValue;
 
+
 /**
  * An enumeration to store the tags used to encode and decode the syncInfoValue control.
  * 

Modified: directory/shared/trunk/ldap/src/test/java/org/apache/directory/shared/ldap/codec/controls/replication/SyncInfoValueControlTest.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/test/java/org/apache/directory/shared/ldap/codec/controls/replication/SyncInfoValueControlTest.java?rev=1064988&r1=1064987&r2=1064988&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/test/java/org/apache/directory/shared/ldap/codec/controls/replication/SyncInfoValueControlTest.java (original)
+++ directory/shared/trunk/ldap/src/test/java/org/apache/directory/shared/ldap/codec/controls/replication/SyncInfoValueControlTest.java Sat Jan 29 09:45:18 2011
@@ -31,8 +31,8 @@ import org.apache.directory.junit.tools.
 import org.apache.directory.shared.asn1.DecoderException;
 import org.apache.directory.shared.asn1.EncoderException;
 import org.apache.directory.shared.asn1.ber.Asn1Decoder;
-import org.apache.directory.shared.ldap.codec.controls.replication.syncInfoValue.SyncInfoValueControl;
-import org.apache.directory.shared.ldap.codec.controls.replication.syncInfoValue.SyncInfoValueControlContainer;
+import org.apache.directory.shared.ldap.codec.controls.replication.syncInfoValue.SyncInfoValueDecorator;
+import org.apache.directory.shared.ldap.codec.controls.replication.syncInfoValue.SyncInfoValueContainer;
 import org.apache.directory.shared.ldap.codec.controls.replication.syncInfoValue.SyncInfoValueControlDecoder;
 import org.apache.directory.shared.ldap.message.control.replication.SynchronizationInfoEnum;
 import org.apache.directory.shared.util.Strings;
@@ -66,8 +66,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.NEW_COOKIE ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.NEW_COOKIE ) );
 
         try
         {
@@ -79,7 +79,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.NEW_COOKIE, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         
@@ -125,8 +125,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.NEW_COOKIE ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.NEW_COOKIE ) );
         
         try
         {
@@ -138,7 +138,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.NEW_COOKIE, syncInfoValue.getType() );
         assertEquals( "", Strings.utf8ToString(syncInfoValue.getCookie()) );
         
@@ -189,8 +189,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_DELETE ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_DELETE ) );
         
         try
         {
@@ -202,7 +202,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.REFRESH_DELETE, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertTrue( syncInfoValue.isRefreshDone() );
@@ -253,8 +253,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_DELETE ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_DELETE ) );
 
         try
         {
@@ -266,7 +266,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.REFRESH_DELETE, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertFalse( syncInfoValue.isRefreshDone() );
@@ -317,8 +317,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_DELETE ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_DELETE ) );
 
         try
         {
@@ -330,7 +330,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.REFRESH_DELETE, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertTrue( syncInfoValue.isRefreshDone() );
@@ -380,8 +380,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_DELETE ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_DELETE ) );
 
         try
         {
@@ -393,7 +393,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.REFRESH_DELETE, syncInfoValue.getType() );
         assertEquals( "", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertFalse( syncInfoValue.isRefreshDone() );
@@ -441,8 +441,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_DELETE ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_DELETE ) );
 
         try
         {
@@ -454,7 +454,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.REFRESH_DELETE, syncInfoValue.getType() );
         assertEquals( "", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertTrue( syncInfoValue.isRefreshDone() );
@@ -506,8 +506,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_PRESENT ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_PRESENT ) );
 
         try
         {
@@ -519,7 +519,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.REFRESH_PRESENT, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertTrue( syncInfoValue.isRefreshDone() );
@@ -570,8 +570,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_PRESENT ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_PRESENT ) );
 
         try
         {
@@ -583,7 +583,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.REFRESH_PRESENT, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertFalse( syncInfoValue.isRefreshDone() );
@@ -634,8 +634,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_PRESENT ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_PRESENT ) );
 
         try
         {
@@ -647,7 +647,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.REFRESH_PRESENT, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertTrue( syncInfoValue.isRefreshDone() );
@@ -697,8 +697,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_PRESENT ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_PRESENT ) );
 
         try
         {
@@ -710,7 +710,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.REFRESH_PRESENT, syncInfoValue.getType() );
         assertEquals( "", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertFalse( syncInfoValue.isRefreshDone() );
@@ -758,8 +758,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.REFRESH_PRESENT ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.REFRESH_PRESENT ) );
 
         try
         {
@@ -771,7 +771,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
 
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.REFRESH_PRESENT, syncInfoValue.getType() );
         assertEquals( "", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertTrue( syncInfoValue.isRefreshDone() );
@@ -820,8 +820,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -852,8 +852,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -884,8 +884,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -917,8 +917,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -949,8 +949,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -962,7 +962,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
         
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.SYNC_ID_SET, syncInfoValue.getType() );
         assertEquals( "", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertFalse( syncInfoValue.isRefreshDeletes() );
@@ -1022,8 +1022,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -1034,7 +1034,7 @@ public class SyncInfoValueControlTest
             de.printStackTrace();
             fail( de.getMessage() );
         }
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.SYNC_ID_SET, syncInfoValue.getType() );
         assertEquals( "", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertFalse( syncInfoValue.isRefreshDeletes() );
@@ -1105,8 +1105,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -1117,7 +1117,7 @@ public class SyncInfoValueControlTest
             de.printStackTrace();
             fail( de.getMessage() );
         }
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.SYNC_ID_SET, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertFalse( syncInfoValue.isRefreshDeletes() );
@@ -1179,8 +1179,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -1192,7 +1192,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
         
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.SYNC_ID_SET, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertFalse( syncInfoValue.isRefreshDeletes() );
@@ -1264,8 +1264,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -1276,7 +1276,7 @@ public class SyncInfoValueControlTest
             de.printStackTrace();
             fail( de.getMessage() );
         }
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.SYNC_ID_SET, syncInfoValue.getType() );
         assertEquals( "", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertTrue( syncInfoValue.isRefreshDeletes() );
@@ -1338,8 +1338,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -1350,7 +1350,7 @@ public class SyncInfoValueControlTest
             de.printStackTrace();
             fail( de.getMessage() );
         }
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.SYNC_ID_SET, syncInfoValue.getType() );
         assertEquals( "", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertTrue( syncInfoValue.isRefreshDeletes() );
@@ -1423,8 +1423,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -1435,7 +1435,7 @@ public class SyncInfoValueControlTest
             de.printStackTrace();
             fail( de.getMessage() );
         }
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.SYNC_ID_SET, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertTrue( syncInfoValue.isRefreshDeletes() );
@@ -1499,8 +1499,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -1512,7 +1512,7 @@ public class SyncInfoValueControlTest
             fail( de.getMessage() );
         }
         
-        SyncInfoValueControl syncInfoValue = container.getSyncInfoValueControl();
+        SyncInfoValueDecorator syncInfoValue = container.getSyncInfoValueControl();
         assertEquals( SynchronizationInfoEnum.SYNC_ID_SET, syncInfoValue.getType() );
         assertEquals( "abc", Strings.utf8ToString(syncInfoValue.getCookie()) );
         assertTrue( syncInfoValue.isRefreshDeletes() );
@@ -1589,8 +1589,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {
@@ -1627,8 +1627,8 @@ public class SyncInfoValueControlTest
             } );
         bb.flip();
 
-        SyncInfoValueControlContainer container = new SyncInfoValueControlContainer();
-        container.setSyncInfoValueControl( new SyncInfoValueControl( SynchronizationInfoEnum.SYNC_ID_SET ) );
+        SyncInfoValueContainer container = new SyncInfoValueContainer();
+        container.setSyncInfoValueControl( new SyncInfoValueDecorator( SynchronizationInfoEnum.SYNC_ID_SET ) );
 
         try
         {



Mime
View raw message