com.lordofthejars.nosqlunit.redis.embedded
Class BitsUtils

java.lang.Object
  extended by com.lordofthejars.nosqlunit.redis.embedded.BitsUtils

public class BitsUtils
extends Object


Constructor Summary
BitsUtils()
           
 
Method Summary
static int calculateNumberOfBytes(int numBits)
           
static int countBits(byte num)
           
static byte[] extendByteArrayBy(byte[] data, int numberOfNewPositions)
           
static int getBit(byte[] data, int pos)
           
static void setBit(byte[] data, int pos, int val)
           
static boolean toBoolean(int bit)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BitsUtils

public BitsUtils()
Method Detail

extendByteArrayBy

public static byte[] extendByteArrayBy(byte[] data,
                                       int numberOfNewPositions)

toBoolean

public static boolean toBoolean(int bit)

countBits

public static int countBits(byte num)

calculateNumberOfBytes

public static int calculateNumberOfBytes(int numBits)

getBit

public static int getBit(byte[] data,
                         int pos)

setBit

public static void setBit(byte[] data,
                          int pos,
                          int val)


Copyright © 2012. All Rights Reserved.