bitset
bitset copied to clipboard
Implementing (next/previous)(Set/Clear)Bit()
A reasonably DRY implementation of the following methods:
- http://docs.oracle.com/javase/7/docs/api/java/util/BitSet.html#nextSetBit(int)
- http://docs.oracle.com/javase/7/docs/api/java/util/BitSet.html#nextClearBit(int)
- http://docs.oracle.com/javase/7/docs/api/java/util/BitSet.html#previousSetBit(int)
- http://docs.oracle.com/javase/7/docs/api/java/util/BitSet.html#previousClearBit(int)
Need to write some unit tests, but has been manually tested, and all seems good.
Will update source branch with:
- Fixed conflicts
- Updated README.md with methods listed