@Override public java.util.List<Feature> extract(JCas view, FOCUS_T annotation1, FOCUS_T annotation2) throws CleartkExtractorException { return this.extractBetween(view, annotation1, annotation2); }
@Override public List<Feature> extract(JCas jCas, IdentifiedAnnotation mention1, IdentifiedAnnotation mention2) throws AnalysisEngineProcessException { List<Feature> features = new ArrayList<Feature>(); Annotation arg1 = mention1; Annotation arg2 = mention2; if(arg1 instanceof EventMention){ arg1 = getExpandedEvent(jCas, mention1); if(arg1 == null) arg1 = mention1; } if(arg2 instanceof EventMention){ arg2 = getExpandedEvent(jCas, mention2); if(arg2 == null) arg2 = mention2; } features.addAll(this.mention1FeaturesExtractor.extract(jCas, arg1)); features.addAll(this.mention2FeaturesExtractor.extract(jCas, arg2)); features.addAll(this.tokensBetween.extractBetween(jCas, arg1, arg2)); features.addAll(this.nTokensBetween.extract(jCas, arg1, arg2)); return features; }
@Override public List<Feature> extract(JCas jCas, IdentifiedAnnotation mention1, IdentifiedAnnotation mention2) throws AnalysisEngineProcessException { List<Feature> features = new ArrayList<Feature>(); Annotation arg1 = mention1; Annotation arg2 = mention2; if(arg1 instanceof EventMention){ arg1 = getExpandedEvent(jCas, mention1); if(arg1 == null) arg1 = mention1; } if(arg2 instanceof EventMention){ arg2 = getExpandedEvent(jCas, mention2); if(arg2 == null) arg2 = mention2; } features.addAll(this.mention1FeaturesExtractor.extract(jCas, arg1)); features.addAll(this.mention2FeaturesExtractor.extract(jCas, arg2)); features.addAll(this.tokensBetween.extractBetween(jCas, arg1, arg2)); features.addAll(this.nTokensBetween.extract(jCas, arg1, arg2)); return features; }