code: public void append( int bits , int numberOfBits , boolean swapOrder ) {
  		if( numberOfBits > 32 )
  			throw new IllegalArgumentException("Number of bits exceeds the size of bits");
  		int indexTail = size;
  		growArray(numberOfBits,true);
  
  		if( swapOrder ) {
  			for (int i = 0; i < numberOfBits; i++) {
  				set( indexTail + i , ( bits >> i ) & 1 );
  			}
  		} else {
  			for (int i = 0; i < numberOfBits; i++) {
  				set( indexTail + numberOfBits-i-1 , ( bits >> i ) & 1 );
  			}
  		}
  	}
docs: Appends bits on to the end of the stack.
  @param bits Storage for bits. Relevant bits start at the front.
  @param numberOfBits Number of relevant bits in 'bits'
  @param swapOrder If true then the first bit in 'bits' will be the last bit in this array.