You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ctakes.apache.org by tm...@apache.org on 2014/11/06 18:06:42 UTC
svn commit: r1637157 -
/ctakes/trunk/ctakes-constituency-parser/src/main/java/org/apache/ctakes/constituency/parser/util/AnnotationTreeUtils.java
Author: tmill
Date: Thu Nov 6 17:06:42 2014
New Revision: 1637157
URL: http://svn.apache.org/r1637157
Log:
Removed overly verbose warning message.
Modified:
ctakes/trunk/ctakes-constituency-parser/src/main/java/org/apache/ctakes/constituency/parser/util/AnnotationTreeUtils.java
Modified: ctakes/trunk/ctakes-constituency-parser/src/main/java/org/apache/ctakes/constituency/parser/util/AnnotationTreeUtils.java
URL: http://svn.apache.org/viewvc/ctakes/trunk/ctakes-constituency-parser/src/main/java/org/apache/ctakes/constituency/parser/util/AnnotationTreeUtils.java?rev=1637157&r1=1637156&r2=1637157&view=diff
==============================================================================
--- ctakes/trunk/ctakes-constituency-parser/src/main/java/org/apache/ctakes/constituency/parser/util/AnnotationTreeUtils.java (original)
+++ ctakes/trunk/ctakes-constituency-parser/src/main/java/org/apache/ctakes/constituency/parser/util/AnnotationTreeUtils.java Thu Nov 6 17:06:42 2014
@@ -35,19 +35,13 @@ public class AnnotationTreeUtils {
public static TopTreebankNode getAnnotationTree(JCas jcas, Annotation annot){
TopTreebankNode tree = null;
-// FSIterator<Annotation> iter = jcas.getJFSIndexRepository().getAnnotationIndex(TopTreebankNode.type).iterator();
Collection<TopTreebankNode> roots = JCasUtil.select(jcas, TopTreebankNode.class);
-// while(iter.hasNext()){
for(TopTreebankNode root : roots){
-// TopTreebankNode root = (TopTreebankNode) iter.next();
if(root.getBegin() <= annot.getBegin() && root.getEnd() >= annot.getEnd()){
tree = root;
break;
}
}
- if(tree == null){
- System.err.println("Could not find a tree.");
- }
return tree;
}