You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by Alex Karasulu <ao...@bellsouth.net> on 2005/03/07 23:06:15 UTC

Re: svn commit: r155926 [2/2] - in incubator/directory/asn1/trunk: ber/src/java/org/apache/asn1/ber/ ber/src/java/org/apache/asn1/ber/digester/rules/ ber/src/test/org/apache/asn1/ber/ ber/src/test/org/apache/asn1/ber/digester/rules/ ber/xdocs/ codec/src/java/org/apache/asn1/codec/stateful/ xdocs/

Alan I don't see these diffs doing anything.  What was the point for 
these modifications?

Alex

adc@apache.org wrote:

>Modified: incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java
>URL: http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java?view=diff&r1=155925&r2=155926
>==============================================================================
>--- incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java (original)
>+++ incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java Wed Mar  2 07:14:39 2005
>@@ -1,5 +1,5 @@
> /*
>- *   Copyright 2004 The Apache Software Foundation
>+ *   Copyright 2004-2005 The Apache Software Foundation
>  *
>  *   Licensed under the Apache License, Version 2.0 (the "License");
>  *   you may not use this file except in compliance with the License.
>@@ -37,7 +37,7 @@
> {
>     public DefaultMutableTupleNodeTest()
>     {
>-        super ( DefaultMutableTupleNodeTest.class.getName() ) ; 
>+        super ( DefaultMutableTupleNodeTest.class.getName() ) ;
>     }
> 
> 
>@@ -85,7 +85,7 @@
>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>         parent.insert( (MutableTupleNode) node, 0 ) ;
>         node.setParent( (MutableTupleNode) parent) ;
>-        
>+
>         assertEquals(1,parent.getChildCount()) ;
>         node.removeFromParent() ;
>         assertEquals(0,parent.getChildCount()) ;
>@@ -147,7 +147,7 @@
>         assertTrue( parent.getChildren().hasNext()) ;
>     }
> 
>-    
>+
>     public void testGetChildTupleNodeAt()
>     {
>     }
>@@ -175,13 +175,13 @@
>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>         parent.insert( (MutableTupleNode) node, 0 ) ;
>         node.setParent( (MutableTupleNode) parent) ;
>-        
>+
>         Tuple primitive = new Tuple( 1, 3, true, TypeClass.APPLICATION ) ;
>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>         parent.setTuple( constructed ) ;
>         node.setTuple( primitive ) ;
>-        
>-        // fact that we use the indefinate form we automatically add two to
>+
>+        // fact that we use the indefinite form we automatically add two to
>         // the contained size
>         assertEquals(9, parent.size()) ;
>     }
>@@ -192,12 +192,12 @@
>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>         parent.insert( (MutableTupleNode) node, 0 ) ;
>         node.setParent( (MutableTupleNode) parent) ;
>-        
>+
>         Tuple primitive = new Tuple( 1, 3, true, TypeClass.APPLICATION ) ;
>         Tuple constructed = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>         parent.setTuple( constructed ) ;
>         node.setTuple( primitive ) ;
>-        
>+
>         assertEquals(7, parent.size()) ;
>     }
> 
>@@ -206,7 +206,7 @@
>         DefaultMutableTupleNode parent = new DefaultMutableTupleNode() ;
>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>         parent.setTuple( constructed ) ;
>-        
>+
>         assertEquals(4, parent.size()) ;
>     }
> 
>@@ -219,7 +219,7 @@
>         ByteBuffer buf = ByteBuffer.allocate( 4 ) ;
>         parent.encode( buf ) ;
> 
>-        
>+
>         /*
>         final ArrayList list = new ArrayList() ;
>         TupleTreeDecoder decoder = new TupleTreeDecoder() ;
>@@ -228,10 +228,10 @@
>             {
>                 list.add( arg1 ) ;
>             }}) ;
>-        
>+
>         decoder.decode(buf.flip()) ;
>-        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode ) 
>-            list.get(0); 
>+        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode )
>+            list.get(0);
>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>         */
>     }
>@@ -248,13 +248,13 @@
>     {
>         DefaultMutableTupleNode parent = new DefaultMutableTupleNode() ;
>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>-        
>+
>         DefaultMutableTupleNode end = new DefaultMutableTupleNode() ;
>         parent.insert( (MutableTupleNode) end, 0 ) ;
>         end.setParent( (MutableTupleNode) parent) ;
>         parent.insert( (MutableTupleNode) node, 0 ) ;
>         node.setParent( (MutableTupleNode) parent) ;
>-        
>+
>         Tuple primitive = new Tuple( 1, 3, true, TypeClass.APPLICATION ) ;
>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL ) ;
>@@ -262,9 +262,9 @@
>         parent.setTuple( constructed ) ;
>         node.setTuple( primitive ) ;
>         end.setTuple(terminator) ;
>-        
>+
>         assertEquals(9, parent.size()) ;
>-        
>+
>         ByteBuffer buf = ByteBuffer.allocate( 9 ) ;
>         parent.encode( buf ) ;
> 
>@@ -276,10 +276,10 @@
>             {
>                 list.add( arg1 ) ;
>             }}) ;
>-        
>+
>         decoder.decode(buf.flip()) ;
>-        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode ) 
>-            list.get(0); 
>+        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode )
>+            list.get(0);
>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>         */
>     }
>@@ -290,15 +290,15 @@
>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>         parent.insert( (MutableTupleNode) node, 0 ) ;
>         node.setParent( (MutableTupleNode) parent) ;
>-        
>+
>         Tuple primitive = new Tuple( 1, 3, true, TypeClass.APPLICATION ) ;
>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>         parent.setTuple( constructed ) ;
>         node.setTuple( primitive ) ;
>-        
>-        // 2 extra bytes added for indefinate form
>+
>+        // 2 extra bytes added for indefinite form
>         assertEquals(9, parent.size()) ;
>-        
>+
>         ByteBuffer buf = ByteBuffer.allocate( 9 ) ;
>         parent.encode( buf ) ;
> 
>@@ -310,10 +310,10 @@
>             {
>                 list.add( arg1 ) ;
>             }}) ;
>-        
>+
>         decoder.decode(buf.flip()) ;
>-        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode ) 
>-            list.get(0); 
>+        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode )
>+            list.get(0);
>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>         */
>     }
>@@ -327,18 +327,18 @@
>         middle.setParent( (MutableTupleNode) top) ;
>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>         bottom.setParent( (MutableTupleNode) middle) ;
>-        
>+
>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>         Tuple bottomTuple = new Tuple( 3, 1, true, TypeClass.APPLICATION ) ;
>-        
>+
>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>         top.setTuple( topTuple ) ;
>         middle.setTuple( middleTuple ) ;
>         bottom.setTuple( bottomTuple ) ;
>-        
>+
>         assertEquals(7, top.size()) ;
>-        
>+
>         ByteBuffer buf = ByteBuffer.allocate( 7 ) ;
>         top.encode( buf ) ;
> 
>@@ -350,15 +350,15 @@
>             {
>                 list.add( arg1 ) ;
>             }}) ;
>-        
>+
>         decoder.decode(buf.flip()) ;
>-        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode ) 
>-            list.get(0); 
>+        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode )
>+            list.get(0);
>         assertEquals( decoded.getTuple(), top.getTuple()) ;
>         */
>     }
> 
>-    
>+
>     public void testEquals()
>     {
>         DefaultMutableTupleNode top = new DefaultMutableTupleNode() ;
>@@ -368,18 +368,18 @@
>         middle.setParent( (MutableTupleNode) top) ;
>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>         bottom.setParent( (MutableTupleNode) middle) ;
>-        
>+
>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>         Tuple bottomTuple = new Tuple( 3, 1, true, TypeClass.APPLICATION ) ;
>-        
>+
>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>         top.setTuple( topTuple ) ;
>         middle.setTuple( middleTuple ) ;
>         bottom.setTuple( bottomTuple ) ;
> 
>         assertTrue( top.equals( top ) ) ;
>-        
>+
>         DefaultMutableTupleNode topClone = new DefaultMutableTupleNode() ;
>         topClone.setTuple( topTuple ) ;
>         assertFalse( top.equals(topClone)) ;
>@@ -387,7 +387,7 @@
>         topClone = new DefaultMutableTupleNode() ;
>         topClone.setTuple( bottomTuple ) ;
>         assertFalse( top.equals(topClone)) ;
>-        
>+
>         topClone = new DefaultMutableTupleNode() ;
>         DefaultMutableTupleNode middleClone = new DefaultMutableTupleNode() ;
>         DefaultMutableTupleNode bottomClone = new DefaultMutableTupleNode() ;
>@@ -395,11 +395,11 @@
>         middleClone.setParent( (MutableTupleNode) topClone) ;
>         middleClone.insert( (MutableTupleNode) bottomClone, 0 ) ;
>         bottomClone.setParent( (MutableTupleNode) middleClone) ;
>-        
>+
>         Tuple middleTupleClone = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>         Tuple topTupleClone = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>         Tuple bottomTupleClone= new Tuple( 3, 1, true, TypeClass.APPLICATION ) ;
>-        
>+
>         bottomTupleClone.typeClass = TypeClass.UNIVERSAL ;
>         topClone.setTuple( topTupleClone ) ;
>         middleClone.setTuple( middleTupleClone ) ;
>@@ -409,8 +409,8 @@
>         assertTrue( middle.equals( middleClone ) ) ;
>         assertTrue( top.equals( topClone ) ) ;
>      }
>-    
>-    
>+
>+
>     public void testEquals2()
>     {
>         DefaultMutableTupleNode top = new DefaultMutableTupleNode() ;
>@@ -420,11 +420,11 @@
>         middle.setParent( (MutableTupleNode) top) ;
>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>         bottom.setParent( (MutableTupleNode) middle) ;
>-        
>+
>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>         Tuple bottomTuple = new Tuple( 3, 1, true, TypeClass.APPLICATION ) ;
>-        
>+
>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>         top.setTuple( topTuple ) ;
>         middle.setTuple( middleTuple ) ;
>@@ -433,7 +433,7 @@
>         assertTrue( top.equals( top ) ) ;
> 
>         top.printDepthFirst(new StringBuffer(), 0 ) ;
>-        
>+
>         DefaultMutableTupleNode topClone = new DefaultMutableTupleNode() ;
>         topClone.setTuple( topTuple ) ;
>         assertFalse( top.equals(topClone)) ;
>@@ -441,7 +441,7 @@
>         topClone = new DefaultMutableTupleNode() ;
>         topClone.setTuple( bottomTuple ) ;
>         assertFalse( top.equals(topClone)) ;
>-        
>+
>         topClone = new DefaultMutableTupleNode() ;
>         DefaultMutableTupleNode middleClone = new DefaultMutableTupleNode() ;
>         DefaultMutableTupleNode bottomClone = new DefaultMutableTupleNode() ;
>@@ -449,11 +449,11 @@
>         middleClone.setParent( (MutableTupleNode) topClone) ;
>         middleClone.insert( (MutableTupleNode) bottomClone, 0 ) ;
>         bottomClone.setParent( (MutableTupleNode) middleClone) ;
>-        
>+
>         Tuple middleTupleClone = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>         Tuple topTupleClone = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>         Tuple bottomTupleClone= new Tuple( 3, 1, true, TypeClass.APPLICATION ) ;
>-        
>+
>         bottomTupleClone.typeClass = TypeClass.UNIVERSAL ;
>         topClone.setTuple( topTupleClone ) ;
>         middleClone.setTuple( bottomTupleClone ) ;
>@@ -465,8 +465,8 @@
>         assertFalse( top.equals( new Object() ) ) ;
>         assertFalse( top.equals( null ) ) ;
>      }
>-    
>-    
>+
>+
>     /*
>      * Class to test for String toString()
>      */
>@@ -479,7 +479,7 @@
>         end.setParent( parent) ;
>         parent.insert( node, 0 ) ;
>         node.setParent( parent) ;
>-        
>+
>         Tuple primitive = new Tuple( 1, 3, true, TypeClass.APPLICATION ) ;
>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL ) ;
>@@ -487,7 +487,7 @@
>         parent.setTuple( constructed ) ;
>         node.setTuple( primitive ) ;
>         end.setTuple( terminator ) ;
>-        
>+
>         assertNotNull( parent.toString() ) ;
>     }
> 
>@@ -500,7 +500,7 @@
>         end.setParent( parent) ;
>         parent.insert( node, 0 ) ;
>         node.setParent( parent) ;
>-        
>+
>         Tuple primitive = new Tuple( 1, 3, true, TypeClass.APPLICATION ) ;
>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL ) ;
>@@ -508,7 +508,7 @@
>         parent.setTuple( constructed ) ;
>         node.setTuple( primitive, Collections.EMPTY_LIST ) ;
>         end.setTuple( terminator ) ;
>-        
>+
>         assertTrue( node.getValueChunks().isEmpty() ) ;
> 
> 
>@@ -525,7 +525,7 @@
>         end.setParent( parent) ;
>         parent.insert( node, 0 ) ;
>         node.setParent( parent) ;
>-        
>+
>         Tuple primitive = new Tuple( 1, 3, true, TypeClass.APPLICATION ) ;
>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL ) ;
>@@ -533,18 +533,18 @@
>         parent.setTuple( constructed ) ;
>         node.setTuple( primitive ) ;
>         end.setTuple( terminator ) ;
>-        
>+
>         Iterator list = parent.getChildren() ;
>-        
>+
>         assertEquals( node, list.next() ) ;
>         assertEquals( end, list.next() ) ;
>-        
>+
>         try
>         {
>             list.next() ;
>             fail( "should never get here due to thrown exception" ) ;
>         }
>-        catch( Throwable t ) 
>+        catch( Throwable t )
>         {
>             assertNotNull( t ) ;
>         }
>@@ -559,7 +559,7 @@
>         end.setParent( parent) ;
>         parent.insert( node, 0 ) ;
>         node.setParent( parent) ;
>-        
>+
>         Tuple primitive = new Tuple( 1, 3, true, TypeClass.APPLICATION ) ;
>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL ) ;
>@@ -578,7 +578,7 @@
>         end.setParent( parent) ;
>         parent.addFront( node ) ;
>         node.setParent( parent) ;
>-        
>+
>         Tuple primitive = new Tuple( 1, 3, true, TypeClass.APPLICATION ) ;
>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL ) ;
>@@ -589,7 +589,7 @@
>         parent.toDepthFirstString() ;
>     }
> 
>-    
>+
>     public void testAddLast()
>     {
>         DefaultMutableTupleNode parent = new DefaultMutableTupleNode() ;
>@@ -599,7 +599,7 @@
>         node.setParent( (MutableTupleNode) parent) ;
>         parent.addLast( end ) ;
>         end.setParent( (MutableTupleNode) parent) ;
>-        
>+
>         Tuple primitive = new Tuple( 1, 3, true, TypeClass.APPLICATION ) ;
>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL ) ;
>
>Modified: incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java
>URL: http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java?view=diff&r1=155925&r2=155926
>==============================================================================
>--- incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java (original)
>+++ incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java Wed Mar  2 07:14:39 2005
>@@ -1,5 +1,5 @@
> /*
>- *   Copyright 2004 The Apache Software Foundation
>+ *   Copyright 2004-2005 The Apache Software Foundation
>  *
>  *   Licensed under the Apache License, Version 2.0 (the "License");
>  *   you may not use this file except in compliance with the License.
>@@ -142,14 +142,14 @@
>         assertEquals( 2, t.getId() ) ;
>         assertEquals( TypeClass.PRIVATE, t.getTypeClass() ) ;
>         assertEquals( false, t.isPrimitive() ) ;
>-        assertEquals( Length.INDEFINATE, t.getLength() ) ;
>+        assertEquals( Length.INDEFINITE, t.getLength() ) ;
>         assertEquals( EMPTY_BUFFER, t.getLastValueChunk() ) ;
> 
>         t = new Tuple( 2, (TypeClass) null ) ;
>         assertEquals( 2, t.getId() ) ;
>         assertEquals( TypeClass.APPLICATION, t.getTypeClass() ) ;
>         assertEquals( false, t.isPrimitive() ) ;
>-        assertEquals( Length.INDEFINATE, t.getLength() ) ;
>+        assertEquals( Length.INDEFINITE, t.getLength() ) ;
>         assertEquals( EMPTY_BUFFER, t.getLastValueChunk() ) ;
>     }
> 
>@@ -162,8 +162,8 @@
>         t.id = 21 ;
>         assertEquals( 21, t.getId() ) ;
>     }
>-    
>-    
>+
>+
>     public void testSize()
>     {
>         Tuple t = new Tuple( 1, TypeClass.APPLICATION ) ;
>@@ -178,7 +178,7 @@
>         assertEquals( 5, t.size() ) ;
>         t.id = 1 << 21 ;
>         assertEquals( 6, t.size() ) ;
>-        
>+
>         t.length = 127 ;
>         assertEquals( 6+127, t.size() ) ;
>         t.length = 128 ;
>@@ -188,28 +188,28 @@
>         t.length = 256 ;
>         assertEquals( 8+256, t.size() ) ;
>     }
>-    
>-    
>-    public void testIsIndefinate()
>+
>+
>+    public void testIsIndefinite()
>     {
>         Tuple t = new Tuple() ;
>-        assertFalse( t.isIndefinate() ) ;
>-        t.length = Length.INDEFINATE ;
>-        assertTrue( t.isIndefinate() ) ;
>+        assertFalse( t.isIndefinite() ) ;
>+        t.length = Length.INDEFINITE ;
>+        assertTrue( t.isIndefinite() ) ;
>     }
>-    
> 
>-    public void testIsIndefinateTerminator()
>+
>+    public void testIsIndefiniteTerminator()
>     {
>         Tuple t = new Tuple() ;
>-        assertFalse( t.isIndefinateTerminator() ) ;
>+        assertFalse( t.isIndefiniteTerminator() ) ;
>         t.id = 0 ;
>         t.length = 0 ;
>         t.isPrimitive = true ;
>         t.typeClass = TypeClass.UNIVERSAL ;
>-        assertTrue( t.isIndefinateTerminator() ) ;
>+        assertTrue( t.isIndefiniteTerminator() ) ;
>     }
>-    
>+
> 
>     public void testIsPrimitive()
>     {
>@@ -300,13 +300,13 @@
>         Tuple tnull1 = new Tuple() ;
>         tnull1.valueChunk = null ;
>         tnull0.equals( tnull1 ) ;
>-        
>+
>         tnull1.equals( tnull1 ) ;
>         tnull0.equals( tnull0 ) ;
>-        
>+
>         Tuple t0 = new Tuple() ;
>         Tuple t1 = ( Tuple ) t0.clone() ;
>-        
>+
>         assertTrue( t0.equals( t1 ) ) ;
>         t0.id = 23 ;
>         assertFalse( t0.equals( t1 ) ) ;
>@@ -346,10 +346,10 @@
> 
>         t0.valueChunk = ByteBuffer.allocate( 4 ) ;
>         t1.valueChunk = null ;
>-        
>+
>         // The buffer does not factor into equality
>         assertTrue( t0.equals( t1 ) ) ;
>-        
>+
>         t1 = ( Tuple ) t0.clone() ;
>         assertTrue( t0.equals( t1 ) ) ;
> 
>@@ -567,13 +567,13 @@
>                 , toAsciiString( encoded ) ) ;
>     }
> 
>-    
>+
>     public String toAsciiString( ByteBuffer buf )
>     {
>         return BinaryCodec.toAsciiString( buf.array() ) ;
>     }
>-    
>-    
>+
>+
>     public void testSetTagBufferint()
>     {
>         ByteBuffer bites = ByteBuffer.allocate( 1 ) ;
>@@ -581,7 +581,7 @@
>         t.setTag( bites, 1 ) ;
>         String binary = toAsciiString( bites ) ;
>         assertEquals( "01100000", binary ) ;
>-        
>+
>         bites = ByteBuffer.allocate( 1 ) ;
>         t = new Tuple( 30, 0 ) ;
>         t.setTag( bites, 1 ) ;
>@@ -617,8 +617,8 @@
>         t = new Tuple( BIT_13 - 1, 0 ) ;
>         t.setTag( bites, 3 ) ;
>         binary = toAsciiString( bites ) ;
>-        assertEquals( "01111111" + 
>-                      "11111111" + 
>+        assertEquals( "01111111" +
>+                      "11111111" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 4 ) ;
>@@ -627,7 +627,7 @@
>         binary = toAsciiString( bites ) ;
>         assertEquals( "00000000" +
>                       "10000000" +
>-                      "10000001" + 
>+                      "10000001" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 4 ) ;
>@@ -636,16 +636,16 @@
>         binary = toAsciiString( bites ) ;
>         assertEquals( "00000001" +
>                       "10000000" +
>-                      "10000001" + 
>+                      "10000001" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 4 ) ;
>         t = new Tuple( BIT_20 - 1, 0 ) ;
>         t.setTag( bites, 4 ) ;
>         binary = toAsciiString( bites ) ;
>-        assertEquals( "01111111" + 
>-                      "11111111" + 
>-                      "11111111" + 
>+        assertEquals( "01111111" +
>+                      "11111111" +
>+                      "11111111" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 5 ) ;
>@@ -655,7 +655,7 @@
>         assertEquals( "00000000" +
>                       "10000000" +
>                       "10000000" +
>-                      "10000001" + 
>+                      "10000001" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 5 ) ;
>@@ -665,22 +665,22 @@
>         assertEquals( "00000001" +
>                       "10000000" +
>                       "10000000" +
>-                      "10000001" + 
>+                      "10000001" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 5 ) ;
>         t = new Tuple( BIT_27 - 1, 0 ) ;
>         t.setTag( bites, 5 ) ;
>         binary = toAsciiString( bites ) ;
>-        assertEquals( "01111111" + 
>-                      "11111111" + 
>-                      "11111111" + 
>-                      "11111111" + 
>+        assertEquals( "01111111" +
>+                      "11111111" +
>+                      "11111111" +
>+                      "11111111" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 6 ) ;
>         t = new Tuple( BIT_27, 0 ) ;
>-        
>+
>         try
>         {
>             t.setTag( bites, 6 ) ;
>@@ -699,7 +699,7 @@
>         t.setTag( bites, 1 ) ;
>         String binary = toAsciiString( bites ) ;
>         assertEquals( "01100000", binary ) ;
>-        
>+
>         bites = ByteBuffer.allocate( 1 ) ;
>         t = new Tuple( 30, 0 ) ;
>         t.setTag( bites, 1 ) ;
>@@ -735,8 +735,8 @@
>         t = new Tuple( BIT_13 - 1, 0 ) ;
>         t.setTag( bites, 3 ) ;
>         binary = toAsciiString( bites ) ;
>-        assertEquals( "01111111" + 
>-                      "11111111" + 
>+        assertEquals( "01111111" +
>+                      "11111111" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 4 ) ;
>@@ -745,7 +745,7 @@
>         binary = toAsciiString( bites ) ;
>         assertEquals( "00000000" +
>                       "10000000" +
>-                      "10000001" + 
>+                      "10000001" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 4 ) ;
>@@ -754,16 +754,16 @@
>         binary = toAsciiString( bites ) ;
>         assertEquals( "00000001" +
>                       "10000000" +
>-                      "10000001" + 
>+                      "10000001" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 4 ) ;
>         t = new Tuple( BIT_20 - 1, 0 ) ;
>         t.setTag( bites, 4 ) ;
>         binary = toAsciiString( bites ) ;
>-        assertEquals( "01111111" + 
>-                      "11111111" + 
>-                      "11111111" + 
>+        assertEquals( "01111111" +
>+                      "11111111" +
>+                      "11111111" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 5 ) ;
>@@ -773,7 +773,7 @@
>         assertEquals( "00000000" +
>                       "10000000" +
>                       "10000000" +
>-                      "10000001" + 
>+                      "10000001" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 5 ) ;
>@@ -783,22 +783,22 @@
>         assertEquals( "00000001" +
>                       "10000000" +
>                       "10000000" +
>-                      "10000001" + 
>+                      "10000001" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 5 ) ;
>         t = new Tuple( BIT_27 - 1, 0 ) ;
>         t.setTag( bites, 5 ) ;
>         binary = toAsciiString( bites ) ;
>-        assertEquals( "01111111" + 
>-                      "11111111" + 
>-                      "11111111" + 
>-                      "11111111" + 
>+        assertEquals( "01111111" +
>+                      "11111111" +
>+                      "11111111" +
>+                      "11111111" +
>                       "01111111", binary ) ;
> 
>         bites = ByteBuffer.allocate( 6 ) ;
>         t = new Tuple( BIT_27, 0 ) ;
>-        
>+
>         try
>         {
>             t.setTag( bites, 6 ) ;
>@@ -809,8 +809,8 @@
>             assertNotNull( e ) ;
>         }
>     }
>-    
>-    
>+
>+
>     String toAsciiString( int raw )
>     {
>         byte[] intBytes = new byte[4] ;
>@@ -818,10 +818,10 @@
>         intBytes[1] = (byte) ( (int) ( 0x0000ff00 & raw ) >> 8 ) ;
>         intBytes[2] = (byte) ( (int) ( 0x00ff0000 & raw ) >> 16 ) ;
>         intBytes[3] = (byte) ( (int) ( 0xff000000 & raw ) >> 24 ) ;
>-        
>+
>         return BinaryCodec.toAsciiString( intBytes ) ;
>     }
>-    
>+
> 
>     public void testSetLengthBuffer()
>     {
>@@ -1064,7 +1064,7 @@
>         assertEquals( 4, t.getTagLength() ) ;
>         t.id = BIT_13 + 100 ;
>         assertEquals( 4, t.getTagLength() ) ;
>-        
>+
>         t.id = BIT_20 - 1 ;
>         assertEquals( 4, t.getTagLength() ) ;
>         t.id = BIT_20 ;
>@@ -1076,7 +1076,7 @@
>         assertEquals( 5, t.getTagLength() ) ;
> 
>         t.id = BIT_27 ;
>-        
>+
>         try
>         {
>             assertEquals( 6, t.getTagLength() ) ;
>@@ -1107,7 +1107,7 @@
>         assertEquals( 4, t.getLengthLength() ) ;
>         t.length = BIT_15 + 100 ;
>         assertEquals( 4, t.getLengthLength() ) ;
>-        
>+
>         t.length = BIT_23 - 1 ;
>         assertEquals( 4, t.getLengthLength() ) ;
>         t.length = BIT_23 ;
>@@ -1118,7 +1118,7 @@
>         t.length = Integer.MAX_VALUE ;
>         assertEquals( 5, t.getLengthLength() ) ;
> 
>-        
>+
>         t.length = Integer.MAX_VALUE + 1 ;
>         try
>         {
>@@ -1129,6 +1129,6 @@
>         {
>             assertNotNull( e ) ;
>         }
>-        
>+
>     }
> }
>
>Modified: incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java
>URL: http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java?view=diff&r1=155925&r2=155926
>==============================================================================
>--- incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java (original)
>+++ incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java Wed Mar  2 07:14:39 2005
>@@ -1,5 +1,5 @@
> /*
>- *   Copyright 2004 The Apache Software Foundation
>+ *   Copyright 2004-2005 The Apache Software Foundation
>  *
>  *   Licensed under the Apache License, Version 2.0 (the "License");
>  *   you may not use this file except in compliance with the License.
>@@ -99,12 +99,12 @@
> 
> 
>     /**
>-     * Tests when the length is indefinate.
>+     * Tests when the length is indefinite.
>      */
>-    public void testIndefinateLength()
>+    public void testIndefiniteLength()
>     {
>         rule.tag( UniversalTag.OCTET_STRING.getTagId(), true, null ) ;
>-        rule.length( Length.INDEFINATE ) ;
>+        rule.length( Length.INDEFINITE ) ;
>         rule.finish() ;
>         ByteBuffer buf = ( ByteBuffer ) digester.pop() ;
>         assertFalse( buf.hasRemaining() ) ;
>@@ -112,12 +112,12 @@
> 
> 
>     /**
>-     * Tests when the length is indefinate.
>+     * Tests when the length is indefinite.
>      */
>     public void testNullValue()
>     {
>         rule.tag( UniversalTag.OCTET_STRING.getTagId(), true, null ) ;
>-        rule.length( Length.INDEFINATE ) ;
>+        rule.length( Length.INDEFINITE ) ;
>         rule.value( null ) ;
>         rule.value( ByteBuffer.allocate( 0 ) ) ;
>         rule.finish() ;
>
>Modified: incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml
>URL: http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml?view=diff&r1=155925&r2=155926
>==============================================================================
>--- incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml (original)
>+++ incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml Wed Mar  2 07:14:39 2005
>@@ -22,7 +22,7 @@
>         <p>
>           A constructed TLV tuple contains other TLV tuples nested within the
>           Value field, and so on, recursively.  The nesting depth is usually
>-          indefinate and dependent on the data structures being transformed.
>+          indefinite and dependent on the data structures being transformed.
>           This fact drastically affects the way the decoder is designed and
>           hence operates.
>         </p>
>@@ -61,7 +61,7 @@
> 
>         <p>
>           Now let's try to figure out how to handle constructed TLV tuples
>-          which recursively nest other tuples indefinately.  State now
>+          which recursively nest other tuples indefinitely.  State now
>           is more that just where you left off in the current tuple being
>           processed.  When processing an inner tuple the decoder must also know
>           where it left off in the outter tuple to resume processing.  More
>
>Modified: incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java
>URL: http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java?view=diff&r1=155925&r2=155926
>==============================================================================
>--- incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java (original)
>+++ incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java Wed Mar  2 07:14:39 2005
>@@ -1,5 +1,5 @@
> /*
>- *   Copyright 2004 The Apache Software Foundation
>+ *   Copyright 2004-2005 The Apache Software Foundation
>  *
>  *   Licensed under the Apache License, Version 2.0 (the "License");
>  *   you may not use this file except in compliance with the License.
>@@ -36,33 +36,33 @@
>     private final LinkedList history ;
>     /** the length of callback history stored */
>     private final int length ;
>-    
>+
> 
>     /**
>-     * Creates an auditing callback that manages a history of indefinate length.
>+     * Creates an auditing callback that manages a history of indefinite length.
>      */
>     public CallbackHistory()
>     {
>         this( -1 ) ;
>     }
>-    
>-    
>+
>+
>     /**
>-     * Creates an auditing callback that manages a history of fixed or 
>-     * indefinate length.  If the length is fixed the history effectively 
>+     * Creates an auditing callback that manages a history of fixed or
>+     * indefinite length.  If the length is fixed the history effectively
>      * becomes a FIFO structure.
>-     * 
>+     *
>      * @param length the maximum length of callback history to store before
>-     *  dropping decoded items, a length of zero or 1 corresponds to indefinate
>-     *  history 
>+     *  dropping decoded items, a length of zero or 1 corresponds to indefinite
>+     *  history
>      */
>     public CallbackHistory( int length )
>     {
>         this.length = length ;
>         history = new LinkedList() ;
>     }
>-    
>-    
>+
>+
>     /* (non-Javadoc)
>      * @see org.apache.asn1.codec.stateful.DecoderCallback#decodeOccurred(
>      * org.apache.asn1.codec.stateful.StatefulDecoder, java.lang.Object)
>@@ -70,13 +70,13 @@
>     public void decodeOccurred( StatefulDecoder decoder, Object decoded )
>     {
>         if ( length > 0 )
>-        {    
>+        {
>             while ( history.size() >= length )
>             {
>                 history.removeLast() ;
>             }
>         }
>-        
>+
>         history.addFirst( decoded ) ;
>     }
> 
>@@ -103,7 +103,7 @@
> 
>     /**
>      * Gets the most recent decoded object if one exists.
>-     * 
>+     *
>      * @return the most recent decoded object
>      * @throws java.util.NoSuchElementException if the history is empty
>      */
>@@ -111,11 +111,11 @@
>     {
>         return history.getFirst() ;
>     }
>-    
>-    
>+
>+
>     /**
>      * Gets the oldest decoded object if one exists.
>-     * 
>+     *
>      * @return the oldest decoded object
>      * @throws java.util.NoSuchElementException if the history is empty
>      */
>@@ -123,19 +123,19 @@
>     {
>         return history.getLast() ;
>     }
>-    
>-    
>+
>+
>     /**
>      * Tests to see if the history is empty.
>-     * 
>+     *
>      * @return true if the history is empty, false otherwise
>      */
>     public boolean isEmpty()
>     {
>         return history.isEmpty() ;
>     }
>-    
>-    
>+
>+
>     /**
>      * Clears the history of decoded items.
>      */
>@@ -143,11 +143,11 @@
>     {
>         history.clear() ;
>     }
>-    
>-    
>+
>+
>     /**
>      * Gets the number of decoded items in the callback history.
>-     * 
>+     *
>      * @return the number of decoded items in the callback history
>      */
>     public int size()
>
>Modified: incubator/directory/asn1/trunk/xdocs/refactor.xml
>URL: http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/xdocs/refactor.xml?view=diff&r1=155925&r2=155926
>==============================================================================
>--- incubator/directory/asn1/trunk/xdocs/refactor.xml (original)
>+++ incubator/directory/asn1/trunk/xdocs/refactor.xml Wed Mar  2 07:14:39 2005
>@@ -166,7 +166,7 @@
>           are still abstract.  This is because we need to differentiate further
>           for buffered verses streamed Tuples in the case of primitive Tuples.
>           For constructed Tuples we need to differentiate between definate
>-          length verses indefinate length Tuples.  With our approach, only the 
>+          length verses indefinite length Tuples.  With our approach, only the 
>           leaf nodes of the inheritance hierarchy will be concrete.  Below is
>           the definition for the PrimitiveTuple.
>         </p>
>@@ -251,10 +251,10 @@
> 
>     /**
>      * Gets whether or not the length of this constructed Tuple is of the 
>-     * definate form or of the indefinate length form.
>+     * definate form or of the indefinite length form.
>      *
>      * @return true if the length is definate, false if the length is of the
>-     * indefinate form
>+     * indefinite form
>      */
>     public abstract boolean isLengthDefinate();
> }
>@@ -264,21 +264,21 @@
>           ConstructedTuple implements the <code>isConstructed()</code> method 
>           as final since it will always return false for this lineage of 
>           Tuples.  Also a new abstract method isLengthDefinate() is introduced 
>-          to see if the Tuple uses the indefinate length form or not.  
>+          to see if the Tuple uses the indefinite length form or not.  
>         </p>
>       </subsection>
> 
>-      <subsection name="Definate Vs. Indefinate Length">
>+      <subsection name="Definate Vs. Indefinite Length">
>         <p>
>           The ConstructedTuple can be further differentiated into two 
>-          subclasses to represent definate and indefinate length constructed 
>-          TLV Tuples.  The indefinate form does not have a length value 
>+          subclasses to represent definate and indefinite length constructed 
>+          TLV Tuples.  The indefinite form does not have a length value 
>           associated with it where as the definate lenght form does.  Let's
>-          explore the concrete IndefinateLegthTuple definition.
>+          explore the concrete IndefiniteLegthTuple definition.
>         </p>
> 
> <source>
>-public class IndefinateLength extends ConstructedTuple
>+public class IndefiniteLength extends ConstructedTuple
> {
>     public final boolean isLengthDefinate()
>     {
>
>
>
>  
>


Re: svn commit: r155926 [2/2] - in incubator/directory/asn1/trunk: ber/src/java/org/apache/asn1/ber/ ber/src/java/org/apache/asn1/ber/digester/rules/ ber/src/test/org/apache/asn1/ber/ ber/src/test/org/apache/asn1/ber/digester/rules/ ber/xdocs/ codec/src/java/org/apache/asn1/codec/stateful/ xdocs/

Posted by "Alan D. Cabrera" <ad...@toolazydogs.com>.
Because I didn't realize that it was cleaning out the extraneous spaces?

Alex Karasulu wrote:

> How come your log message did not say this?
>
> Alan D. Cabrera wrote:
>
>> The word indefinite was misspelled  If you look carefully, you'll see 
>> that each file has it corrected.  It seems that my editor removed the 
>> extra spaces on the end of some lines.
>>
>>
>> Regards,
>> Alan
>>
>> Alex Karasulu wrote:
>>
>>> Alan I don't see these diffs doing anything.  What was the point for 
>>> these modifications?
>>>
>>> Alex
>>>
>>> adc@apache.org wrote:
>>>
>>>> Modified: 
>>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java 
>>>>
>>>> URL: 
>>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java?view=diff&r1=155925&r2=155926 
>>>>
>>>> ============================================================================== 
>>>>
>>>> --- 
>>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java 
>>>> (original)
>>>> +++ 
>>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java 
>>>> Wed Mar  2 07:14:39 2005
>>>> @@ -1,5 +1,5 @@
>>>> /*
>>>> - *   Copyright 2004 The Apache Software Foundation
>>>> + *   Copyright 2004-2005 The Apache Software Foundation
>>>>  *
>>>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>>>  *   you may not use this file except in compliance with the License.
>>>> @@ -37,7 +37,7 @@
>>>> {
>>>>     public DefaultMutableTupleNodeTest()
>>>>     {
>>>> -        super ( DefaultMutableTupleNodeTest.class.getName() ) ; 
>>>> +        super ( DefaultMutableTupleNodeTest.class.getName() ) ;
>>>>     }
>>>>
>>>>
>>>> @@ -85,7 +85,7 @@
>>>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>>>         node.setParent( (MutableTupleNode) parent) ;
>>>> -        +
>>>>         assertEquals(1,parent.getChildCount()) ;
>>>>         node.removeFromParent() ;
>>>>         assertEquals(0,parent.getChildCount()) ;
>>>> @@ -147,7 +147,7 @@
>>>>         assertTrue( parent.getChildren().hasNext()) ;
>>>>     }
>>>>
>>>> -    +
>>>>     public void testGetChildTupleNodeAt()
>>>>     {
>>>>     }
>>>> @@ -175,13 +175,13 @@
>>>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>>>         node.setParent( (MutableTupleNode) parent) ;
>>>> -        +
>>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>>         parent.setTuple( constructed ) ;
>>>>         node.setTuple( primitive ) ;
>>>> -        -        // fact that we use the indefinate form we 
>>>> automatically add two to
>>>> +
>>>> +        // fact that we use the indefinite form we automatically 
>>>> add two to
>>>>         // the contained size
>>>>         assertEquals(9, parent.size()) ;
>>>>     }
>>>> @@ -192,12 +192,12 @@
>>>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>>>         node.setParent( (MutableTupleNode) parent) ;
>>>> -        +
>>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple constructed = new Tuple ( 2, 5, TypeClass.APPLICATION 
>>>> ) ;
>>>>         parent.setTuple( constructed ) ;
>>>>         node.setTuple( primitive ) ;
>>>> -        +
>>>>         assertEquals(7, parent.size()) ;
>>>>     }
>>>>
>>>> @@ -206,7 +206,7 @@
>>>>         DefaultMutableTupleNode parent = new 
>>>> DefaultMutableTupleNode() ;
>>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>>         parent.setTuple( constructed ) ;
>>>> -        +
>>>>         assertEquals(4, parent.size()) ;
>>>>     }
>>>>
>>>> @@ -219,7 +219,7 @@
>>>>         ByteBuffer buf = ByteBuffer.allocate( 4 ) ;
>>>>         parent.encode( buf ) ;
>>>>
>>>> -        +
>>>>         /*
>>>>         final ArrayList list = new ArrayList() ;
>>>>         TupleTreeDecoder decoder = new TupleTreeDecoder() ;
>>>> @@ -228,10 +228,10 @@
>>>>             {
>>>>                 list.add( arg1 ) ;
>>>>             }}) ;
>>>> -        +
>>>>         decoder.decode(buf.flip()) ;
>>>> -        DefaultMutableTupleNode decoded = ( 
>>>> DefaultMutableTupleNode ) -            list.get(0); +        
>>>> DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode )
>>>> +            list.get(0);
>>>>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>>>>         */
>>>>     }
>>>> @@ -248,13 +248,13 @@
>>>>     {
>>>>         DefaultMutableTupleNode parent = new 
>>>> DefaultMutableTupleNode() ;
>>>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>>> -        +
>>>>         DefaultMutableTupleNode end = new DefaultMutableTupleNode() ;
>>>>         parent.insert( (MutableTupleNode) end, 0 ) ;
>>>>         end.setParent( (MutableTupleNode) parent) ;
>>>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>>>         node.setParent( (MutableTupleNode) parent) ;
>>>> -        +
>>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>>> TypeClass.UNIVERSAL ) ;
>>>> @@ -262,9 +262,9 @@
>>>>         parent.setTuple( constructed ) ;
>>>>         node.setTuple( primitive ) ;
>>>>         end.setTuple(terminator) ;
>>>> -        +
>>>>         assertEquals(9, parent.size()) ;
>>>> -        +
>>>>         ByteBuffer buf = ByteBuffer.allocate( 9 ) ;
>>>>         parent.encode( buf ) ;
>>>>
>>>> @@ -276,10 +276,10 @@
>>>>             {
>>>>                 list.add( arg1 ) ;
>>>>             }}) ;
>>>> -        +
>>>>         decoder.decode(buf.flip()) ;
>>>> -        DefaultMutableTupleNode decoded = ( 
>>>> DefaultMutableTupleNode ) -            list.get(0); +        
>>>> DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode )
>>>> +            list.get(0);
>>>>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>>>>         */
>>>>     }
>>>> @@ -290,15 +290,15 @@
>>>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>>>         node.setParent( (MutableTupleNode) parent) ;
>>>> -        +
>>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>>         parent.setTuple( constructed ) ;
>>>>         node.setTuple( primitive ) ;
>>>> -        -        // 2 extra bytes added for indefinate form
>>>> +
>>>> +        // 2 extra bytes added for indefinite form
>>>>         assertEquals(9, parent.size()) ;
>>>> -        +
>>>>         ByteBuffer buf = ByteBuffer.allocate( 9 ) ;
>>>>         parent.encode( buf ) ;
>>>>
>>>> @@ -310,10 +310,10 @@
>>>>             {
>>>>                 list.add( arg1 ) ;
>>>>             }}) ;
>>>> -        +
>>>>         decoder.decode(buf.flip()) ;
>>>> -        DefaultMutableTupleNode decoded = ( 
>>>> DefaultMutableTupleNode ) -            list.get(0); +        
>>>> DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode )
>>>> +            list.get(0);
>>>>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>>>>         */
>>>>     }
>>>> @@ -327,18 +327,18 @@
>>>>         middle.setParent( (MutableTupleNode) top) ;
>>>>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>>>>         bottom.setParent( (MutableTupleNode) middle) ;
>>>> -        +
>>>>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  
>>>> ) ;
>>>>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>>>         Tuple bottomTuple = new Tuple( 3, 1, true, 
>>>> TypeClass.APPLICATION ) ;
>>>> -        +
>>>>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>>>>         top.setTuple( topTuple ) ;
>>>>         middle.setTuple( middleTuple ) ;
>>>>         bottom.setTuple( bottomTuple ) ;
>>>> -        +
>>>>         assertEquals(7, top.size()) ;
>>>> -        +
>>>>         ByteBuffer buf = ByteBuffer.allocate( 7 ) ;
>>>>         top.encode( buf ) ;
>>>>
>>>> @@ -350,15 +350,15 @@
>>>>             {
>>>>                 list.add( arg1 ) ;
>>>>             }}) ;
>>>> -        +
>>>>         decoder.decode(buf.flip()) ;
>>>> -        DefaultMutableTupleNode decoded = ( 
>>>> DefaultMutableTupleNode ) -            list.get(0); +        
>>>> DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode )
>>>> +            list.get(0);
>>>>         assertEquals( decoded.getTuple(), top.getTuple()) ;
>>>>         */
>>>>     }
>>>>
>>>> -    +
>>>>     public void testEquals()
>>>>     {
>>>>         DefaultMutableTupleNode top = new DefaultMutableTupleNode() ;
>>>> @@ -368,18 +368,18 @@
>>>>         middle.setParent( (MutableTupleNode) top) ;
>>>>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>>>>         bottom.setParent( (MutableTupleNode) middle) ;
>>>> -        +
>>>>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  
>>>> ) ;
>>>>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>>>         Tuple bottomTuple = new Tuple( 3, 1, true, 
>>>> TypeClass.APPLICATION ) ;
>>>> -        +
>>>>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>>>>         top.setTuple( topTuple ) ;
>>>>         middle.setTuple( middleTuple ) ;
>>>>         bottom.setTuple( bottomTuple ) ;
>>>>
>>>>         assertTrue( top.equals( top ) ) ;
>>>> -        +
>>>>         DefaultMutableTupleNode topClone = new 
>>>> DefaultMutableTupleNode() ;
>>>>         topClone.setTuple( topTuple ) ;
>>>>         assertFalse( top.equals(topClone)) ;
>>>> @@ -387,7 +387,7 @@
>>>>         topClone = new DefaultMutableTupleNode() ;
>>>>         topClone.setTuple( bottomTuple ) ;
>>>>         assertFalse( top.equals(topClone)) ;
>>>> -        +
>>>>         topClone = new DefaultMutableTupleNode() ;
>>>>         DefaultMutableTupleNode middleClone = new 
>>>> DefaultMutableTupleNode() ;
>>>>         DefaultMutableTupleNode bottomClone = new 
>>>> DefaultMutableTupleNode() ;
>>>> @@ -395,11 +395,11 @@
>>>>         middleClone.setParent( (MutableTupleNode) topClone) ;
>>>>         middleClone.insert( (MutableTupleNode) bottomClone, 0 ) ;
>>>>         bottomClone.setParent( (MutableTupleNode) middleClone) ;
>>>> -        +
>>>>         Tuple middleTupleClone = new Tuple( 1, 3, 
>>>> TypeClass.APPLICATION  ) ;
>>>>         Tuple topTupleClone = new Tuple ( 2, 5, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple bottomTupleClone= new Tuple( 3, 1, true, 
>>>> TypeClass.APPLICATION ) ;
>>>> -        +
>>>>         bottomTupleClone.typeClass = TypeClass.UNIVERSAL ;
>>>>         topClone.setTuple( topTupleClone ) ;
>>>>         middleClone.setTuple( middleTupleClone ) ;
>>>> @@ -409,8 +409,8 @@
>>>>         assertTrue( middle.equals( middleClone ) ) ;
>>>>         assertTrue( top.equals( topClone ) ) ;
>>>>      }
>>>> -    -    +
>>>> +
>>>>     public void testEquals2()
>>>>     {
>>>>         DefaultMutableTupleNode top = new DefaultMutableTupleNode() ;
>>>> @@ -420,11 +420,11 @@
>>>>         middle.setParent( (MutableTupleNode) top) ;
>>>>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>>>>         bottom.setParent( (MutableTupleNode) middle) ;
>>>> -        +
>>>>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  
>>>> ) ;
>>>>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>>>         Tuple bottomTuple = new Tuple( 3, 1, true, 
>>>> TypeClass.APPLICATION ) ;
>>>> -        +
>>>>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>>>>         top.setTuple( topTuple ) ;
>>>>         middle.setTuple( middleTuple ) ;
>>>> @@ -433,7 +433,7 @@
>>>>         assertTrue( top.equals( top ) ) ;
>>>>
>>>>         top.printDepthFirst(new StringBuffer(), 0 ) ;
>>>> -        +
>>>>         DefaultMutableTupleNode topClone = new 
>>>> DefaultMutableTupleNode() ;
>>>>         topClone.setTuple( topTuple ) ;
>>>>         assertFalse( top.equals(topClone)) ;
>>>> @@ -441,7 +441,7 @@
>>>>         topClone = new DefaultMutableTupleNode() ;
>>>>         topClone.setTuple( bottomTuple ) ;
>>>>         assertFalse( top.equals(topClone)) ;
>>>> -        +
>>>>         topClone = new DefaultMutableTupleNode() ;
>>>>         DefaultMutableTupleNode middleClone = new 
>>>> DefaultMutableTupleNode() ;
>>>>         DefaultMutableTupleNode bottomClone = new 
>>>> DefaultMutableTupleNode() ;
>>>> @@ -449,11 +449,11 @@
>>>>         middleClone.setParent( (MutableTupleNode) topClone) ;
>>>>         middleClone.insert( (MutableTupleNode) bottomClone, 0 ) ;
>>>>         bottomClone.setParent( (MutableTupleNode) middleClone) ;
>>>> -        +
>>>>         Tuple middleTupleClone = new Tuple( 1, 3, 
>>>> TypeClass.APPLICATION  ) ;
>>>>         Tuple topTupleClone = new Tuple ( 2, 5, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple bottomTupleClone= new Tuple( 3, 1, true, 
>>>> TypeClass.APPLICATION ) ;
>>>> -        +
>>>>         bottomTupleClone.typeClass = TypeClass.UNIVERSAL ;
>>>>         topClone.setTuple( topTupleClone ) ;
>>>>         middleClone.setTuple( bottomTupleClone ) ;
>>>> @@ -465,8 +465,8 @@
>>>>         assertFalse( top.equals( new Object() ) ) ;
>>>>         assertFalse( top.equals( null ) ) ;
>>>>      }
>>>> -    -    +
>>>> +
>>>>     /*
>>>>      * Class to test for String toString()
>>>>      */
>>>> @@ -479,7 +479,7 @@
>>>>         end.setParent( parent) ;
>>>>         parent.insert( node, 0 ) ;
>>>>         node.setParent( parent) ;
>>>> -        +
>>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>>> TypeClass.UNIVERSAL ) ;
>>>> @@ -487,7 +487,7 @@
>>>>         parent.setTuple( constructed ) ;
>>>>         node.setTuple( primitive ) ;
>>>>         end.setTuple( terminator ) ;
>>>> -        +
>>>>         assertNotNull( parent.toString() ) ;
>>>>     }
>>>>
>>>> @@ -500,7 +500,7 @@
>>>>         end.setParent( parent) ;
>>>>         parent.insert( node, 0 ) ;
>>>>         node.setParent( parent) ;
>>>> -        +
>>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>>> TypeClass.UNIVERSAL ) ;
>>>> @@ -508,7 +508,7 @@
>>>>         parent.setTuple( constructed ) ;
>>>>         node.setTuple( primitive, Collections.EMPTY_LIST ) ;
>>>>         end.setTuple( terminator ) ;
>>>> -        +
>>>>         assertTrue( node.getValueChunks().isEmpty() ) ;
>>>>
>>>>
>>>> @@ -525,7 +525,7 @@
>>>>         end.setParent( parent) ;
>>>>         parent.insert( node, 0 ) ;
>>>>         node.setParent( parent) ;
>>>> -        +
>>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>>> TypeClass.UNIVERSAL ) ;
>>>> @@ -533,18 +533,18 @@
>>>>         parent.setTuple( constructed ) ;
>>>>         node.setTuple( primitive ) ;
>>>>         end.setTuple( terminator ) ;
>>>> -        +
>>>>         Iterator list = parent.getChildren() ;
>>>> -        +
>>>>         assertEquals( node, list.next() ) ;
>>>>         assertEquals( end, list.next() ) ;
>>>> -        +
>>>>         try
>>>>         {
>>>>             list.next() ;
>>>>             fail( "should never get here due to thrown exception" ) ;
>>>>         }
>>>> -        catch( Throwable t ) +        catch( Throwable t )
>>>>         {
>>>>             assertNotNull( t ) ;
>>>>         }
>>>> @@ -559,7 +559,7 @@
>>>>         end.setParent( parent) ;
>>>>         parent.insert( node, 0 ) ;
>>>>         node.setParent( parent) ;
>>>> -        +
>>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>>> TypeClass.UNIVERSAL ) ;
>>>> @@ -578,7 +578,7 @@
>>>>         end.setParent( parent) ;
>>>>         parent.addFront( node ) ;
>>>>         node.setParent( parent) ;
>>>> -        +
>>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>>> TypeClass.UNIVERSAL ) ;
>>>> @@ -589,7 +589,7 @@
>>>>         parent.toDepthFirstString() ;
>>>>     }
>>>>
>>>> -    +
>>>>     public void testAddLast()
>>>>     {
>>>>         DefaultMutableTupleNode parent = new 
>>>> DefaultMutableTupleNode() ;
>>>> @@ -599,7 +599,7 @@
>>>>         node.setParent( (MutableTupleNode) parent) ;
>>>>         parent.addLast( end ) ;
>>>>         end.setParent( (MutableTupleNode) parent) ;
>>>> -        +
>>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>>> TypeClass.APPLICATION ) ;
>>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>>> TypeClass.UNIVERSAL ) ;
>>>>
>>>> Modified: 
>>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java 
>>>>
>>>> URL: 
>>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java?view=diff&r1=155925&r2=155926 
>>>>
>>>> ============================================================================== 
>>>>
>>>> --- 
>>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java 
>>>> (original)
>>>> +++ 
>>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java 
>>>> Wed Mar  2 07:14:39 2005
>>>> @@ -1,5 +1,5 @@
>>>> /*
>>>> - *   Copyright 2004 The Apache Software Foundation
>>>> + *   Copyright 2004-2005 The Apache Software Foundation
>>>>  *
>>>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>>>  *   you may not use this file except in compliance with the License.
>>>> @@ -142,14 +142,14 @@
>>>>         assertEquals( 2, t.getId() ) ;
>>>>         assertEquals( TypeClass.PRIVATE, t.getTypeClass() ) ;
>>>>         assertEquals( false, t.isPrimitive() ) ;
>>>> -        assertEquals( Length.INDEFINATE, t.getLength() ) ;
>>>> +        assertEquals( Length.INDEFINITE, t.getLength() ) ;
>>>>         assertEquals( EMPTY_BUFFER, t.getLastValueChunk() ) ;
>>>>
>>>>         t = new Tuple( 2, (TypeClass) null ) ;
>>>>         assertEquals( 2, t.getId() ) ;
>>>>         assertEquals( TypeClass.APPLICATION, t.getTypeClass() ) ;
>>>>         assertEquals( false, t.isPrimitive() ) ;
>>>> -        assertEquals( Length.INDEFINATE, t.getLength() ) ;
>>>> +        assertEquals( Length.INDEFINITE, t.getLength() ) ;
>>>>         assertEquals( EMPTY_BUFFER, t.getLastValueChunk() ) ;
>>>>     }
>>>>
>>>> @@ -162,8 +162,8 @@
>>>>         t.id = 21 ;
>>>>         assertEquals( 21, t.getId() ) ;
>>>>     }
>>>> -    -    +
>>>> +
>>>>     public void testSize()
>>>>     {
>>>>         Tuple t = new Tuple( 1, TypeClass.APPLICATION ) ;
>>>> @@ -178,7 +178,7 @@
>>>>         assertEquals( 5, t.size() ) ;
>>>>         t.id = 1 << 21 ;
>>>>         assertEquals( 6, t.size() ) ;
>>>> -        +
>>>>         t.length = 127 ;
>>>>         assertEquals( 6+127, t.size() ) ;
>>>>         t.length = 128 ;
>>>> @@ -188,28 +188,28 @@
>>>>         t.length = 256 ;
>>>>         assertEquals( 8+256, t.size() ) ;
>>>>     }
>>>> -    -    -    public void testIsIndefinate()
>>>> +
>>>> +
>>>> +    public void testIsIndefinite()
>>>>     {
>>>>         Tuple t = new Tuple() ;
>>>> -        assertFalse( t.isIndefinate() ) ;
>>>> -        t.length = Length.INDEFINATE ;
>>>> -        assertTrue( t.isIndefinate() ) ;
>>>> +        assertFalse( t.isIndefinite() ) ;
>>>> +        t.length = Length.INDEFINITE ;
>>>> +        assertTrue( t.isIndefinite() ) ;
>>>>     }
>>>> -   -    public void testIsIndefinateTerminator()
>>>> +
>>>> +    public void testIsIndefiniteTerminator()
>>>>     {
>>>>         Tuple t = new Tuple() ;
>>>> -        assertFalse( t.isIndefinateTerminator() ) ;
>>>> +        assertFalse( t.isIndefiniteTerminator() ) ;
>>>>         t.id = 0 ;
>>>>         t.length = 0 ;
>>>>         t.isPrimitive = true ;
>>>>         t.typeClass = TypeClass.UNIVERSAL ;
>>>> -        assertTrue( t.isIndefinateTerminator() ) ;
>>>> +        assertTrue( t.isIndefiniteTerminator() ) ;
>>>>     }
>>>> -    +
>>>>
>>>>     public void testIsPrimitive()
>>>>     {
>>>> @@ -300,13 +300,13 @@
>>>>         Tuple tnull1 = new Tuple() ;
>>>>         tnull1.valueChunk = null ;
>>>>         tnull0.equals( tnull1 ) ;
>>>> -        +
>>>>         tnull1.equals( tnull1 ) ;
>>>>         tnull0.equals( tnull0 ) ;
>>>> -        +
>>>>         Tuple t0 = new Tuple() ;
>>>>         Tuple t1 = ( Tuple ) t0.clone() ;
>>>> -        +
>>>>         assertTrue( t0.equals( t1 ) ) ;
>>>>         t0.id = 23 ;
>>>>         assertFalse( t0.equals( t1 ) ) ;
>>>> @@ -346,10 +346,10 @@
>>>>
>>>>         t0.valueChunk = ByteBuffer.allocate( 4 ) ;
>>>>         t1.valueChunk = null ;
>>>> -        +
>>>>         // The buffer does not factor into equality
>>>>         assertTrue( t0.equals( t1 ) ) ;
>>>> -        +
>>>>         t1 = ( Tuple ) t0.clone() ;
>>>>         assertTrue( t0.equals( t1 ) ) ;
>>>>
>>>> @@ -567,13 +567,13 @@
>>>>                 , toAsciiString( encoded ) ) ;
>>>>     }
>>>>
>>>> -    +
>>>>     public String toAsciiString( ByteBuffer buf )
>>>>     {
>>>>         return BinaryCodec.toAsciiString( buf.array() ) ;
>>>>     }
>>>> -    -    +
>>>> +
>>>>     public void testSetTagBufferint()
>>>>     {
>>>>         ByteBuffer bites = ByteBuffer.allocate( 1 ) ;
>>>> @@ -581,7 +581,7 @@
>>>>         t.setTag( bites, 1 ) ;
>>>>         String binary = toAsciiString( bites ) ;
>>>>         assertEquals( "01100000", binary ) ;
>>>> -        +
>>>>         bites = ByteBuffer.allocate( 1 ) ;
>>>>         t = new Tuple( 30, 0 ) ;
>>>>         t.setTag( bites, 1 ) ;
>>>> @@ -617,8 +617,8 @@
>>>>         t = new Tuple( BIT_13 - 1, 0 ) ;
>>>>         t.setTag( bites, 3 ) ;
>>>>         binary = toAsciiString( bites ) ;
>>>> -        assertEquals( "01111111" + -                      
>>>> "11111111" + +        assertEquals( "01111111" +
>>>> +                      "11111111" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 4 ) ;
>>>> @@ -627,7 +627,7 @@
>>>>         binary = toAsciiString( bites ) ;
>>>>         assertEquals( "00000000" +
>>>>                       "10000000" +
>>>> -                      "10000001" + +                      
>>>> "10000001" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 4 ) ;
>>>> @@ -636,16 +636,16 @@
>>>>         binary = toAsciiString( bites ) ;
>>>>         assertEquals( "00000001" +
>>>>                       "10000000" +
>>>> -                      "10000001" + +                      
>>>> "10000001" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 4 ) ;
>>>>         t = new Tuple( BIT_20 - 1, 0 ) ;
>>>>         t.setTag( bites, 4 ) ;
>>>>         binary = toAsciiString( bites ) ;
>>>> -        assertEquals( "01111111" + -                      
>>>> "11111111" + -                      "11111111" + +        
>>>> assertEquals( "01111111" +
>>>> +                      "11111111" +
>>>> +                      "11111111" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 5 ) ;
>>>> @@ -655,7 +655,7 @@
>>>>         assertEquals( "00000000" +
>>>>                       "10000000" +
>>>>                       "10000000" +
>>>> -                      "10000001" + +                      
>>>> "10000001" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 5 ) ;
>>>> @@ -665,22 +665,22 @@
>>>>         assertEquals( "00000001" +
>>>>                       "10000000" +
>>>>                       "10000000" +
>>>> -                      "10000001" + +                      
>>>> "10000001" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 5 ) ;
>>>>         t = new Tuple( BIT_27 - 1, 0 ) ;
>>>>         t.setTag( bites, 5 ) ;
>>>>         binary = toAsciiString( bites ) ;
>>>> -        assertEquals( "01111111" + -                      
>>>> "11111111" + -                      "11111111" + 
>>>> -                      "11111111" + +        assertEquals( 
>>>> "01111111" +
>>>> +                      "11111111" +
>>>> +                      "11111111" +
>>>> +                      "11111111" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 6 ) ;
>>>>         t = new Tuple( BIT_27, 0 ) ;
>>>> -        +
>>>>         try
>>>>         {
>>>>             t.setTag( bites, 6 ) ;
>>>> @@ -699,7 +699,7 @@
>>>>         t.setTag( bites, 1 ) ;
>>>>         String binary = toAsciiString( bites ) ;
>>>>         assertEquals( "01100000", binary ) ;
>>>> -        +
>>>>         bites = ByteBuffer.allocate( 1 ) ;
>>>>         t = new Tuple( 30, 0 ) ;
>>>>         t.setTag( bites, 1 ) ;
>>>> @@ -735,8 +735,8 @@
>>>>         t = new Tuple( BIT_13 - 1, 0 ) ;
>>>>         t.setTag( bites, 3 ) ;
>>>>         binary = toAsciiString( bites ) ;
>>>> -        assertEquals( "01111111" + -                      
>>>> "11111111" + +        assertEquals( "01111111" +
>>>> +                      "11111111" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 4 ) ;
>>>> @@ -745,7 +745,7 @@
>>>>         binary = toAsciiString( bites ) ;
>>>>         assertEquals( "00000000" +
>>>>                       "10000000" +
>>>> -                      "10000001" + +                      
>>>> "10000001" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 4 ) ;
>>>> @@ -754,16 +754,16 @@
>>>>         binary = toAsciiString( bites ) ;
>>>>         assertEquals( "00000001" +
>>>>                       "10000000" +
>>>> -                      "10000001" + +                      
>>>> "10000001" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 4 ) ;
>>>>         t = new Tuple( BIT_20 - 1, 0 ) ;
>>>>         t.setTag( bites, 4 ) ;
>>>>         binary = toAsciiString( bites ) ;
>>>> -        assertEquals( "01111111" + -                      
>>>> "11111111" + -                      "11111111" + +        
>>>> assertEquals( "01111111" +
>>>> +                      "11111111" +
>>>> +                      "11111111" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 5 ) ;
>>>> @@ -773,7 +773,7 @@
>>>>         assertEquals( "00000000" +
>>>>                       "10000000" +
>>>>                       "10000000" +
>>>> -                      "10000001" + +                      
>>>> "10000001" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 5 ) ;
>>>> @@ -783,22 +783,22 @@
>>>>         assertEquals( "00000001" +
>>>>                       "10000000" +
>>>>                       "10000000" +
>>>> -                      "10000001" + +                      
>>>> "10000001" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 5 ) ;
>>>>         t = new Tuple( BIT_27 - 1, 0 ) ;
>>>>         t.setTag( bites, 5 ) ;
>>>>         binary = toAsciiString( bites ) ;
>>>> -        assertEquals( "01111111" + -                      
>>>> "11111111" + -                      "11111111" + 
>>>> -                      "11111111" + +        assertEquals( 
>>>> "01111111" +
>>>> +                      "11111111" +
>>>> +                      "11111111" +
>>>> +                      "11111111" +
>>>>                       "01111111", binary ) ;
>>>>
>>>>         bites = ByteBuffer.allocate( 6 ) ;
>>>>         t = new Tuple( BIT_27, 0 ) ;
>>>> -        +
>>>>         try
>>>>         {
>>>>             t.setTag( bites, 6 ) ;
>>>> @@ -809,8 +809,8 @@
>>>>             assertNotNull( e ) ;
>>>>         }
>>>>     }
>>>> -    -    +
>>>> +
>>>>     String toAsciiString( int raw )
>>>>     {
>>>>         byte[] intBytes = new byte[4] ;
>>>> @@ -818,10 +818,10 @@
>>>>         intBytes[1] = (byte) ( (int) ( 0x0000ff00 & raw ) >> 8 ) ;
>>>>         intBytes[2] = (byte) ( (int) ( 0x00ff0000 & raw ) >> 16 ) ;
>>>>         intBytes[3] = (byte) ( (int) ( 0xff000000 & raw ) >> 24 ) ;
>>>> -        +
>>>>         return BinaryCodec.toAsciiString( intBytes ) ;
>>>>     }
>>>> -    +
>>>>
>>>>     public void testSetLengthBuffer()
>>>>     {
>>>> @@ -1064,7 +1064,7 @@
>>>>         assertEquals( 4, t.getTagLength() ) ;
>>>>         t.id = BIT_13 + 100 ;
>>>>         assertEquals( 4, t.getTagLength() ) ;
>>>> -        +
>>>>         t.id = BIT_20 - 1 ;
>>>>         assertEquals( 4, t.getTagLength() ) ;
>>>>         t.id = BIT_20 ;
>>>> @@ -1076,7 +1076,7 @@
>>>>         assertEquals( 5, t.getTagLength() ) ;
>>>>
>>>>         t.id = BIT_27 ;
>>>> -        +
>>>>         try
>>>>         {
>>>>             assertEquals( 6, t.getTagLength() ) ;
>>>> @@ -1107,7 +1107,7 @@
>>>>         assertEquals( 4, t.getLengthLength() ) ;
>>>>         t.length = BIT_15 + 100 ;
>>>>         assertEquals( 4, t.getLengthLength() ) ;
>>>> -        +
>>>>         t.length = BIT_23 - 1 ;
>>>>         assertEquals( 4, t.getLengthLength() ) ;
>>>>         t.length = BIT_23 ;
>>>> @@ -1118,7 +1118,7 @@
>>>>         t.length = Integer.MAX_VALUE ;
>>>>         assertEquals( 5, t.getLengthLength() ) ;
>>>>
>>>> -        +
>>>>         t.length = Integer.MAX_VALUE + 1 ;
>>>>         try
>>>>         {
>>>> @@ -1129,6 +1129,6 @@
>>>>         {
>>>>             assertNotNull( e ) ;
>>>>         }
>>>> -        +
>>>>     }
>>>> }
>>>>
>>>> Modified: 
>>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java 
>>>>
>>>> URL: 
>>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java?view=diff&r1=155925&r2=155926 
>>>>
>>>> ============================================================================== 
>>>>
>>>> --- 
>>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java 
>>>> (original)
>>>> +++ 
>>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java 
>>>> Wed Mar  2 07:14:39 2005
>>>> @@ -1,5 +1,5 @@
>>>> /*
>>>> - *   Copyright 2004 The Apache Software Foundation
>>>> + *   Copyright 2004-2005 The Apache Software Foundation
>>>>  *
>>>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>>>  *   you may not use this file except in compliance with the License.
>>>> @@ -99,12 +99,12 @@
>>>>
>>>>
>>>>     /**
>>>> -     * Tests when the length is indefinate.
>>>> +     * Tests when the length is indefinite.
>>>>      */
>>>> -    public void testIndefinateLength()
>>>> +    public void testIndefiniteLength()
>>>>     {
>>>>         rule.tag( UniversalTag.OCTET_STRING.getTagId(), true, null ) ;
>>>> -        rule.length( Length.INDEFINATE ) ;
>>>> +        rule.length( Length.INDEFINITE ) ;
>>>>         rule.finish() ;
>>>>         ByteBuffer buf = ( ByteBuffer ) digester.pop() ;
>>>>         assertFalse( buf.hasRemaining() ) ;
>>>> @@ -112,12 +112,12 @@
>>>>
>>>>
>>>>     /**
>>>> -     * Tests when the length is indefinate.
>>>> +     * Tests when the length is indefinite.
>>>>      */
>>>>     public void testNullValue()
>>>>     {
>>>>         rule.tag( UniversalTag.OCTET_STRING.getTagId(), true, null ) ;
>>>> -        rule.length( Length.INDEFINATE ) ;
>>>> +        rule.length( Length.INDEFINITE ) ;
>>>>         rule.value( null ) ;
>>>>         rule.value( ByteBuffer.allocate( 0 ) ) ;
>>>>         rule.finish() ;
>>>>
>>>> Modified: 
>>>> incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml
>>>> URL: 
>>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml?view=diff&r1=155925&r2=155926 
>>>>
>>>> ============================================================================== 
>>>>
>>>> --- incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml 
>>>> (original)
>>>> +++ incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml 
>>>> Wed Mar  2 07:14:39 2005
>>>> @@ -22,7 +22,7 @@
>>>>         <p>
>>>>           A constructed TLV tuple contains other TLV tuples nested 
>>>> within the
>>>>           Value field, and so on, recursively.  The nesting depth 
>>>> is usually
>>>> -          indefinate and dependent on the data structures being 
>>>> transformed.
>>>> +          indefinite and dependent on the data structures being 
>>>> transformed.
>>>>           This fact drastically affects the way the decoder is 
>>>> designed and
>>>>           hence operates.
>>>>         </p>
>>>> @@ -61,7 +61,7 @@
>>>>
>>>>         <p>
>>>>           Now let's try to figure out how to handle constructed TLV 
>>>> tuples
>>>> -          which recursively nest other tuples indefinately.  State 
>>>> now
>>>> +          which recursively nest other tuples indefinitely.  State 
>>>> now
>>>>           is more that just where you left off in the current tuple 
>>>> being
>>>>           processed.  When processing an inner tuple the decoder 
>>>> must also know
>>>>           where it left off in the outter tuple to resume 
>>>> processing.  More
>>>>
>>>> Modified: 
>>>> incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java 
>>>>
>>>> URL: 
>>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java?view=diff&r1=155925&r2=155926 
>>>>
>>>> ============================================================================== 
>>>>
>>>> --- 
>>>> incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java 
>>>> (original)
>>>> +++ 
>>>> incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java 
>>>> Wed Mar  2 07:14:39 2005
>>>> @@ -1,5 +1,5 @@
>>>> /*
>>>> - *   Copyright 2004 The Apache Software Foundation
>>>> + *   Copyright 2004-2005 The Apache Software Foundation
>>>>  *
>>>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>>>  *   you may not use this file except in compliance with the License.
>>>> @@ -36,33 +36,33 @@
>>>>     private final LinkedList history ;
>>>>     /** the length of callback history stored */
>>>>     private final int length ;
>>>> -    +
>>>>
>>>>     /**
>>>> -     * Creates an auditing callback that manages a history of 
>>>> indefinate length.
>>>> +     * Creates an auditing callback that manages a history of 
>>>> indefinite length.
>>>>      */
>>>>     public CallbackHistory()
>>>>     {
>>>>         this( -1 ) ;
>>>>     }
>>>> -    -    +
>>>> +
>>>>     /**
>>>> -     * Creates an auditing callback that manages a history of 
>>>> fixed or -     * indefinate length.  If the length is fixed the 
>>>> history effectively +     * Creates an auditing callback that 
>>>> manages a history of fixed or
>>>> +     * indefinite length.  If the length is fixed the history 
>>>> effectively
>>>>      * becomes a FIFO structure.
>>>> -     * +     *
>>>>      * @param length the maximum length of callback history to 
>>>> store before
>>>> -     *  dropping decoded items, a length of zero or 1 corresponds 
>>>> to indefinate
>>>> -     *  history +     *  dropping decoded items, a length of zero 
>>>> or 1 corresponds to indefinite
>>>> +     *  history
>>>>      */
>>>>     public CallbackHistory( int length )
>>>>     {
>>>>         this.length = length ;
>>>>         history = new LinkedList() ;
>>>>     }
>>>> -    -    +
>>>> +
>>>>     /* (non-Javadoc)
>>>>      * @see 
>>>> org.apache.asn1.codec.stateful.DecoderCallback#decodeOccurred(
>>>>      * org.apache.asn1.codec.stateful.StatefulDecoder, 
>>>> java.lang.Object)
>>>> @@ -70,13 +70,13 @@
>>>>     public void decodeOccurred( StatefulDecoder decoder, Object 
>>>> decoded )
>>>>     {
>>>>         if ( length > 0 )
>>>> -        {    +        {
>>>>             while ( history.size() >= length )
>>>>             {
>>>>                 history.removeLast() ;
>>>>             }
>>>>         }
>>>> -        +
>>>>         history.addFirst( decoded ) ;
>>>>     }
>>>>
>>>> @@ -103,7 +103,7 @@
>>>>
>>>>     /**
>>>>      * Gets the most recent decoded object if one exists.
>>>> -     * +     *
>>>>      * @return the most recent decoded object
>>>>      * @throws java.util.NoSuchElementException if the history is 
>>>> empty
>>>>      */
>>>> @@ -111,11 +111,11 @@
>>>>     {
>>>>         return history.getFirst() ;
>>>>     }
>>>> -    -    +
>>>> +
>>>>     /**
>>>>      * Gets the oldest decoded object if one exists.
>>>> -     * +     *
>>>>      * @return the oldest decoded object
>>>>      * @throws java.util.NoSuchElementException if the history is 
>>>> empty
>>>>      */
>>>> @@ -123,19 +123,19 @@
>>>>     {
>>>>         return history.getLast() ;
>>>>     }
>>>> -    -    +
>>>> +
>>>>     /**
>>>>      * Tests to see if the history is empty.
>>>> -     * +     *
>>>>      * @return true if the history is empty, false otherwise
>>>>      */
>>>>     public boolean isEmpty()
>>>>     {
>>>>         return history.isEmpty() ;
>>>>     }
>>>> -    -    +
>>>> +
>>>>     /**
>>>>      * Clears the history of decoded items.
>>>>      */
>>>> @@ -143,11 +143,11 @@
>>>>     {
>>>>         history.clear() ;
>>>>     }
>>>> -    -    +
>>>> +
>>>>     /**
>>>>      * Gets the number of decoded items in the callback history.
>>>> -     * +     *
>>>>      * @return the number of decoded items in the callback history
>>>>      */
>>>>     public int size()
>>>>
>>>> Modified: incubator/directory/asn1/trunk/xdocs/refactor.xml
>>>> URL: 
>>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/xdocs/refactor.xml?view=diff&r1=155925&r2=155926 
>>>>
>>>> ============================================================================== 
>>>>
>>>> --- incubator/directory/asn1/trunk/xdocs/refactor.xml (original)
>>>> +++ incubator/directory/asn1/trunk/xdocs/refactor.xml Wed Mar  2 
>>>> 07:14:39 2005
>>>> @@ -166,7 +166,7 @@
>>>>           are still abstract.  This is because we need to 
>>>> differentiate further
>>>>           for buffered verses streamed Tuples in the case of 
>>>> primitive Tuples.
>>>>           For constructed Tuples we need to differentiate between 
>>>> definate
>>>> -          length verses indefinate length Tuples.  With our 
>>>> approach, only the +          length verses indefinite length 
>>>> Tuples.  With our approach, only the           leaf nodes of the 
>>>> inheritance hierarchy will be concrete.  Below is
>>>>           the definition for the PrimitiveTuple.
>>>>         </p>
>>>> @@ -251,10 +251,10 @@
>>>>
>>>>     /**
>>>>      * Gets whether or not the length of this constructed Tuple is 
>>>> of the -     * definate form or of the indefinate length form.
>>>> +     * definate form or of the indefinite length form.
>>>>      *
>>>>      * @return true if the length is definate, false if the length 
>>>> is of the
>>>> -     * indefinate form
>>>> +     * indefinite form
>>>>      */
>>>>     public abstract boolean isLengthDefinate();
>>>> }
>>>> @@ -264,21 +264,21 @@
>>>>           ConstructedTuple implements the 
>>>> <code>isConstructed()</code> method           as final since it 
>>>> will always return false for this lineage of           Tuples.  
>>>> Also a new abstract method isLengthDefinate() is introduced 
>>>> -          to see if the Tuple uses the indefinate length form or 
>>>> not.  +          to see if the Tuple uses the indefinite length 
>>>> form or not.          </p>
>>>>       </subsection>
>>>>
>>>> -      <subsection name="Definate Vs. Indefinate Length">
>>>> +      <subsection name="Definate Vs. Indefinite Length">
>>>>         <p>
>>>>           The ConstructedTuple can be further differentiated into 
>>>> two -          subclasses to represent definate and indefinate 
>>>> length constructed -          TLV Tuples.  The indefinate form does 
>>>> not have a length value +          subclasses to represent definate 
>>>> and indefinite length constructed +          TLV Tuples.  The 
>>>> indefinite form does not have a length value           associated 
>>>> with it where as the definate lenght form does.  Let's
>>>> -          explore the concrete IndefinateLegthTuple definition.
>>>> +          explore the concrete IndefiniteLegthTuple definition.
>>>>         </p>
>>>>
>>>> <source>
>>>> -public class IndefinateLength extends ConstructedTuple
>>>> +public class IndefiniteLength extends ConstructedTuple
>>>> {
>>>>     public final boolean isLengthDefinate()
>>>>     {
>>>>
>>>>
>>>>
>>>>  
>>>>
>>
>>


Re: svn commit: r155926 [2/2] - in incubator/directory/asn1/trunk: ber/src/java/org/apache/asn1/ber/ ber/src/java/org/apache/asn1/ber/digester/rules/ ber/src/test/org/apache/asn1/ber/ ber/src/test/org/apache/asn1/ber/digester/rules/ ber/xdocs/ codec/src/java/org/apache/asn1/codec/stateful/ xdocs/

Posted by Alex Karasulu <ao...@bellsouth.net>.
How come your log message did not say this?

Alan D. Cabrera wrote:

> The word indefinite was misspelled  If you look carefully, you'll see 
> that each file has it corrected.  It seems that my editor removed the 
> extra spaces on the end of some lines.
>
>
> Regards,
> Alan
>
> Alex Karasulu wrote:
>
>> Alan I don't see these diffs doing anything.  What was the point for 
>> these modifications?
>>
>> Alex
>>
>> adc@apache.org wrote:
>>
>>> Modified: 
>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java 
>>>
>>> URL: 
>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java?view=diff&r1=155925&r2=155926 
>>>
>>> ============================================================================== 
>>>
>>> --- 
>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java 
>>> (original)
>>> +++ 
>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java 
>>> Wed Mar  2 07:14:39 2005
>>> @@ -1,5 +1,5 @@
>>> /*
>>> - *   Copyright 2004 The Apache Software Foundation
>>> + *   Copyright 2004-2005 The Apache Software Foundation
>>>  *
>>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>>  *   you may not use this file except in compliance with the License.
>>> @@ -37,7 +37,7 @@
>>> {
>>>     public DefaultMutableTupleNodeTest()
>>>     {
>>> -        super ( DefaultMutableTupleNodeTest.class.getName() ) ; 
>>> +        super ( DefaultMutableTupleNodeTest.class.getName() ) ;
>>>     }
>>>
>>>
>>> @@ -85,7 +85,7 @@
>>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>>         node.setParent( (MutableTupleNode) parent) ;
>>> -        +
>>>         assertEquals(1,parent.getChildCount()) ;
>>>         node.removeFromParent() ;
>>>         assertEquals(0,parent.getChildCount()) ;
>>> @@ -147,7 +147,7 @@
>>>         assertTrue( parent.getChildren().hasNext()) ;
>>>     }
>>>
>>> -    +
>>>     public void testGetChildTupleNodeAt()
>>>     {
>>>     }
>>> @@ -175,13 +175,13 @@
>>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>>         node.setParent( (MutableTupleNode) parent) ;
>>> -        +
>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>         parent.setTuple( constructed ) ;
>>>         node.setTuple( primitive ) ;
>>> -        -        // fact that we use the indefinate form we 
>>> automatically add two to
>>> +
>>> +        // fact that we use the indefinite form we automatically 
>>> add two to
>>>         // the contained size
>>>         assertEquals(9, parent.size()) ;
>>>     }
>>> @@ -192,12 +192,12 @@
>>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>>         node.setParent( (MutableTupleNode) parent) ;
>>> -        +
>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple constructed = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>>         parent.setTuple( constructed ) ;
>>>         node.setTuple( primitive ) ;
>>> -        +
>>>         assertEquals(7, parent.size()) ;
>>>     }
>>>
>>> @@ -206,7 +206,7 @@
>>>         DefaultMutableTupleNode parent = new 
>>> DefaultMutableTupleNode() ;
>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>         parent.setTuple( constructed ) ;
>>> -        +
>>>         assertEquals(4, parent.size()) ;
>>>     }
>>>
>>> @@ -219,7 +219,7 @@
>>>         ByteBuffer buf = ByteBuffer.allocate( 4 ) ;
>>>         parent.encode( buf ) ;
>>>
>>> -        +
>>>         /*
>>>         final ArrayList list = new ArrayList() ;
>>>         TupleTreeDecoder decoder = new TupleTreeDecoder() ;
>>> @@ -228,10 +228,10 @@
>>>             {
>>>                 list.add( arg1 ) ;
>>>             }}) ;
>>> -        +
>>>         decoder.decode(buf.flip()) ;
>>> -        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode 
>>> ) -            list.get(0); +        DefaultMutableTupleNode decoded 
>>> = ( DefaultMutableTupleNode )
>>> +            list.get(0);
>>>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>>>         */
>>>     }
>>> @@ -248,13 +248,13 @@
>>>     {
>>>         DefaultMutableTupleNode parent = new 
>>> DefaultMutableTupleNode() ;
>>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>> -        +
>>>         DefaultMutableTupleNode end = new DefaultMutableTupleNode() ;
>>>         parent.insert( (MutableTupleNode) end, 0 ) ;
>>>         end.setParent( (MutableTupleNode) parent) ;
>>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>>         node.setParent( (MutableTupleNode) parent) ;
>>> -        +
>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>> TypeClass.UNIVERSAL ) ;
>>> @@ -262,9 +262,9 @@
>>>         parent.setTuple( constructed ) ;
>>>         node.setTuple( primitive ) ;
>>>         end.setTuple(terminator) ;
>>> -        +
>>>         assertEquals(9, parent.size()) ;
>>> -        +
>>>         ByteBuffer buf = ByteBuffer.allocate( 9 ) ;
>>>         parent.encode( buf ) ;
>>>
>>> @@ -276,10 +276,10 @@
>>>             {
>>>                 list.add( arg1 ) ;
>>>             }}) ;
>>> -        +
>>>         decoder.decode(buf.flip()) ;
>>> -        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode 
>>> ) -            list.get(0); +        DefaultMutableTupleNode decoded 
>>> = ( DefaultMutableTupleNode )
>>> +            list.get(0);
>>>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>>>         */
>>>     }
>>> @@ -290,15 +290,15 @@
>>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>>         node.setParent( (MutableTupleNode) parent) ;
>>> -        +
>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>         parent.setTuple( constructed ) ;
>>>         node.setTuple( primitive ) ;
>>> -        -        // 2 extra bytes added for indefinate form
>>> +
>>> +        // 2 extra bytes added for indefinite form
>>>         assertEquals(9, parent.size()) ;
>>> -        +
>>>         ByteBuffer buf = ByteBuffer.allocate( 9 ) ;
>>>         parent.encode( buf ) ;
>>>
>>> @@ -310,10 +310,10 @@
>>>             {
>>>                 list.add( arg1 ) ;
>>>             }}) ;
>>> -        +
>>>         decoder.decode(buf.flip()) ;
>>> -        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode 
>>> ) -            list.get(0); +        DefaultMutableTupleNode decoded 
>>> = ( DefaultMutableTupleNode )
>>> +            list.get(0);
>>>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>>>         */
>>>     }
>>> @@ -327,18 +327,18 @@
>>>         middle.setParent( (MutableTupleNode) top) ;
>>>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>>>         bottom.setParent( (MutableTupleNode) middle) ;
>>> -        +
>>>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>>>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>>         Tuple bottomTuple = new Tuple( 3, 1, true, 
>>> TypeClass.APPLICATION ) ;
>>> -        +
>>>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>>>         top.setTuple( topTuple ) ;
>>>         middle.setTuple( middleTuple ) ;
>>>         bottom.setTuple( bottomTuple ) ;
>>> -        +
>>>         assertEquals(7, top.size()) ;
>>> -        +
>>>         ByteBuffer buf = ByteBuffer.allocate( 7 ) ;
>>>         top.encode( buf ) ;
>>>
>>> @@ -350,15 +350,15 @@
>>>             {
>>>                 list.add( arg1 ) ;
>>>             }}) ;
>>> -        +
>>>         decoder.decode(buf.flip()) ;
>>> -        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode 
>>> ) -            list.get(0); +        DefaultMutableTupleNode decoded 
>>> = ( DefaultMutableTupleNode )
>>> +            list.get(0);
>>>         assertEquals( decoded.getTuple(), top.getTuple()) ;
>>>         */
>>>     }
>>>
>>> -    +
>>>     public void testEquals()
>>>     {
>>>         DefaultMutableTupleNode top = new DefaultMutableTupleNode() ;
>>> @@ -368,18 +368,18 @@
>>>         middle.setParent( (MutableTupleNode) top) ;
>>>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>>>         bottom.setParent( (MutableTupleNode) middle) ;
>>> -        +
>>>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>>>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>>         Tuple bottomTuple = new Tuple( 3, 1, true, 
>>> TypeClass.APPLICATION ) ;
>>> -        +
>>>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>>>         top.setTuple( topTuple ) ;
>>>         middle.setTuple( middleTuple ) ;
>>>         bottom.setTuple( bottomTuple ) ;
>>>
>>>         assertTrue( top.equals( top ) ) ;
>>> -        +
>>>         DefaultMutableTupleNode topClone = new 
>>> DefaultMutableTupleNode() ;
>>>         topClone.setTuple( topTuple ) ;
>>>         assertFalse( top.equals(topClone)) ;
>>> @@ -387,7 +387,7 @@
>>>         topClone = new DefaultMutableTupleNode() ;
>>>         topClone.setTuple( bottomTuple ) ;
>>>         assertFalse( top.equals(topClone)) ;
>>> -        +
>>>         topClone = new DefaultMutableTupleNode() ;
>>>         DefaultMutableTupleNode middleClone = new 
>>> DefaultMutableTupleNode() ;
>>>         DefaultMutableTupleNode bottomClone = new 
>>> DefaultMutableTupleNode() ;
>>> @@ -395,11 +395,11 @@
>>>         middleClone.setParent( (MutableTupleNode) topClone) ;
>>>         middleClone.insert( (MutableTupleNode) bottomClone, 0 ) ;
>>>         bottomClone.setParent( (MutableTupleNode) middleClone) ;
>>> -        +
>>>         Tuple middleTupleClone = new Tuple( 1, 3, 
>>> TypeClass.APPLICATION  ) ;
>>>         Tuple topTupleClone = new Tuple ( 2, 5, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple bottomTupleClone= new Tuple( 3, 1, true, 
>>> TypeClass.APPLICATION ) ;
>>> -        +
>>>         bottomTupleClone.typeClass = TypeClass.UNIVERSAL ;
>>>         topClone.setTuple( topTupleClone ) ;
>>>         middleClone.setTuple( middleTupleClone ) ;
>>> @@ -409,8 +409,8 @@
>>>         assertTrue( middle.equals( middleClone ) ) ;
>>>         assertTrue( top.equals( topClone ) ) ;
>>>      }
>>> -    -    +
>>> +
>>>     public void testEquals2()
>>>     {
>>>         DefaultMutableTupleNode top = new DefaultMutableTupleNode() ;
>>> @@ -420,11 +420,11 @@
>>>         middle.setParent( (MutableTupleNode) top) ;
>>>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>>>         bottom.setParent( (MutableTupleNode) middle) ;
>>> -        +
>>>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>>>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>>         Tuple bottomTuple = new Tuple( 3, 1, true, 
>>> TypeClass.APPLICATION ) ;
>>> -        +
>>>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>>>         top.setTuple( topTuple ) ;
>>>         middle.setTuple( middleTuple ) ;
>>> @@ -433,7 +433,7 @@
>>>         assertTrue( top.equals( top ) ) ;
>>>
>>>         top.printDepthFirst(new StringBuffer(), 0 ) ;
>>> -        +
>>>         DefaultMutableTupleNode topClone = new 
>>> DefaultMutableTupleNode() ;
>>>         topClone.setTuple( topTuple ) ;
>>>         assertFalse( top.equals(topClone)) ;
>>> @@ -441,7 +441,7 @@
>>>         topClone = new DefaultMutableTupleNode() ;
>>>         topClone.setTuple( bottomTuple ) ;
>>>         assertFalse( top.equals(topClone)) ;
>>> -        +
>>>         topClone = new DefaultMutableTupleNode() ;
>>>         DefaultMutableTupleNode middleClone = new 
>>> DefaultMutableTupleNode() ;
>>>         DefaultMutableTupleNode bottomClone = new 
>>> DefaultMutableTupleNode() ;
>>> @@ -449,11 +449,11 @@
>>>         middleClone.setParent( (MutableTupleNode) topClone) ;
>>>         middleClone.insert( (MutableTupleNode) bottomClone, 0 ) ;
>>>         bottomClone.setParent( (MutableTupleNode) middleClone) ;
>>> -        +
>>>         Tuple middleTupleClone = new Tuple( 1, 3, 
>>> TypeClass.APPLICATION  ) ;
>>>         Tuple topTupleClone = new Tuple ( 2, 5, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple bottomTupleClone= new Tuple( 3, 1, true, 
>>> TypeClass.APPLICATION ) ;
>>> -        +
>>>         bottomTupleClone.typeClass = TypeClass.UNIVERSAL ;
>>>         topClone.setTuple( topTupleClone ) ;
>>>         middleClone.setTuple( bottomTupleClone ) ;
>>> @@ -465,8 +465,8 @@
>>>         assertFalse( top.equals( new Object() ) ) ;
>>>         assertFalse( top.equals( null ) ) ;
>>>      }
>>> -    -    +
>>> +
>>>     /*
>>>      * Class to test for String toString()
>>>      */
>>> @@ -479,7 +479,7 @@
>>>         end.setParent( parent) ;
>>>         parent.insert( node, 0 ) ;
>>>         node.setParent( parent) ;
>>> -        +
>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>> TypeClass.UNIVERSAL ) ;
>>> @@ -487,7 +487,7 @@
>>>         parent.setTuple( constructed ) ;
>>>         node.setTuple( primitive ) ;
>>>         end.setTuple( terminator ) ;
>>> -        +
>>>         assertNotNull( parent.toString() ) ;
>>>     }
>>>
>>> @@ -500,7 +500,7 @@
>>>         end.setParent( parent) ;
>>>         parent.insert( node, 0 ) ;
>>>         node.setParent( parent) ;
>>> -        +
>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>> TypeClass.UNIVERSAL ) ;
>>> @@ -508,7 +508,7 @@
>>>         parent.setTuple( constructed ) ;
>>>         node.setTuple( primitive, Collections.EMPTY_LIST ) ;
>>>         end.setTuple( terminator ) ;
>>> -        +
>>>         assertTrue( node.getValueChunks().isEmpty() ) ;
>>>
>>>
>>> @@ -525,7 +525,7 @@
>>>         end.setParent( parent) ;
>>>         parent.insert( node, 0 ) ;
>>>         node.setParent( parent) ;
>>> -        +
>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>> TypeClass.UNIVERSAL ) ;
>>> @@ -533,18 +533,18 @@
>>>         parent.setTuple( constructed ) ;
>>>         node.setTuple( primitive ) ;
>>>         end.setTuple( terminator ) ;
>>> -        +
>>>         Iterator list = parent.getChildren() ;
>>> -        +
>>>         assertEquals( node, list.next() ) ;
>>>         assertEquals( end, list.next() ) ;
>>> -        +
>>>         try
>>>         {
>>>             list.next() ;
>>>             fail( "should never get here due to thrown exception" ) ;
>>>         }
>>> -        catch( Throwable t ) +        catch( Throwable t )
>>>         {
>>>             assertNotNull( t ) ;
>>>         }
>>> @@ -559,7 +559,7 @@
>>>         end.setParent( parent) ;
>>>         parent.insert( node, 0 ) ;
>>>         node.setParent( parent) ;
>>> -        +
>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>> TypeClass.UNIVERSAL ) ;
>>> @@ -578,7 +578,7 @@
>>>         end.setParent( parent) ;
>>>         parent.addFront( node ) ;
>>>         node.setParent( parent) ;
>>> -        +
>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>> TypeClass.UNIVERSAL ) ;
>>> @@ -589,7 +589,7 @@
>>>         parent.toDepthFirstString() ;
>>>     }
>>>
>>> -    +
>>>     public void testAddLast()
>>>     {
>>>         DefaultMutableTupleNode parent = new 
>>> DefaultMutableTupleNode() ;
>>> @@ -599,7 +599,7 @@
>>>         node.setParent( (MutableTupleNode) parent) ;
>>>         parent.addLast( end ) ;
>>>         end.setParent( (MutableTupleNode) parent) ;
>>> -        +
>>>         Tuple primitive = new Tuple( 1, 3, true, 
>>> TypeClass.APPLICATION ) ;
>>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>>         Tuple terminator = new Tuple( 0, 0, true, 
>>> TypeClass.UNIVERSAL ) ;
>>>
>>> Modified: 
>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java 
>>>
>>> URL: 
>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java?view=diff&r1=155925&r2=155926 
>>>
>>> ============================================================================== 
>>>
>>> --- 
>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java 
>>> (original)
>>> +++ 
>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java 
>>> Wed Mar  2 07:14:39 2005
>>> @@ -1,5 +1,5 @@
>>> /*
>>> - *   Copyright 2004 The Apache Software Foundation
>>> + *   Copyright 2004-2005 The Apache Software Foundation
>>>  *
>>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>>  *   you may not use this file except in compliance with the License.
>>> @@ -142,14 +142,14 @@
>>>         assertEquals( 2, t.getId() ) ;
>>>         assertEquals( TypeClass.PRIVATE, t.getTypeClass() ) ;
>>>         assertEquals( false, t.isPrimitive() ) ;
>>> -        assertEquals( Length.INDEFINATE, t.getLength() ) ;
>>> +        assertEquals( Length.INDEFINITE, t.getLength() ) ;
>>>         assertEquals( EMPTY_BUFFER, t.getLastValueChunk() ) ;
>>>
>>>         t = new Tuple( 2, (TypeClass) null ) ;
>>>         assertEquals( 2, t.getId() ) ;
>>>         assertEquals( TypeClass.APPLICATION, t.getTypeClass() ) ;
>>>         assertEquals( false, t.isPrimitive() ) ;
>>> -        assertEquals( Length.INDEFINATE, t.getLength() ) ;
>>> +        assertEquals( Length.INDEFINITE, t.getLength() ) ;
>>>         assertEquals( EMPTY_BUFFER, t.getLastValueChunk() ) ;
>>>     }
>>>
>>> @@ -162,8 +162,8 @@
>>>         t.id = 21 ;
>>>         assertEquals( 21, t.getId() ) ;
>>>     }
>>> -    -    +
>>> +
>>>     public void testSize()
>>>     {
>>>         Tuple t = new Tuple( 1, TypeClass.APPLICATION ) ;
>>> @@ -178,7 +178,7 @@
>>>         assertEquals( 5, t.size() ) ;
>>>         t.id = 1 << 21 ;
>>>         assertEquals( 6, t.size() ) ;
>>> -        +
>>>         t.length = 127 ;
>>>         assertEquals( 6+127, t.size() ) ;
>>>         t.length = 128 ;
>>> @@ -188,28 +188,28 @@
>>>         t.length = 256 ;
>>>         assertEquals( 8+256, t.size() ) ;
>>>     }
>>> -    -    -    public void testIsIndefinate()
>>> +
>>> +
>>> +    public void testIsIndefinite()
>>>     {
>>>         Tuple t = new Tuple() ;
>>> -        assertFalse( t.isIndefinate() ) ;
>>> -        t.length = Length.INDEFINATE ;
>>> -        assertTrue( t.isIndefinate() ) ;
>>> +        assertFalse( t.isIndefinite() ) ;
>>> +        t.length = Length.INDEFINITE ;
>>> +        assertTrue( t.isIndefinite() ) ;
>>>     }
>>> -   -    public void testIsIndefinateTerminator()
>>> +
>>> +    public void testIsIndefiniteTerminator()
>>>     {
>>>         Tuple t = new Tuple() ;
>>> -        assertFalse( t.isIndefinateTerminator() ) ;
>>> +        assertFalse( t.isIndefiniteTerminator() ) ;
>>>         t.id = 0 ;
>>>         t.length = 0 ;
>>>         t.isPrimitive = true ;
>>>         t.typeClass = TypeClass.UNIVERSAL ;
>>> -        assertTrue( t.isIndefinateTerminator() ) ;
>>> +        assertTrue( t.isIndefiniteTerminator() ) ;
>>>     }
>>> -    +
>>>
>>>     public void testIsPrimitive()
>>>     {
>>> @@ -300,13 +300,13 @@
>>>         Tuple tnull1 = new Tuple() ;
>>>         tnull1.valueChunk = null ;
>>>         tnull0.equals( tnull1 ) ;
>>> -        +
>>>         tnull1.equals( tnull1 ) ;
>>>         tnull0.equals( tnull0 ) ;
>>> -        +
>>>         Tuple t0 = new Tuple() ;
>>>         Tuple t1 = ( Tuple ) t0.clone() ;
>>> -        +
>>>         assertTrue( t0.equals( t1 ) ) ;
>>>         t0.id = 23 ;
>>>         assertFalse( t0.equals( t1 ) ) ;
>>> @@ -346,10 +346,10 @@
>>>
>>>         t0.valueChunk = ByteBuffer.allocate( 4 ) ;
>>>         t1.valueChunk = null ;
>>> -        +
>>>         // The buffer does not factor into equality
>>>         assertTrue( t0.equals( t1 ) ) ;
>>> -        +
>>>         t1 = ( Tuple ) t0.clone() ;
>>>         assertTrue( t0.equals( t1 ) ) ;
>>>
>>> @@ -567,13 +567,13 @@
>>>                 , toAsciiString( encoded ) ) ;
>>>     }
>>>
>>> -    +
>>>     public String toAsciiString( ByteBuffer buf )
>>>     {
>>>         return BinaryCodec.toAsciiString( buf.array() ) ;
>>>     }
>>> -    -    +
>>> +
>>>     public void testSetTagBufferint()
>>>     {
>>>         ByteBuffer bites = ByteBuffer.allocate( 1 ) ;
>>> @@ -581,7 +581,7 @@
>>>         t.setTag( bites, 1 ) ;
>>>         String binary = toAsciiString( bites ) ;
>>>         assertEquals( "01100000", binary ) ;
>>> -        +
>>>         bites = ByteBuffer.allocate( 1 ) ;
>>>         t = new Tuple( 30, 0 ) ;
>>>         t.setTag( bites, 1 ) ;
>>> @@ -617,8 +617,8 @@
>>>         t = new Tuple( BIT_13 - 1, 0 ) ;
>>>         t.setTag( bites, 3 ) ;
>>>         binary = toAsciiString( bites ) ;
>>> -        assertEquals( "01111111" + -                      
>>> "11111111" + +        assertEquals( "01111111" +
>>> +                      "11111111" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 4 ) ;
>>> @@ -627,7 +627,7 @@
>>>         binary = toAsciiString( bites ) ;
>>>         assertEquals( "00000000" +
>>>                       "10000000" +
>>> -                      "10000001" + +                      "10000001" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 4 ) ;
>>> @@ -636,16 +636,16 @@
>>>         binary = toAsciiString( bites ) ;
>>>         assertEquals( "00000001" +
>>>                       "10000000" +
>>> -                      "10000001" + +                      "10000001" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 4 ) ;
>>>         t = new Tuple( BIT_20 - 1, 0 ) ;
>>>         t.setTag( bites, 4 ) ;
>>>         binary = toAsciiString( bites ) ;
>>> -        assertEquals( "01111111" + -                      
>>> "11111111" + -                      "11111111" + +        
>>> assertEquals( "01111111" +
>>> +                      "11111111" +
>>> +                      "11111111" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 5 ) ;
>>> @@ -655,7 +655,7 @@
>>>         assertEquals( "00000000" +
>>>                       "10000000" +
>>>                       "10000000" +
>>> -                      "10000001" + +                      "10000001" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 5 ) ;
>>> @@ -665,22 +665,22 @@
>>>         assertEquals( "00000001" +
>>>                       "10000000" +
>>>                       "10000000" +
>>> -                      "10000001" + +                      "10000001" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 5 ) ;
>>>         t = new Tuple( BIT_27 - 1, 0 ) ;
>>>         t.setTag( bites, 5 ) ;
>>>         binary = toAsciiString( bites ) ;
>>> -        assertEquals( "01111111" + -                      
>>> "11111111" + -                      "11111111" + 
>>> -                      "11111111" + +        assertEquals( "01111111" +
>>> +                      "11111111" +
>>> +                      "11111111" +
>>> +                      "11111111" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 6 ) ;
>>>         t = new Tuple( BIT_27, 0 ) ;
>>> -        +
>>>         try
>>>         {
>>>             t.setTag( bites, 6 ) ;
>>> @@ -699,7 +699,7 @@
>>>         t.setTag( bites, 1 ) ;
>>>         String binary = toAsciiString( bites ) ;
>>>         assertEquals( "01100000", binary ) ;
>>> -        +
>>>         bites = ByteBuffer.allocate( 1 ) ;
>>>         t = new Tuple( 30, 0 ) ;
>>>         t.setTag( bites, 1 ) ;
>>> @@ -735,8 +735,8 @@
>>>         t = new Tuple( BIT_13 - 1, 0 ) ;
>>>         t.setTag( bites, 3 ) ;
>>>         binary = toAsciiString( bites ) ;
>>> -        assertEquals( "01111111" + -                      
>>> "11111111" + +        assertEquals( "01111111" +
>>> +                      "11111111" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 4 ) ;
>>> @@ -745,7 +745,7 @@
>>>         binary = toAsciiString( bites ) ;
>>>         assertEquals( "00000000" +
>>>                       "10000000" +
>>> -                      "10000001" + +                      "10000001" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 4 ) ;
>>> @@ -754,16 +754,16 @@
>>>         binary = toAsciiString( bites ) ;
>>>         assertEquals( "00000001" +
>>>                       "10000000" +
>>> -                      "10000001" + +                      "10000001" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 4 ) ;
>>>         t = new Tuple( BIT_20 - 1, 0 ) ;
>>>         t.setTag( bites, 4 ) ;
>>>         binary = toAsciiString( bites ) ;
>>> -        assertEquals( "01111111" + -                      
>>> "11111111" + -                      "11111111" + +        
>>> assertEquals( "01111111" +
>>> +                      "11111111" +
>>> +                      "11111111" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 5 ) ;
>>> @@ -773,7 +773,7 @@
>>>         assertEquals( "00000000" +
>>>                       "10000000" +
>>>                       "10000000" +
>>> -                      "10000001" + +                      "10000001" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 5 ) ;
>>> @@ -783,22 +783,22 @@
>>>         assertEquals( "00000001" +
>>>                       "10000000" +
>>>                       "10000000" +
>>> -                      "10000001" + +                      "10000001" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 5 ) ;
>>>         t = new Tuple( BIT_27 - 1, 0 ) ;
>>>         t.setTag( bites, 5 ) ;
>>>         binary = toAsciiString( bites ) ;
>>> -        assertEquals( "01111111" + -                      
>>> "11111111" + -                      "11111111" + 
>>> -                      "11111111" + +        assertEquals( "01111111" +
>>> +                      "11111111" +
>>> +                      "11111111" +
>>> +                      "11111111" +
>>>                       "01111111", binary ) ;
>>>
>>>         bites = ByteBuffer.allocate( 6 ) ;
>>>         t = new Tuple( BIT_27, 0 ) ;
>>> -        +
>>>         try
>>>         {
>>>             t.setTag( bites, 6 ) ;
>>> @@ -809,8 +809,8 @@
>>>             assertNotNull( e ) ;
>>>         }
>>>     }
>>> -    -    +
>>> +
>>>     String toAsciiString( int raw )
>>>     {
>>>         byte[] intBytes = new byte[4] ;
>>> @@ -818,10 +818,10 @@
>>>         intBytes[1] = (byte) ( (int) ( 0x0000ff00 & raw ) >> 8 ) ;
>>>         intBytes[2] = (byte) ( (int) ( 0x00ff0000 & raw ) >> 16 ) ;
>>>         intBytes[3] = (byte) ( (int) ( 0xff000000 & raw ) >> 24 ) ;
>>> -        +
>>>         return BinaryCodec.toAsciiString( intBytes ) ;
>>>     }
>>> -    +
>>>
>>>     public void testSetLengthBuffer()
>>>     {
>>> @@ -1064,7 +1064,7 @@
>>>         assertEquals( 4, t.getTagLength() ) ;
>>>         t.id = BIT_13 + 100 ;
>>>         assertEquals( 4, t.getTagLength() ) ;
>>> -        +
>>>         t.id = BIT_20 - 1 ;
>>>         assertEquals( 4, t.getTagLength() ) ;
>>>         t.id = BIT_20 ;
>>> @@ -1076,7 +1076,7 @@
>>>         assertEquals( 5, t.getTagLength() ) ;
>>>
>>>         t.id = BIT_27 ;
>>> -        +
>>>         try
>>>         {
>>>             assertEquals( 6, t.getTagLength() ) ;
>>> @@ -1107,7 +1107,7 @@
>>>         assertEquals( 4, t.getLengthLength() ) ;
>>>         t.length = BIT_15 + 100 ;
>>>         assertEquals( 4, t.getLengthLength() ) ;
>>> -        +
>>>         t.length = BIT_23 - 1 ;
>>>         assertEquals( 4, t.getLengthLength() ) ;
>>>         t.length = BIT_23 ;
>>> @@ -1118,7 +1118,7 @@
>>>         t.length = Integer.MAX_VALUE ;
>>>         assertEquals( 5, t.getLengthLength() ) ;
>>>
>>> -        +
>>>         t.length = Integer.MAX_VALUE + 1 ;
>>>         try
>>>         {
>>> @@ -1129,6 +1129,6 @@
>>>         {
>>>             assertNotNull( e ) ;
>>>         }
>>> -        +
>>>     }
>>> }
>>>
>>> Modified: 
>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java 
>>>
>>> URL: 
>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java?view=diff&r1=155925&r2=155926 
>>>
>>> ============================================================================== 
>>>
>>> --- 
>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java 
>>> (original)
>>> +++ 
>>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java 
>>> Wed Mar  2 07:14:39 2005
>>> @@ -1,5 +1,5 @@
>>> /*
>>> - *   Copyright 2004 The Apache Software Foundation
>>> + *   Copyright 2004-2005 The Apache Software Foundation
>>>  *
>>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>>  *   you may not use this file except in compliance with the License.
>>> @@ -99,12 +99,12 @@
>>>
>>>
>>>     /**
>>> -     * Tests when the length is indefinate.
>>> +     * Tests when the length is indefinite.
>>>      */
>>> -    public void testIndefinateLength()
>>> +    public void testIndefiniteLength()
>>>     {
>>>         rule.tag( UniversalTag.OCTET_STRING.getTagId(), true, null ) ;
>>> -        rule.length( Length.INDEFINATE ) ;
>>> +        rule.length( Length.INDEFINITE ) ;
>>>         rule.finish() ;
>>>         ByteBuffer buf = ( ByteBuffer ) digester.pop() ;
>>>         assertFalse( buf.hasRemaining() ) ;
>>> @@ -112,12 +112,12 @@
>>>
>>>
>>>     /**
>>> -     * Tests when the length is indefinate.
>>> +     * Tests when the length is indefinite.
>>>      */
>>>     public void testNullValue()
>>>     {
>>>         rule.tag( UniversalTag.OCTET_STRING.getTagId(), true, null ) ;
>>> -        rule.length( Length.INDEFINATE ) ;
>>> +        rule.length( Length.INDEFINITE ) ;
>>>         rule.value( null ) ;
>>>         rule.value( ByteBuffer.allocate( 0 ) ) ;
>>>         rule.finish() ;
>>>
>>> Modified: incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml
>>> URL: 
>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml?view=diff&r1=155925&r2=155926 
>>>
>>> ============================================================================== 
>>>
>>> --- incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml 
>>> (original)
>>> +++ incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml 
>>> Wed Mar  2 07:14:39 2005
>>> @@ -22,7 +22,7 @@
>>>         <p>
>>>           A constructed TLV tuple contains other TLV tuples nested 
>>> within the
>>>           Value field, and so on, recursively.  The nesting depth is 
>>> usually
>>> -          indefinate and dependent on the data structures being 
>>> transformed.
>>> +          indefinite and dependent on the data structures being 
>>> transformed.
>>>           This fact drastically affects the way the decoder is 
>>> designed and
>>>           hence operates.
>>>         </p>
>>> @@ -61,7 +61,7 @@
>>>
>>>         <p>
>>>           Now let's try to figure out how to handle constructed TLV 
>>> tuples
>>> -          which recursively nest other tuples indefinately.  State now
>>> +          which recursively nest other tuples indefinitely.  State now
>>>           is more that just where you left off in the current tuple 
>>> being
>>>           processed.  When processing an inner tuple the decoder 
>>> must also know
>>>           where it left off in the outter tuple to resume 
>>> processing.  More
>>>
>>> Modified: 
>>> incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java 
>>>
>>> URL: 
>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java?view=diff&r1=155925&r2=155926 
>>>
>>> ============================================================================== 
>>>
>>> --- 
>>> incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java 
>>> (original)
>>> +++ 
>>> incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java 
>>> Wed Mar  2 07:14:39 2005
>>> @@ -1,5 +1,5 @@
>>> /*
>>> - *   Copyright 2004 The Apache Software Foundation
>>> + *   Copyright 2004-2005 The Apache Software Foundation
>>>  *
>>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>>  *   you may not use this file except in compliance with the License.
>>> @@ -36,33 +36,33 @@
>>>     private final LinkedList history ;
>>>     /** the length of callback history stored */
>>>     private final int length ;
>>> -    +
>>>
>>>     /**
>>> -     * Creates an auditing callback that manages a history of 
>>> indefinate length.
>>> +     * Creates an auditing callback that manages a history of 
>>> indefinite length.
>>>      */
>>>     public CallbackHistory()
>>>     {
>>>         this( -1 ) ;
>>>     }
>>> -    -    +
>>> +
>>>     /**
>>> -     * Creates an auditing callback that manages a history of fixed 
>>> or -     * indefinate length.  If the length is fixed the history 
>>> effectively +     * Creates an auditing callback that manages a 
>>> history of fixed or
>>> +     * indefinite length.  If the length is fixed the history 
>>> effectively
>>>      * becomes a FIFO structure.
>>> -     * +     *
>>>      * @param length the maximum length of callback history to store 
>>> before
>>> -     *  dropping decoded items, a length of zero or 1 corresponds 
>>> to indefinate
>>> -     *  history +     *  dropping decoded items, a length of zero 
>>> or 1 corresponds to indefinite
>>> +     *  history
>>>      */
>>>     public CallbackHistory( int length )
>>>     {
>>>         this.length = length ;
>>>         history = new LinkedList() ;
>>>     }
>>> -    -    +
>>> +
>>>     /* (non-Javadoc)
>>>      * @see 
>>> org.apache.asn1.codec.stateful.DecoderCallback#decodeOccurred(
>>>      * org.apache.asn1.codec.stateful.StatefulDecoder, 
>>> java.lang.Object)
>>> @@ -70,13 +70,13 @@
>>>     public void decodeOccurred( StatefulDecoder decoder, Object 
>>> decoded )
>>>     {
>>>         if ( length > 0 )
>>> -        {    +        {
>>>             while ( history.size() >= length )
>>>             {
>>>                 history.removeLast() ;
>>>             }
>>>         }
>>> -        +
>>>         history.addFirst( decoded ) ;
>>>     }
>>>
>>> @@ -103,7 +103,7 @@
>>>
>>>     /**
>>>      * Gets the most recent decoded object if one exists.
>>> -     * +     *
>>>      * @return the most recent decoded object
>>>      * @throws java.util.NoSuchElementException if the history is empty
>>>      */
>>> @@ -111,11 +111,11 @@
>>>     {
>>>         return history.getFirst() ;
>>>     }
>>> -    -    +
>>> +
>>>     /**
>>>      * Gets the oldest decoded object if one exists.
>>> -     * +     *
>>>      * @return the oldest decoded object
>>>      * @throws java.util.NoSuchElementException if the history is empty
>>>      */
>>> @@ -123,19 +123,19 @@
>>>     {
>>>         return history.getLast() ;
>>>     }
>>> -    -    +
>>> +
>>>     /**
>>>      * Tests to see if the history is empty.
>>> -     * +     *
>>>      * @return true if the history is empty, false otherwise
>>>      */
>>>     public boolean isEmpty()
>>>     {
>>>         return history.isEmpty() ;
>>>     }
>>> -    -    +
>>> +
>>>     /**
>>>      * Clears the history of decoded items.
>>>      */
>>> @@ -143,11 +143,11 @@
>>>     {
>>>         history.clear() ;
>>>     }
>>> -    -    +
>>> +
>>>     /**
>>>      * Gets the number of decoded items in the callback history.
>>> -     * +     *
>>>      * @return the number of decoded items in the callback history
>>>      */
>>>     public int size()
>>>
>>> Modified: incubator/directory/asn1/trunk/xdocs/refactor.xml
>>> URL: 
>>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/xdocs/refactor.xml?view=diff&r1=155925&r2=155926 
>>>
>>> ============================================================================== 
>>>
>>> --- incubator/directory/asn1/trunk/xdocs/refactor.xml (original)
>>> +++ incubator/directory/asn1/trunk/xdocs/refactor.xml Wed Mar  2 
>>> 07:14:39 2005
>>> @@ -166,7 +166,7 @@
>>>           are still abstract.  This is because we need to 
>>> differentiate further
>>>           for buffered verses streamed Tuples in the case of 
>>> primitive Tuples.
>>>           For constructed Tuples we need to differentiate between 
>>> definate
>>> -          length verses indefinate length Tuples.  With our 
>>> approach, only the +          length verses indefinite length 
>>> Tuples.  With our approach, only the           leaf nodes of the 
>>> inheritance hierarchy will be concrete.  Below is
>>>           the definition for the PrimitiveTuple.
>>>         </p>
>>> @@ -251,10 +251,10 @@
>>>
>>>     /**
>>>      * Gets whether or not the length of this constructed Tuple is 
>>> of the -     * definate form or of the indefinate length form.
>>> +     * definate form or of the indefinite length form.
>>>      *
>>>      * @return true if the length is definate, false if the length 
>>> is of the
>>> -     * indefinate form
>>> +     * indefinite form
>>>      */
>>>     public abstract boolean isLengthDefinate();
>>> }
>>> @@ -264,21 +264,21 @@
>>>           ConstructedTuple implements the 
>>> <code>isConstructed()</code> method           as final since it will 
>>> always return false for this lineage of           Tuples.  Also a 
>>> new abstract method isLengthDefinate() is introduced -          to 
>>> see if the Tuple uses the indefinate length form or not.  +          
>>> to see if the Tuple uses the indefinite length form or not.          
>>> </p>
>>>       </subsection>
>>>
>>> -      <subsection name="Definate Vs. Indefinate Length">
>>> +      <subsection name="Definate Vs. Indefinite Length">
>>>         <p>
>>>           The ConstructedTuple can be further differentiated into 
>>> two -          subclasses to represent definate and indefinate 
>>> length constructed -          TLV Tuples.  The indefinate form does 
>>> not have a length value +          subclasses to represent definate 
>>> and indefinite length constructed +          TLV Tuples.  The 
>>> indefinite form does not have a length value           associated 
>>> with it where as the definate lenght form does.  Let's
>>> -          explore the concrete IndefinateLegthTuple definition.
>>> +          explore the concrete IndefiniteLegthTuple definition.
>>>         </p>
>>>
>>> <source>
>>> -public class IndefinateLength extends ConstructedTuple
>>> +public class IndefiniteLength extends ConstructedTuple
>>> {
>>>     public final boolean isLengthDefinate()
>>>     {
>>>
>>>
>>>
>>>  
>>>
>
>


Re: svn commit: r155926 [2/2] - in incubator/directory/asn1/trunk: ber/src/java/org/apache/asn1/ber/ ber/src/java/org/apache/asn1/ber/digester/rules/ ber/src/test/org/apache/asn1/ber/ ber/src/test/org/apache/asn1/ber/digester/rules/ ber/xdocs/ codec/src/java/org/apache/asn1/codec/stateful/ xdocs/

Posted by "Alan D. Cabrera" <ad...@toolazydogs.com>.
The word indefinite was misspelled  If you look carefully, you'll see 
that each file has it corrected.  It seems that my editor removed the 
extra spaces on the end of some lines.


Regards,
Alan

Alex Karasulu wrote:

> Alan I don't see these diffs doing anything.  What was the point for 
> these modifications?
>
> Alex
>
> adc@apache.org wrote:
>
>> Modified: 
>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java 
>>
>> URL: 
>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java?view=diff&r1=155925&r2=155926 
>>
>> ============================================================================== 
>>
>> --- 
>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java 
>> (original)
>> +++ 
>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/DefaultMutableTupleNodeTest.java 
>> Wed Mar  2 07:14:39 2005
>> @@ -1,5 +1,5 @@
>> /*
>> - *   Copyright 2004 The Apache Software Foundation
>> + *   Copyright 2004-2005 The Apache Software Foundation
>>  *
>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>  *   you may not use this file except in compliance with the License.
>> @@ -37,7 +37,7 @@
>> {
>>     public DefaultMutableTupleNodeTest()
>>     {
>> -        super ( DefaultMutableTupleNodeTest.class.getName() ) ; 
>> +        super ( DefaultMutableTupleNodeTest.class.getName() ) ;
>>     }
>>
>>
>> @@ -85,7 +85,7 @@
>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>         node.setParent( (MutableTupleNode) parent) ;
>> -        +
>>         assertEquals(1,parent.getChildCount()) ;
>>         node.removeFromParent() ;
>>         assertEquals(0,parent.getChildCount()) ;
>> @@ -147,7 +147,7 @@
>>         assertTrue( parent.getChildren().hasNext()) ;
>>     }
>>
>> -    +
>>     public void testGetChildTupleNodeAt()
>>     {
>>     }
>> @@ -175,13 +175,13 @@
>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>         node.setParent( (MutableTupleNode) parent) ;
>> -        +
>>         Tuple primitive = new Tuple( 1, 3, true, 
>> TypeClass.APPLICATION ) ;
>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>         parent.setTuple( constructed ) ;
>>         node.setTuple( primitive ) ;
>> -        -        // fact that we use the indefinate form we 
>> automatically add two to
>> +
>> +        // fact that we use the indefinite form we automatically add 
>> two to
>>         // the contained size
>>         assertEquals(9, parent.size()) ;
>>     }
>> @@ -192,12 +192,12 @@
>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>         node.setParent( (MutableTupleNode) parent) ;
>> -        +
>>         Tuple primitive = new Tuple( 1, 3, true, 
>> TypeClass.APPLICATION ) ;
>>         Tuple constructed = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>         parent.setTuple( constructed ) ;
>>         node.setTuple( primitive ) ;
>> -        +
>>         assertEquals(7, parent.size()) ;
>>     }
>>
>> @@ -206,7 +206,7 @@
>>         DefaultMutableTupleNode parent = new DefaultMutableTupleNode() ;
>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>         parent.setTuple( constructed ) ;
>> -        +
>>         assertEquals(4, parent.size()) ;
>>     }
>>
>> @@ -219,7 +219,7 @@
>>         ByteBuffer buf = ByteBuffer.allocate( 4 ) ;
>>         parent.encode( buf ) ;
>>
>> -        +
>>         /*
>>         final ArrayList list = new ArrayList() ;
>>         TupleTreeDecoder decoder = new TupleTreeDecoder() ;
>> @@ -228,10 +228,10 @@
>>             {
>>                 list.add( arg1 ) ;
>>             }}) ;
>> -        +
>>         decoder.decode(buf.flip()) ;
>> -        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode 
>> ) -            list.get(0); +        DefaultMutableTupleNode decoded 
>> = ( DefaultMutableTupleNode )
>> +            list.get(0);
>>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>>         */
>>     }
>> @@ -248,13 +248,13 @@
>>     {
>>         DefaultMutableTupleNode parent = new DefaultMutableTupleNode() ;
>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>> -        +
>>         DefaultMutableTupleNode end = new DefaultMutableTupleNode() ;
>>         parent.insert( (MutableTupleNode) end, 0 ) ;
>>         end.setParent( (MutableTupleNode) parent) ;
>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>         node.setParent( (MutableTupleNode) parent) ;
>> -        +
>>         Tuple primitive = new Tuple( 1, 3, true, 
>> TypeClass.APPLICATION ) ;
>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL 
>> ) ;
>> @@ -262,9 +262,9 @@
>>         parent.setTuple( constructed ) ;
>>         node.setTuple( primitive ) ;
>>         end.setTuple(terminator) ;
>> -        +
>>         assertEquals(9, parent.size()) ;
>> -        +
>>         ByteBuffer buf = ByteBuffer.allocate( 9 ) ;
>>         parent.encode( buf ) ;
>>
>> @@ -276,10 +276,10 @@
>>             {
>>                 list.add( arg1 ) ;
>>             }}) ;
>> -        +
>>         decoder.decode(buf.flip()) ;
>> -        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode 
>> ) -            list.get(0); +        DefaultMutableTupleNode decoded 
>> = ( DefaultMutableTupleNode )
>> +            list.get(0);
>>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>>         */
>>     }
>> @@ -290,15 +290,15 @@
>>         DefaultMutableTupleNode node = new DefaultMutableTupleNode() ;
>>         parent.insert( (MutableTupleNode) node, 0 ) ;
>>         node.setParent( (MutableTupleNode) parent) ;
>> -        +
>>         Tuple primitive = new Tuple( 1, 3, true, 
>> TypeClass.APPLICATION ) ;
>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>         parent.setTuple( constructed ) ;
>>         node.setTuple( primitive ) ;
>> -        -        // 2 extra bytes added for indefinate form
>> +
>> +        // 2 extra bytes added for indefinite form
>>         assertEquals(9, parent.size()) ;
>> -        +
>>         ByteBuffer buf = ByteBuffer.allocate( 9 ) ;
>>         parent.encode( buf ) ;
>>
>> @@ -310,10 +310,10 @@
>>             {
>>                 list.add( arg1 ) ;
>>             }}) ;
>> -        +
>>         decoder.decode(buf.flip()) ;
>> -        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode 
>> ) -            list.get(0); +        DefaultMutableTupleNode decoded 
>> = ( DefaultMutableTupleNode )
>> +            list.get(0);
>>         assertEquals( decoded.getTuple(), parent.getTuple()) ;
>>         */
>>     }
>> @@ -327,18 +327,18 @@
>>         middle.setParent( (MutableTupleNode) top) ;
>>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>>         bottom.setParent( (MutableTupleNode) middle) ;
>> -        +
>>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>         Tuple bottomTuple = new Tuple( 3, 1, true, 
>> TypeClass.APPLICATION ) ;
>> -        +
>>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>>         top.setTuple( topTuple ) ;
>>         middle.setTuple( middleTuple ) ;
>>         bottom.setTuple( bottomTuple ) ;
>> -        +
>>         assertEquals(7, top.size()) ;
>> -        +
>>         ByteBuffer buf = ByteBuffer.allocate( 7 ) ;
>>         top.encode( buf ) ;
>>
>> @@ -350,15 +350,15 @@
>>             {
>>                 list.add( arg1 ) ;
>>             }}) ;
>> -        +
>>         decoder.decode(buf.flip()) ;
>> -        DefaultMutableTupleNode decoded = ( DefaultMutableTupleNode 
>> ) -            list.get(0); +        DefaultMutableTupleNode decoded 
>> = ( DefaultMutableTupleNode )
>> +            list.get(0);
>>         assertEquals( decoded.getTuple(), top.getTuple()) ;
>>         */
>>     }
>>
>> -    +
>>     public void testEquals()
>>     {
>>         DefaultMutableTupleNode top = new DefaultMutableTupleNode() ;
>> @@ -368,18 +368,18 @@
>>         middle.setParent( (MutableTupleNode) top) ;
>>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>>         bottom.setParent( (MutableTupleNode) middle) ;
>> -        +
>>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>         Tuple bottomTuple = new Tuple( 3, 1, true, 
>> TypeClass.APPLICATION ) ;
>> -        +
>>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>>         top.setTuple( topTuple ) ;
>>         middle.setTuple( middleTuple ) ;
>>         bottom.setTuple( bottomTuple ) ;
>>
>>         assertTrue( top.equals( top ) ) ;
>> -        +
>>         DefaultMutableTupleNode topClone = new 
>> DefaultMutableTupleNode() ;
>>         topClone.setTuple( topTuple ) ;
>>         assertFalse( top.equals(topClone)) ;
>> @@ -387,7 +387,7 @@
>>         topClone = new DefaultMutableTupleNode() ;
>>         topClone.setTuple( bottomTuple ) ;
>>         assertFalse( top.equals(topClone)) ;
>> -        +
>>         topClone = new DefaultMutableTupleNode() ;
>>         DefaultMutableTupleNode middleClone = new 
>> DefaultMutableTupleNode() ;
>>         DefaultMutableTupleNode bottomClone = new 
>> DefaultMutableTupleNode() ;
>> @@ -395,11 +395,11 @@
>>         middleClone.setParent( (MutableTupleNode) topClone) ;
>>         middleClone.insert( (MutableTupleNode) bottomClone, 0 ) ;
>>         bottomClone.setParent( (MutableTupleNode) middleClone) ;
>> -        +
>>         Tuple middleTupleClone = new Tuple( 1, 3, 
>> TypeClass.APPLICATION  ) ;
>>         Tuple topTupleClone = new Tuple ( 2, 5, TypeClass.APPLICATION 
>> ) ;
>>         Tuple bottomTupleClone= new Tuple( 3, 1, true, 
>> TypeClass.APPLICATION ) ;
>> -        +
>>         bottomTupleClone.typeClass = TypeClass.UNIVERSAL ;
>>         topClone.setTuple( topTupleClone ) ;
>>         middleClone.setTuple( middleTupleClone ) ;
>> @@ -409,8 +409,8 @@
>>         assertTrue( middle.equals( middleClone ) ) ;
>>         assertTrue( top.equals( topClone ) ) ;
>>      }
>> -    -    +
>> +
>>     public void testEquals2()
>>     {
>>         DefaultMutableTupleNode top = new DefaultMutableTupleNode() ;
>> @@ -420,11 +420,11 @@
>>         middle.setParent( (MutableTupleNode) top) ;
>>         middle.insert( (MutableTupleNode) bottom, 0 ) ;
>>         bottom.setParent( (MutableTupleNode) middle) ;
>> -        +
>>         Tuple middleTuple = new Tuple( 1, 3, TypeClass.APPLICATION  ) ;
>>         Tuple topTuple = new Tuple ( 2, 5, TypeClass.APPLICATION ) ;
>>         Tuple bottomTuple = new Tuple( 3, 1, true, 
>> TypeClass.APPLICATION ) ;
>> -        +
>>         bottomTuple.typeClass = TypeClass.UNIVERSAL ;
>>         top.setTuple( topTuple ) ;
>>         middle.setTuple( middleTuple ) ;
>> @@ -433,7 +433,7 @@
>>         assertTrue( top.equals( top ) ) ;
>>
>>         top.printDepthFirst(new StringBuffer(), 0 ) ;
>> -        +
>>         DefaultMutableTupleNode topClone = new 
>> DefaultMutableTupleNode() ;
>>         topClone.setTuple( topTuple ) ;
>>         assertFalse( top.equals(topClone)) ;
>> @@ -441,7 +441,7 @@
>>         topClone = new DefaultMutableTupleNode() ;
>>         topClone.setTuple( bottomTuple ) ;
>>         assertFalse( top.equals(topClone)) ;
>> -        +
>>         topClone = new DefaultMutableTupleNode() ;
>>         DefaultMutableTupleNode middleClone = new 
>> DefaultMutableTupleNode() ;
>>         DefaultMutableTupleNode bottomClone = new 
>> DefaultMutableTupleNode() ;
>> @@ -449,11 +449,11 @@
>>         middleClone.setParent( (MutableTupleNode) topClone) ;
>>         middleClone.insert( (MutableTupleNode) bottomClone, 0 ) ;
>>         bottomClone.setParent( (MutableTupleNode) middleClone) ;
>> -        +
>>         Tuple middleTupleClone = new Tuple( 1, 3, 
>> TypeClass.APPLICATION  ) ;
>>         Tuple topTupleClone = new Tuple ( 2, 5, TypeClass.APPLICATION 
>> ) ;
>>         Tuple bottomTupleClone= new Tuple( 3, 1, true, 
>> TypeClass.APPLICATION ) ;
>> -        +
>>         bottomTupleClone.typeClass = TypeClass.UNIVERSAL ;
>>         topClone.setTuple( topTupleClone ) ;
>>         middleClone.setTuple( bottomTupleClone ) ;
>> @@ -465,8 +465,8 @@
>>         assertFalse( top.equals( new Object() ) ) ;
>>         assertFalse( top.equals( null ) ) ;
>>      }
>> -    -    +
>> +
>>     /*
>>      * Class to test for String toString()
>>      */
>> @@ -479,7 +479,7 @@
>>         end.setParent( parent) ;
>>         parent.insert( node, 0 ) ;
>>         node.setParent( parent) ;
>> -        +
>>         Tuple primitive = new Tuple( 1, 3, true, 
>> TypeClass.APPLICATION ) ;
>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL 
>> ) ;
>> @@ -487,7 +487,7 @@
>>         parent.setTuple( constructed ) ;
>>         node.setTuple( primitive ) ;
>>         end.setTuple( terminator ) ;
>> -        +
>>         assertNotNull( parent.toString() ) ;
>>     }
>>
>> @@ -500,7 +500,7 @@
>>         end.setParent( parent) ;
>>         parent.insert( node, 0 ) ;
>>         node.setParent( parent) ;
>> -        +
>>         Tuple primitive = new Tuple( 1, 3, true, 
>> TypeClass.APPLICATION ) ;
>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL 
>> ) ;
>> @@ -508,7 +508,7 @@
>>         parent.setTuple( constructed ) ;
>>         node.setTuple( primitive, Collections.EMPTY_LIST ) ;
>>         end.setTuple( terminator ) ;
>> -        +
>>         assertTrue( node.getValueChunks().isEmpty() ) ;
>>
>>
>> @@ -525,7 +525,7 @@
>>         end.setParent( parent) ;
>>         parent.insert( node, 0 ) ;
>>         node.setParent( parent) ;
>> -        +
>>         Tuple primitive = new Tuple( 1, 3, true, 
>> TypeClass.APPLICATION ) ;
>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL 
>> ) ;
>> @@ -533,18 +533,18 @@
>>         parent.setTuple( constructed ) ;
>>         node.setTuple( primitive ) ;
>>         end.setTuple( terminator ) ;
>> -        +
>>         Iterator list = parent.getChildren() ;
>> -        +
>>         assertEquals( node, list.next() ) ;
>>         assertEquals( end, list.next() ) ;
>> -        +
>>         try
>>         {
>>             list.next() ;
>>             fail( "should never get here due to thrown exception" ) ;
>>         }
>> -        catch( Throwable t ) +        catch( Throwable t )
>>         {
>>             assertNotNull( t ) ;
>>         }
>> @@ -559,7 +559,7 @@
>>         end.setParent( parent) ;
>>         parent.insert( node, 0 ) ;
>>         node.setParent( parent) ;
>> -        +
>>         Tuple primitive = new Tuple( 1, 3, true, 
>> TypeClass.APPLICATION ) ;
>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL 
>> ) ;
>> @@ -578,7 +578,7 @@
>>         end.setParent( parent) ;
>>         parent.addFront( node ) ;
>>         node.setParent( parent) ;
>> -        +
>>         Tuple primitive = new Tuple( 1, 3, true, 
>> TypeClass.APPLICATION ) ;
>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL 
>> ) ;
>> @@ -589,7 +589,7 @@
>>         parent.toDepthFirstString() ;
>>     }
>>
>> -    +
>>     public void testAddLast()
>>     {
>>         DefaultMutableTupleNode parent = new DefaultMutableTupleNode() ;
>> @@ -599,7 +599,7 @@
>>         node.setParent( (MutableTupleNode) parent) ;
>>         parent.addLast( end ) ;
>>         end.setParent( (MutableTupleNode) parent) ;
>> -        +
>>         Tuple primitive = new Tuple( 1, 3, true, 
>> TypeClass.APPLICATION ) ;
>>         Tuple constructed = new Tuple ( 2, TypeClass.APPLICATION ) ;
>>         Tuple terminator = new Tuple( 0, 0, true, TypeClass.UNIVERSAL 
>> ) ;
>>
>> Modified: 
>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java 
>>
>> URL: 
>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java?view=diff&r1=155925&r2=155926 
>>
>> ============================================================================== 
>>
>> --- 
>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java 
>> (original)
>> +++ 
>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/TupleTest.java 
>> Wed Mar  2 07:14:39 2005
>> @@ -1,5 +1,5 @@
>> /*
>> - *   Copyright 2004 The Apache Software Foundation
>> + *   Copyright 2004-2005 The Apache Software Foundation
>>  *
>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>  *   you may not use this file except in compliance with the License.
>> @@ -142,14 +142,14 @@
>>         assertEquals( 2, t.getId() ) ;
>>         assertEquals( TypeClass.PRIVATE, t.getTypeClass() ) ;
>>         assertEquals( false, t.isPrimitive() ) ;
>> -        assertEquals( Length.INDEFINATE, t.getLength() ) ;
>> +        assertEquals( Length.INDEFINITE, t.getLength() ) ;
>>         assertEquals( EMPTY_BUFFER, t.getLastValueChunk() ) ;
>>
>>         t = new Tuple( 2, (TypeClass) null ) ;
>>         assertEquals( 2, t.getId() ) ;
>>         assertEquals( TypeClass.APPLICATION, t.getTypeClass() ) ;
>>         assertEquals( false, t.isPrimitive() ) ;
>> -        assertEquals( Length.INDEFINATE, t.getLength() ) ;
>> +        assertEquals( Length.INDEFINITE, t.getLength() ) ;
>>         assertEquals( EMPTY_BUFFER, t.getLastValueChunk() ) ;
>>     }
>>
>> @@ -162,8 +162,8 @@
>>         t.id = 21 ;
>>         assertEquals( 21, t.getId() ) ;
>>     }
>> -    -    +
>> +
>>     public void testSize()
>>     {
>>         Tuple t = new Tuple( 1, TypeClass.APPLICATION ) ;
>> @@ -178,7 +178,7 @@
>>         assertEquals( 5, t.size() ) ;
>>         t.id = 1 << 21 ;
>>         assertEquals( 6, t.size() ) ;
>> -        +
>>         t.length = 127 ;
>>         assertEquals( 6+127, t.size() ) ;
>>         t.length = 128 ;
>> @@ -188,28 +188,28 @@
>>         t.length = 256 ;
>>         assertEquals( 8+256, t.size() ) ;
>>     }
>> -    -    -    public void testIsIndefinate()
>> +
>> +
>> +    public void testIsIndefinite()
>>     {
>>         Tuple t = new Tuple() ;
>> -        assertFalse( t.isIndefinate() ) ;
>> -        t.length = Length.INDEFINATE ;
>> -        assertTrue( t.isIndefinate() ) ;
>> +        assertFalse( t.isIndefinite() ) ;
>> +        t.length = Length.INDEFINITE ;
>> +        assertTrue( t.isIndefinite() ) ;
>>     }
>> -   
>> -    public void testIsIndefinateTerminator()
>> +
>> +    public void testIsIndefiniteTerminator()
>>     {
>>         Tuple t = new Tuple() ;
>> -        assertFalse( t.isIndefinateTerminator() ) ;
>> +        assertFalse( t.isIndefiniteTerminator() ) ;
>>         t.id = 0 ;
>>         t.length = 0 ;
>>         t.isPrimitive = true ;
>>         t.typeClass = TypeClass.UNIVERSAL ;
>> -        assertTrue( t.isIndefinateTerminator() ) ;
>> +        assertTrue( t.isIndefiniteTerminator() ) ;
>>     }
>> -    +
>>
>>     public void testIsPrimitive()
>>     {
>> @@ -300,13 +300,13 @@
>>         Tuple tnull1 = new Tuple() ;
>>         tnull1.valueChunk = null ;
>>         tnull0.equals( tnull1 ) ;
>> -        +
>>         tnull1.equals( tnull1 ) ;
>>         tnull0.equals( tnull0 ) ;
>> -        +
>>         Tuple t0 = new Tuple() ;
>>         Tuple t1 = ( Tuple ) t0.clone() ;
>> -        +
>>         assertTrue( t0.equals( t1 ) ) ;
>>         t0.id = 23 ;
>>         assertFalse( t0.equals( t1 ) ) ;
>> @@ -346,10 +346,10 @@
>>
>>         t0.valueChunk = ByteBuffer.allocate( 4 ) ;
>>         t1.valueChunk = null ;
>> -        +
>>         // The buffer does not factor into equality
>>         assertTrue( t0.equals( t1 ) ) ;
>> -        +
>>         t1 = ( Tuple ) t0.clone() ;
>>         assertTrue( t0.equals( t1 ) ) ;
>>
>> @@ -567,13 +567,13 @@
>>                 , toAsciiString( encoded ) ) ;
>>     }
>>
>> -    +
>>     public String toAsciiString( ByteBuffer buf )
>>     {
>>         return BinaryCodec.toAsciiString( buf.array() ) ;
>>     }
>> -    -    +
>> +
>>     public void testSetTagBufferint()
>>     {
>>         ByteBuffer bites = ByteBuffer.allocate( 1 ) ;
>> @@ -581,7 +581,7 @@
>>         t.setTag( bites, 1 ) ;
>>         String binary = toAsciiString( bites ) ;
>>         assertEquals( "01100000", binary ) ;
>> -        +
>>         bites = ByteBuffer.allocate( 1 ) ;
>>         t = new Tuple( 30, 0 ) ;
>>         t.setTag( bites, 1 ) ;
>> @@ -617,8 +617,8 @@
>>         t = new Tuple( BIT_13 - 1, 0 ) ;
>>         t.setTag( bites, 3 ) ;
>>         binary = toAsciiString( bites ) ;
>> -        assertEquals( "01111111" + -                      "11111111" 
>> + +        assertEquals( "01111111" +
>> +                      "11111111" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 4 ) ;
>> @@ -627,7 +627,7 @@
>>         binary = toAsciiString( bites ) ;
>>         assertEquals( "00000000" +
>>                       "10000000" +
>> -                      "10000001" + +                      "10000001" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 4 ) ;
>> @@ -636,16 +636,16 @@
>>         binary = toAsciiString( bites ) ;
>>         assertEquals( "00000001" +
>>                       "10000000" +
>> -                      "10000001" + +                      "10000001" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 4 ) ;
>>         t = new Tuple( BIT_20 - 1, 0 ) ;
>>         t.setTag( bites, 4 ) ;
>>         binary = toAsciiString( bites ) ;
>> -        assertEquals( "01111111" + -                      "11111111" 
>> + -                      "11111111" + +        assertEquals( 
>> "01111111" +
>> +                      "11111111" +
>> +                      "11111111" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 5 ) ;
>> @@ -655,7 +655,7 @@
>>         assertEquals( "00000000" +
>>                       "10000000" +
>>                       "10000000" +
>> -                      "10000001" + +                      "10000001" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 5 ) ;
>> @@ -665,22 +665,22 @@
>>         assertEquals( "00000001" +
>>                       "10000000" +
>>                       "10000000" +
>> -                      "10000001" + +                      "10000001" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 5 ) ;
>>         t = new Tuple( BIT_27 - 1, 0 ) ;
>>         t.setTag( bites, 5 ) ;
>>         binary = toAsciiString( bites ) ;
>> -        assertEquals( "01111111" + -                      "11111111" 
>> + -                      "11111111" + -                      
>> "11111111" + +        assertEquals( "01111111" +
>> +                      "11111111" +
>> +                      "11111111" +
>> +                      "11111111" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 6 ) ;
>>         t = new Tuple( BIT_27, 0 ) ;
>> -        +
>>         try
>>         {
>>             t.setTag( bites, 6 ) ;
>> @@ -699,7 +699,7 @@
>>         t.setTag( bites, 1 ) ;
>>         String binary = toAsciiString( bites ) ;
>>         assertEquals( "01100000", binary ) ;
>> -        +
>>         bites = ByteBuffer.allocate( 1 ) ;
>>         t = new Tuple( 30, 0 ) ;
>>         t.setTag( bites, 1 ) ;
>> @@ -735,8 +735,8 @@
>>         t = new Tuple( BIT_13 - 1, 0 ) ;
>>         t.setTag( bites, 3 ) ;
>>         binary = toAsciiString( bites ) ;
>> -        assertEquals( "01111111" + -                      "11111111" 
>> + +        assertEquals( "01111111" +
>> +                      "11111111" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 4 ) ;
>> @@ -745,7 +745,7 @@
>>         binary = toAsciiString( bites ) ;
>>         assertEquals( "00000000" +
>>                       "10000000" +
>> -                      "10000001" + +                      "10000001" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 4 ) ;
>> @@ -754,16 +754,16 @@
>>         binary = toAsciiString( bites ) ;
>>         assertEquals( "00000001" +
>>                       "10000000" +
>> -                      "10000001" + +                      "10000001" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 4 ) ;
>>         t = new Tuple( BIT_20 - 1, 0 ) ;
>>         t.setTag( bites, 4 ) ;
>>         binary = toAsciiString( bites ) ;
>> -        assertEquals( "01111111" + -                      "11111111" 
>> + -                      "11111111" + +        assertEquals( 
>> "01111111" +
>> +                      "11111111" +
>> +                      "11111111" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 5 ) ;
>> @@ -773,7 +773,7 @@
>>         assertEquals( "00000000" +
>>                       "10000000" +
>>                       "10000000" +
>> -                      "10000001" + +                      "10000001" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 5 ) ;
>> @@ -783,22 +783,22 @@
>>         assertEquals( "00000001" +
>>                       "10000000" +
>>                       "10000000" +
>> -                      "10000001" + +                      "10000001" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 5 ) ;
>>         t = new Tuple( BIT_27 - 1, 0 ) ;
>>         t.setTag( bites, 5 ) ;
>>         binary = toAsciiString( bites ) ;
>> -        assertEquals( "01111111" + -                      "11111111" 
>> + -                      "11111111" + -                      
>> "11111111" + +        assertEquals( "01111111" +
>> +                      "11111111" +
>> +                      "11111111" +
>> +                      "11111111" +
>>                       "01111111", binary ) ;
>>
>>         bites = ByteBuffer.allocate( 6 ) ;
>>         t = new Tuple( BIT_27, 0 ) ;
>> -        +
>>         try
>>         {
>>             t.setTag( bites, 6 ) ;
>> @@ -809,8 +809,8 @@
>>             assertNotNull( e ) ;
>>         }
>>     }
>> -    -    +
>> +
>>     String toAsciiString( int raw )
>>     {
>>         byte[] intBytes = new byte[4] ;
>> @@ -818,10 +818,10 @@
>>         intBytes[1] = (byte) ( (int) ( 0x0000ff00 & raw ) >> 8 ) ;
>>         intBytes[2] = (byte) ( (int) ( 0x00ff0000 & raw ) >> 16 ) ;
>>         intBytes[3] = (byte) ( (int) ( 0xff000000 & raw ) >> 24 ) ;
>> -        +
>>         return BinaryCodec.toAsciiString( intBytes ) ;
>>     }
>> -    +
>>
>>     public void testSetLengthBuffer()
>>     {
>> @@ -1064,7 +1064,7 @@
>>         assertEquals( 4, t.getTagLength() ) ;
>>         t.id = BIT_13 + 100 ;
>>         assertEquals( 4, t.getTagLength() ) ;
>> -        +
>>         t.id = BIT_20 - 1 ;
>>         assertEquals( 4, t.getTagLength() ) ;
>>         t.id = BIT_20 ;
>> @@ -1076,7 +1076,7 @@
>>         assertEquals( 5, t.getTagLength() ) ;
>>
>>         t.id = BIT_27 ;
>> -        +
>>         try
>>         {
>>             assertEquals( 6, t.getTagLength() ) ;
>> @@ -1107,7 +1107,7 @@
>>         assertEquals( 4, t.getLengthLength() ) ;
>>         t.length = BIT_15 + 100 ;
>>         assertEquals( 4, t.getLengthLength() ) ;
>> -        +
>>         t.length = BIT_23 - 1 ;
>>         assertEquals( 4, t.getLengthLength() ) ;
>>         t.length = BIT_23 ;
>> @@ -1118,7 +1118,7 @@
>>         t.length = Integer.MAX_VALUE ;
>>         assertEquals( 5, t.getLengthLength() ) ;
>>
>> -        +
>>         t.length = Integer.MAX_VALUE + 1 ;
>>         try
>>         {
>> @@ -1129,6 +1129,6 @@
>>         {
>>             assertNotNull( e ) ;
>>         }
>> -        +
>>     }
>> }
>>
>> Modified: 
>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java 
>>
>> URL: 
>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java?view=diff&r1=155925&r2=155926 
>>
>> ============================================================================== 
>>
>> --- 
>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java 
>> (original)
>> +++ 
>> incubator/directory/asn1/trunk/ber/src/test/org/apache/asn1/ber/digester/rules/PrimitiveOctetStringRuleTest.java 
>> Wed Mar  2 07:14:39 2005
>> @@ -1,5 +1,5 @@
>> /*
>> - *   Copyright 2004 The Apache Software Foundation
>> + *   Copyright 2004-2005 The Apache Software Foundation
>>  *
>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>  *   you may not use this file except in compliance with the License.
>> @@ -99,12 +99,12 @@
>>
>>
>>     /**
>> -     * Tests when the length is indefinate.
>> +     * Tests when the length is indefinite.
>>      */
>> -    public void testIndefinateLength()
>> +    public void testIndefiniteLength()
>>     {
>>         rule.tag( UniversalTag.OCTET_STRING.getTagId(), true, null ) ;
>> -        rule.length( Length.INDEFINATE ) ;
>> +        rule.length( Length.INDEFINITE ) ;
>>         rule.finish() ;
>>         ByteBuffer buf = ( ByteBuffer ) digester.pop() ;
>>         assertFalse( buf.hasRemaining() ) ;
>> @@ -112,12 +112,12 @@
>>
>>
>>     /**
>> -     * Tests when the length is indefinate.
>> +     * Tests when the length is indefinite.
>>      */
>>     public void testNullValue()
>>     {
>>         rule.tag( UniversalTag.OCTET_STRING.getTagId(), true, null ) ;
>> -        rule.length( Length.INDEFINATE ) ;
>> +        rule.length( Length.INDEFINITE ) ;
>>         rule.value( null ) ;
>>         rule.value( ByteBuffer.allocate( 0 ) ) ;
>>         rule.finish() ;
>>
>> Modified: incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml
>> URL: 
>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml?view=diff&r1=155925&r2=155926 
>>
>> ============================================================================== 
>>
>> --- incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml 
>> (original)
>> +++ incubator/directory/asn1/trunk/ber/xdocs/BERDecoderDesign.xml Wed 
>> Mar  2 07:14:39 2005
>> @@ -22,7 +22,7 @@
>>         <p>
>>           A constructed TLV tuple contains other TLV tuples nested 
>> within the
>>           Value field, and so on, recursively.  The nesting depth is 
>> usually
>> -          indefinate and dependent on the data structures being 
>> transformed.
>> +          indefinite and dependent on the data structures being 
>> transformed.
>>           This fact drastically affects the way the decoder is 
>> designed and
>>           hence operates.
>>         </p>
>> @@ -61,7 +61,7 @@
>>
>>         <p>
>>           Now let's try to figure out how to handle constructed TLV 
>> tuples
>> -          which recursively nest other tuples indefinately.  State now
>> +          which recursively nest other tuples indefinitely.  State now
>>           is more that just where you left off in the current tuple 
>> being
>>           processed.  When processing an inner tuple the decoder must 
>> also know
>>           where it left off in the outter tuple to resume 
>> processing.  More
>>
>> Modified: 
>> incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java 
>>
>> URL: 
>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java?view=diff&r1=155925&r2=155926 
>>
>> ============================================================================== 
>>
>> --- 
>> incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java 
>> (original)
>> +++ 
>> incubator/directory/asn1/trunk/codec/src/java/org/apache/asn1/codec/stateful/CallbackHistory.java 
>> Wed Mar  2 07:14:39 2005
>> @@ -1,5 +1,5 @@
>> /*
>> - *   Copyright 2004 The Apache Software Foundation
>> + *   Copyright 2004-2005 The Apache Software Foundation
>>  *
>>  *   Licensed under the Apache License, Version 2.0 (the "License");
>>  *   you may not use this file except in compliance with the License.
>> @@ -36,33 +36,33 @@
>>     private final LinkedList history ;
>>     /** the length of callback history stored */
>>     private final int length ;
>> -    +
>>
>>     /**
>> -     * Creates an auditing callback that manages a history of 
>> indefinate length.
>> +     * Creates an auditing callback that manages a history of 
>> indefinite length.
>>      */
>>     public CallbackHistory()
>>     {
>>         this( -1 ) ;
>>     }
>> -    -    +
>> +
>>     /**
>> -     * Creates an auditing callback that manages a history of fixed 
>> or -     * indefinate length.  If the length is fixed the history 
>> effectively +     * Creates an auditing callback that manages a 
>> history of fixed or
>> +     * indefinite length.  If the length is fixed the history 
>> effectively
>>      * becomes a FIFO structure.
>> -     * +     *
>>      * @param length the maximum length of callback history to store 
>> before
>> -     *  dropping decoded items, a length of zero or 1 corresponds to 
>> indefinate
>> -     *  history +     *  dropping decoded items, a length of zero or 
>> 1 corresponds to indefinite
>> +     *  history
>>      */
>>     public CallbackHistory( int length )
>>     {
>>         this.length = length ;
>>         history = new LinkedList() ;
>>     }
>> -    -    +
>> +
>>     /* (non-Javadoc)
>>      * @see 
>> org.apache.asn1.codec.stateful.DecoderCallback#decodeOccurred(
>>      * org.apache.asn1.codec.stateful.StatefulDecoder, java.lang.Object)
>> @@ -70,13 +70,13 @@
>>     public void decodeOccurred( StatefulDecoder decoder, Object 
>> decoded )
>>     {
>>         if ( length > 0 )
>> -        {    +        {
>>             while ( history.size() >= length )
>>             {
>>                 history.removeLast() ;
>>             }
>>         }
>> -        +
>>         history.addFirst( decoded ) ;
>>     }
>>
>> @@ -103,7 +103,7 @@
>>
>>     /**
>>      * Gets the most recent decoded object if one exists.
>> -     * +     *
>>      * @return the most recent decoded object
>>      * @throws java.util.NoSuchElementException if the history is empty
>>      */
>> @@ -111,11 +111,11 @@
>>     {
>>         return history.getFirst() ;
>>     }
>> -    -    +
>> +
>>     /**
>>      * Gets the oldest decoded object if one exists.
>> -     * +     *
>>      * @return the oldest decoded object
>>      * @throws java.util.NoSuchElementException if the history is empty
>>      */
>> @@ -123,19 +123,19 @@
>>     {
>>         return history.getLast() ;
>>     }
>> -    -    +
>> +
>>     /**
>>      * Tests to see if the history is empty.
>> -     * +     *
>>      * @return true if the history is empty, false otherwise
>>      */
>>     public boolean isEmpty()
>>     {
>>         return history.isEmpty() ;
>>     }
>> -    -    +
>> +
>>     /**
>>      * Clears the history of decoded items.
>>      */
>> @@ -143,11 +143,11 @@
>>     {
>>         history.clear() ;
>>     }
>> -    -    +
>> +
>>     /**
>>      * Gets the number of decoded items in the callback history.
>> -     * +     *
>>      * @return the number of decoded items in the callback history
>>      */
>>     public int size()
>>
>> Modified: incubator/directory/asn1/trunk/xdocs/refactor.xml
>> URL: 
>> http://svn.apache.org/viewcvs/incubator/directory/asn1/trunk/xdocs/refactor.xml?view=diff&r1=155925&r2=155926 
>>
>> ============================================================================== 
>>
>> --- incubator/directory/asn1/trunk/xdocs/refactor.xml (original)
>> +++ incubator/directory/asn1/trunk/xdocs/refactor.xml Wed Mar  2 
>> 07:14:39 2005
>> @@ -166,7 +166,7 @@
>>           are still abstract.  This is because we need to 
>> differentiate further
>>           for buffered verses streamed Tuples in the case of 
>> primitive Tuples.
>>           For constructed Tuples we need to differentiate between 
>> definate
>> -          length verses indefinate length Tuples.  With our 
>> approach, only the +          length verses indefinite length 
>> Tuples.  With our approach, only the           leaf nodes of the 
>> inheritance hierarchy will be concrete.  Below is
>>           the definition for the PrimitiveTuple.
>>         </p>
>> @@ -251,10 +251,10 @@
>>
>>     /**
>>      * Gets whether or not the length of this constructed Tuple is of 
>> the -     * definate form or of the indefinate length form.
>> +     * definate form or of the indefinite length form.
>>      *
>>      * @return true if the length is definate, false if the length is 
>> of the
>> -     * indefinate form
>> +     * indefinite form
>>      */
>>     public abstract boolean isLengthDefinate();
>> }
>> @@ -264,21 +264,21 @@
>>           ConstructedTuple implements the 
>> <code>isConstructed()</code> method           as final since it will 
>> always return false for this lineage of           Tuples.  Also a new 
>> abstract method isLengthDefinate() is introduced -          to see if 
>> the Tuple uses the indefinate length form or not.  +          to see 
>> if the Tuple uses the indefinite length form or not.          </p>
>>       </subsection>
>>
>> -      <subsection name="Definate Vs. Indefinate Length">
>> +      <subsection name="Definate Vs. Indefinite Length">
>>         <p>
>>           The ConstructedTuple can be further differentiated into two 
>> -          subclasses to represent definate and indefinate length 
>> constructed -          TLV Tuples.  The indefinate form does not have 
>> a length value +          subclasses to represent definate and 
>> indefinite length constructed +          TLV Tuples.  The indefinite 
>> form does not have a length value           associated with it where 
>> as the definate lenght form does.  Let's
>> -          explore the concrete IndefinateLegthTuple definition.
>> +          explore the concrete IndefiniteLegthTuple definition.
>>         </p>
>>
>> <source>
>> -public class IndefinateLength extends ConstructedTuple
>> +public class IndefiniteLength extends ConstructedTuple
>> {
>>     public final boolean isLengthDefinate()
>>     {
>>
>>
>>
>>  
>>