tableModel.addRow(new Object[] { featName, new Integer(intVal) });
} else if (CAS.TYPE_NAME_FLOAT.equals(rangeTypeName)) {
float floatVal = aAnnotation.getFloatValue(feat);
tableModel.addRow(new Object[] { featName, new Float(floatVal) });
} else if (CAS.TYPE_NAME_STRING_ARRAY.equals(rangeTypeName)) {
StringArrayFS arrayFS = (StringArrayFS) aAnnotation.getFeatureValue(feat);
StringBuffer displayVal = new StringBuffer();
if (arrayFS == null) {
displayVal.append("null");
} else {
displayVal.append('[');
String[] vals = arrayFS.toArray();
for (int i = 0; i < vals.length - 1; i++) {
displayVal.append(vals[i]);
displayVal.append(',');
}
if (vals.length > 0) {
displayVal.append(vals[vals.length - 1]);
}
displayVal.append(']');
}
tableModel.addRow(new Object[] { featName, displayVal });
} else if (CAS.TYPE_NAME_INTEGER_ARRAY.equals(rangeTypeName)) {
IntArrayFS arrayFS = (IntArrayFS) aAnnotation.getFeatureValue(feat);
StringBuffer displayVal = new StringBuffer();
if (arrayFS == null) {
displayVal.append("null");
} else {
displayVal.append('[');
int[] vals = arrayFS.toArray();
for (int i = 0; i < vals.length - 1; i++) {
displayVal.append(vals[i]);
displayVal.append(',');
}
if (vals.length > 0) {
displayVal.append(vals[vals.length - 1]);
}
displayVal.append(']');
}
tableModel.addRow(new Object[] { featName, displayVal });
} else if (CAS.TYPE_NAME_FLOAT_ARRAY.equals(rangeTypeName)) {
FloatArrayFS arrayFS = (FloatArrayFS) aAnnotation.getFeatureValue(feat);
StringBuffer displayVal = new StringBuffer();
if (arrayFS == null) {
displayVal.append("null");
} else {
displayVal.append('[');
float[] vals = arrayFS.toArray();
for (int i = 0; i < vals.length - 1; i++) {
displayVal.append(vals[i]);
displayVal.append(',');
}
if (vals.length > 0) {