// out = new FileOutputStream(outputFile);
// XCASSerializer.serialize(view.getCas(), out, true); // true -> formats the output
outputFile.createNewFile();
BufferedWriter bw = new BufferedWriter(new FileWriter(outputFile));
AnnotationIndex nodeIndex = jCas.getAnnotationIndex(ConllDependencyNode.type);
FSIterator sentences = jCas.getAnnotationIndex(Sentence.type).iterator();
while (sentences.hasNext()) {
Sentence sentence = (Sentence) sentences.next();
ConllDependencyNode node = null;
FSIterator nodeIterator = nodeIndex.subiterator(sentence);
while (nodeIterator.hasNext()) {
// int pID = (node==null)? 0 : node.getID();
node = (ConllDependencyNode) nodeIterator.next();
if (node.getId()!=0 ) { // && node.getID() !=pID) {