test_class.file: wdtk-storage/src/test/java/org/wikidata/wdtk/storage/datastructures/BitVectorImplTest.java
test_class.identifier: BitVectorImplTest
test_case.body: @Test
  	public void testSetBit() {
  		long word = 0;
  
  		for (byte i = 0; i < 0x40; i++) {
  			word = BitVectorImpl.setBitInWord(i, true, word);
  		}
  
  		for (byte i = 0; i < 0x40; i++) {
  			Assert.assertTrue(BitVectorImpl.getBitInWord(i, word));
  		}
  
  		for (byte i = 0; i < 0x40; i++) {
  			word = BitVectorImpl.setBitInWord(i, false, word);
  		}
  
  		for (byte i = 0; i < 0x40; i++) {
  			Assert.assertFalse(BitVectorImpl.getBitInWord(i, word));
  		}
  
  		word = 0x0362;
  		for (byte i = 0; i < 0x40; i++) {
  			boolean value = BitVectorImpl.getBitInWord(i, word);
  			word = BitVectorImpl.setBitInWord(i, value, word);
  			Assert.assertEquals(value, BitVectorImpl.getBitInWord(i, word));
  
  			value = !value;
  			word = BitVectorImpl.setBitInWord(i, value, word);
  			Assert.assertEquals(value, BitVectorImpl.getBitInWord(i, word));
  
  			value = !value;
  			word = BitVectorImpl.setBitInWord(i, value, word);
  			Assert.assertEquals(value, BitVectorImpl.getBitInWord(i, word));
  		}
  
  		Assert.assertEquals(0x0362, word);
  
  	}
test_case.class_method_signature: BitVectorImplTest.testSetBit()
test_case.full_signature: @Test public void testSetBit()
test_case.identifier: testSetBit
test_case.invocations: setBitInWord assertTrue getBitInWord setBitInWord assertFalse getBitInWord getBitInWord setBitInWord assertEquals getBitInWord setBitInWord assertEquals getBitInWord setBitInWord assertEquals getBitInWord assertEquals
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testSetBit()
focal_class.declarator: GROWTH_FACTOR = 2
focal_class.modifier: static final
focal_class.original_string: static final int GROWTH_FACTOR = 2;
focal_class.type: int
focal_class.var_name: GROWTH_FACTOR
focal_class.declarator: LG_WORD_SIZE = 6
focal_class.modifier: static final
focal_class.original_string: static final int LG_WORD_SIZE = 6;
focal_class.type: int
focal_class.var_name: LG_WORD_SIZE
focal_class.declarator: MINIMUM_ARRAY_SIZE = 1
focal_class.modifier: static final
focal_class.original_string: static final int MINIMUM_ARRAY_SIZE = 1;
focal_class.type: int
focal_class.var_name: MINIMUM_ARRAY_SIZE
focal_class.declarator: WORD_MASK = 0x3F
focal_class.modifier: static final
focal_class.original_string: static final int WORD_MASK = 0x3F;
focal_class.type: int
focal_class.var_name: WORD_MASK
focal_class.declarator: WORD_SIZE = 0x40
focal_class.modifier: static final
focal_class.original_string: static final int WORD_SIZE = 0x40;
focal_class.type: int
focal_class.var_name: WORD_SIZE
focal_class.declarator: arrayOfBits
focal_class.original_string: long[] arrayOfBits;
focal_class.type: long[]
focal_class.var_name: arrayOfBits
focal_class.declarator: hashCode
focal_class.original_string: int hashCode;
focal_class.type: int
focal_class.var_name: hashCode
focal_class.declarator: size
focal_class.original_string: long size;
focal_class.type: long
focal_class.var_name: size
focal_class.declarator: validHashCode = false
focal_class.original_string: boolean validHashCode = false;
focal_class.type: boolean
focal_class.var_name: validHashCode
focal_class.file: wdtk-storage/src/main/java/org/wikidata/wdtk/storage/datastructures/BitVectorImpl.java
focal_class.identifier: BitVectorImpl
focal_class.interfaces: implements BitVector, Iterable<Boolean>
focal_class.class_method_signature: BitVectorImpl.BitVectorImpl()
focal_class.full_signature: public  BitVectorImpl()
focal_class.identifier: BitVectorImpl
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  BitVectorImpl()
focal_class.class_method_signature: BitVectorImpl.BitVectorImpl(BitVector bitVector)
focal_class.full_signature: public  BitVectorImpl(BitVector bitVector)
focal_class.identifier: BitVectorImpl
focal_class.modifiers: public
focal_class.parameters: (BitVector bitVector)
focal_class.signature:  BitVectorImpl(BitVector bitVector)
focal_class.class_method_signature: BitVectorImpl.BitVectorImpl(long initialSize)
focal_class.full_signature: public  BitVectorImpl(long initialSize)
focal_class.identifier: BitVectorImpl
focal_class.modifiers: public
focal_class.parameters: (long initialSize)
focal_class.signature:  BitVectorImpl(long initialSize)
focal_class.class_method_signature: BitVectorImpl.getBitInWord(byte position, long word)
focal_class.full_signature: static boolean getBitInWord(byte position, long word)
focal_class.identifier: getBitInWord
focal_class.modifiers: static
focal_class.parameters: (byte position, long word)
focal_class.return: boolean
focal_class.signature: boolean getBitInWord(byte position, long word)
focal_class.class_method_signature: BitVectorImpl.getMinimumArraySize(long bitVectorSize)
focal_class.full_signature: static int getMinimumArraySize(long bitVectorSize)
focal_class.identifier: getMinimumArraySize
focal_class.modifiers: static
focal_class.parameters: (long bitVectorSize)
focal_class.return: int
focal_class.signature: int getMinimumArraySize(long bitVectorSize)
focal_class.class_method_signature: BitVectorImpl.setBitInWord(byte position, boolean bit, long word)
focal_class.full_signature: static long setBitInWord(byte position, boolean bit, long word)
focal_class.identifier: setBitInWord
focal_class.modifiers: static
focal_class.parameters: (byte position, boolean bit, long word)
focal_class.return: long
focal_class.signature: long setBitInWord(byte position, boolean bit, long word)
focal_class.class_method_signature: BitVectorImpl.wordToString(long word)
focal_class.full_signature: static String wordToString(long word)
focal_class.identifier: wordToString
focal_class.modifiers: static
focal_class.parameters: (long word)
focal_class.return: String
focal_class.signature: String wordToString(long word)
focal_class.class_method_signature: BitVectorImpl.getSizeInWords(long sizeInBits)
focal_class.full_signature: static int getSizeInWords(long sizeInBits)
focal_class.identifier: getSizeInWords
focal_class.modifiers: static
focal_class.parameters: (long sizeInBits)
focal_class.return: int
focal_class.signature: int getSizeInWords(long sizeInBits)
focal_class.class_method_signature: BitVectorImpl.addBit(boolean bit)
focal_class.full_signature: @Override public boolean addBit(boolean bit)
focal_class.identifier: addBit
focal_class.modifiers: @Override public
focal_class.parameters: (boolean bit)
focal_class.return: boolean
focal_class.signature: boolean addBit(boolean bit)
focal_class.class_method_signature: BitVectorImpl.assertNonNegativePosition(long position)
focal_class.full_signature:  void assertNonNegativePosition(long position)
focal_class.identifier: assertNonNegativePosition
focal_class.parameters: (long position)
focal_class.return: void
focal_class.signature: void assertNonNegativePosition(long position)
focal_class.class_method_signature: BitVectorImpl.ensureSize(long position)
focal_class.full_signature:  void ensureSize(long position)
focal_class.identifier: ensureSize
focal_class.parameters: (long position)
focal_class.return: void
focal_class.signature: void ensureSize(long position)
focal_class.class_method_signature: BitVectorImpl.computeHashCode()
focal_class.full_signature:  int computeHashCode()
focal_class.identifier: computeHashCode
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int computeHashCode()
focal_class.class_method_signature: BitVectorImpl.equals(Object obj)
focal_class.full_signature: @Override public boolean equals(Object obj)
focal_class.identifier: equals
focal_class.modifiers: @Override public
focal_class.parameters: (Object obj)
focal_class.return: boolean
focal_class.signature: boolean equals(Object obj)
focal_class.class_method_signature: BitVectorImpl.getBit(long position)
focal_class.full_signature: @Override public boolean getBit(long position)
focal_class.identifier: getBit
focal_class.modifiers: @Override public
focal_class.parameters: (long position)
focal_class.return: boolean
focal_class.signature: boolean getBit(long position)
focal_class.class_method_signature: BitVectorImpl.hashCode()
focal_class.full_signature: @Override public int hashCode()
focal_class.identifier: hashCode
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int hashCode()
focal_class.class_method_signature: BitVectorImpl.iterator()
focal_class.full_signature: @Override public Iterator<Boolean> iterator()
focal_class.identifier: iterator
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Iterator<Boolean>
focal_class.signature: Iterator<Boolean> iterator()
focal_class.class_method_signature: BitVectorImpl.resizeArray(int newArraySize)
focal_class.full_signature:  void resizeArray(int newArraySize)
focal_class.identifier: resizeArray
focal_class.parameters: (int newArraySize)
focal_class.return: void
focal_class.signature: void resizeArray(int newArraySize)
focal_class.class_method_signature: BitVectorImpl.setBit(long position, boolean bit)
focal_class.full_signature: @Override public void setBit(long position, boolean bit)
focal_class.identifier: setBit
focal_class.modifiers: @Override public
focal_class.parameters: (long position, boolean bit)
focal_class.return: void
focal_class.signature: void setBit(long position, boolean bit)
focal_class.class_method_signature: BitVectorImpl.size()
focal_class.full_signature: @Override public long size()
focal_class.identifier: size
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: long
focal_class.signature: long size()
focal_class.class_method_signature: BitVectorImpl.toString()
focal_class.full_signature: @Override public String toString()
focal_class.identifier: toString
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String toString()
focal_method.body: @Override
  	public void setBit(long position, boolean bit) {
  		ensureSize(position);
  		this.validHashCode = false;
  		int arrayPos = (int) (position >> LG_WORD_SIZE);
  		byte wordPos = (byte) (position & WORD_MASK);
  		this.arrayOfBits[arrayPos] = setBitInWord(wordPos, bit,
  				this.arrayOfBits[arrayPos]);
  	}
focal_method.class_method_signature: BitVectorImpl.setBit(long position, boolean bit)
focal_method.full_signature: @Override public void setBit(long position, boolean bit)
focal_method.identifier: setBit
focal_method.invocations: ensureSize setBitInWord
focal_method.modifiers: @Override public
focal_method.parameters: (long position, boolean bit)
focal_method.return: void
focal_method.signature: void setBit(long position, boolean bit)