// Convert the orderless FSIterator to List, sort by char offsets
LinkedList<Annotation> lm = FSIteratorToList.convert(
jcas.getJFSIndexRepository().getAnnotationIndex(Markable.type).iterator());
// Create a parent pointer tree to calculate equivalence classes
ppt = new ParentPtrTree(lm.size());
// Make a data structure mapping markables to indexes so we don't lose the order if we re-arrange
Map<Markable, Integer> m2q = new HashMap<Markable,Integer>();
for(int p = 0; p < lm.size(); p++){
m2q.put((Markable)lm.get(p), p);