have BitVector.set() return this
authoradam <adam@megacz.com>
Mon, 3 Nov 2008 09:27:21 +0000 (10:27 +0100)
committeradam <adam@megacz.com>
Mon, 3 Nov 2008 09:27:21 +0000 (10:27 +0100)
src/edu/berkeley/fleet/api/BitVector.java

index f8127bf..df4eb71 100644 (file)
@@ -45,9 +45,11 @@ public class BitVector {
         return bits.length;
     }
     
-    public void set(int bit, boolean value) {
+    /** sets the specified bit to the given value */
+    public BitVector set(int bit, boolean value) {
         if (immutable) throw new RuntimeException("attempt to modify an immutable BitVector");
         bits[bit] = value;
+        return this;
     }
 
     public boolean get(int bit) {