本文整理了Java中org.apache.uima.fit.util.FSUtil.isMultiValuedFeature()
方法的一些代码示例,展示了FSUtil.isMultiValuedFeature()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。FSUtil.isMultiValuedFeature()
方法的具体详情如下:
包路径:org.apache.uima.fit.util.FSUtil
类名称:FSUtil
方法名:isMultiValuedFeature
暂无
代码示例来源:origin: org.apache.uima/uimafit-core
public static boolean isMultiValuedFeature(FeatureStructure aFS, String aFeature) {
Feature feat = aFS.getType().getFeatureByBaseName(aFeature);
return isMultiValuedFeature(aFS, feat);
}
代码示例来源:origin: org.apache.uima/uimafit-core
public static boolean isMultiValuedFeature(FeatureStructure aFS, Feature feat) {
return isMultiValuedFeature(aFS.getCAS().getTypeSystem(), feat);
}
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/webanno-io-xmi
private boolean isSlotFeature(TypeSystem aTS, Feature aFeature)
if (!FSUtil.isMultiValuedFeature(aTS, aFeature)) {
return false;
代码示例来源:origin: webanno/webanno
private boolean isSlotFeature(TypeSystem aTS, Feature aFeature)
if (!FSUtil.isMultiValuedFeature(aTS, aFeature)) {
return false;
代码示例来源:origin: webanno/webanno
private Object getValue(FeatureStructure fs, AnnotationFeature aFeature)
{
Object value;
Feature f = fs.getType().getFeatureByBaseName(aFeature.getName());
if (f.getRange().isPrimitive()) {
value = FSUtil.getFeature(fs, aFeature.getName(), Object.class);
}
else if (FSUtil.isMultiValuedFeature(fs, f)) {
value = FSUtil.getFeature(fs, aFeature.getName(), List.class);
}
else {
value = FSUtil.getFeature(fs, aFeature.getName(), FeatureStructure.class);
}
return value;
}
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/webanno-api-annotation
private Object getValue(FeatureStructure fs, AnnotationFeature aFeature)
{
Object value;
Feature f = fs.getType().getFeatureByBaseName(aFeature.getName());
if (f.getRange().isPrimitive()) {
value = FSUtil.getFeature(fs, aFeature.getName(), Object.class);
}
else if (FSUtil.isMultiValuedFeature(fs, f)) {
value = FSUtil.getFeature(fs, aFeature.getName(), List.class);
}
else {
value = FSUtil.getFeature(fs, aFeature.getName(), FeatureStructure.class);
}
return value;
}
代码示例来源:origin: webanno/webanno
default <V> V getFeatureValue(AnnotationFeature aFeature, FeatureStructure aFS)
{
Object value;
Feature f = aFS.getType().getFeatureByBaseName(aFeature.getName());
if (f.getRange().isPrimitive()) {
value = FSUtil.getFeature(aFS, aFeature.getName(), Object.class);
}
else if (FSUtil.isMultiValuedFeature(aFS, f)) {
value = FSUtil.getFeature(aFS, aFeature.getName(), List.class);
}
else {
value = FSUtil.getFeature(aFS, aFeature.getName(), FeatureStructure.class);
}
return (V) wrapFeatureValue(aFeature, aFS.getCAS(), value);
}
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/webanno-api-annotation
default <V> V getFeatureValue(AnnotationFeature aFeature, FeatureStructure aFS)
{
Object value;
Feature f = aFS.getType().getFeatureByBaseName(aFeature.getName());
if (f.getRange().isPrimitive()) {
value = FSUtil.getFeature(aFS, aFeature.getName(), Object.class);
}
else if (FSUtil.isMultiValuedFeature(aFS, f)) {
value = FSUtil.getFeature(aFS, aFeature.getName(), List.class);
}
else {
value = FSUtil.getFeature(aFS, aFeature.getName(), FeatureStructure.class);
}
return (V) wrapFeatureValue(aFeature, aFS.getCAS(), value);
}
内容来源于网络,如有侵权,请联系作者删除!