ByteArrayOutputStream baos = new ByteArrayOutputStream();
NullOutputStream nos = new NullOutputStream();
BitOutputStream bo_null = new BitOutputStream(nos);
DirectInvertedDocidOnlyOuptutStream dios = new DirectInvertedDocidOnlyOuptutStream(bo_null);
BitOutputStream bo = new BitOutputStream(baos);
if (initial_bitoffset > 0)
bo.writeBinary(initial_bitoffset, 0);
int docid = 0;
while((line = br.readLine())!= null)
{
String[] parts = line.split("\\s+");
for(String p : parts)
ids.add(Integer.parseInt(p));
int[] _tmp = ids.toNativeArray();
byteOffset = bo.getByteOffset();
bitOffset = bo.getBitOffset();
BitFilePosition bp = new FilePosition(byteOffset, bitOffset);
startOffsets.add(bp);
//System.err.println(_tmp.length + "@{"+byteOffset+","+bitOffset+"}");
List<Posting> postingList = new ArrayList<Posting>();
IterablePosting ip = new ArrayOfIdsIterablePosting(_tmp);
while(ip.next() != IterablePosting.EOL)
{
postingList.add(ip.asWritablePosting());
}
BitIndexPointer diosPointer = dios.writePostings(postingList.iterator());
IDS.add(_tmp);
ids.clear();
int previous = -1;
for(int i : _tmp)