Fix broken logic in getting value for committed offsets, add unit test.
Added more detail to javadoc.