public class FSUtil
extends java.lang.Object
Constructor and Description |
---|
FSUtil() |
Modifier and Type | Method and Description |
---|---|
static int |
countAnnotationsInSpan(JCas jcas,
int type,
int beginSpan,
int endSpan)
returns the number of annotations of specified type in the
|
static int |
countAnnotationsInSpan(JCas jcas,
int type,
int beginSpan,
int endSpan,
int[] validNeTypes)
Does not use
getAnnotationsInSpan(JCas, int, int, int, int[]) so we don't create a collection
unnecessarily. |
static java.util.List |
getAnnotationsInSpan(JCas jcas,
int type,
int beginSpan,
int endSpan,
int[] validNeTypes) |
static FSIterator |
getAnnotationsInSpanIterator(JCas jcas,
int type,
int beginSpan,
int endSpan)
Deprecated.
|
static FSIterator |
getAnnotationsIteratorInSpan(JCas jcas,
int type,
int beginSpan,
int endSpan)
For correct behavior, requires types to be listed in TypePriorities so that the subiterator works as expected
|
static boolean |
isAnnotationPresentInSpan(JCas jcas,
int type,
int beginSpan,
int endSpan)
returns a true if the annotation type is present in the span
|
private static boolean |
isValidNE(int currNeType,
int[] neTypes) |
@Deprecated public static FSIterator getAnnotationsInSpanIterator(JCas jcas, int type, int beginSpan, int endSpan)
public static FSIterator getAnnotationsIteratorInSpan(JCas jcas, int type, int beginSpan, int endSpan)
public static int countAnnotationsInSpan(JCas jcas, int type, int beginSpan, int endSpan, int[] validNeTypes)
getAnnotationsInSpan(JCas, int, int, int, int[])
so we don't create a collection
unnecessarily.private static boolean isValidNE(int currNeType, int[] neTypes)
public static java.util.List getAnnotationsInSpan(JCas jcas, int type, int beginSpan, int endSpan, int[] validNeTypes)
public static int countAnnotationsInSpan(JCas jcas, int type, int beginSpan, int endSpan)
public static boolean isAnnotationPresentInSpan(JCas jcas, int type, int beginSpan, int endSpan)