<xs:annotation>
<xs:documentation>The value should be a long</xs:documentation></xs:annotation></xs:enumeration>
<xs:enumeration value="string" >
+ <xs:annotation>
+ <xs:documentation>The value should be a string</xs:documentation></xs:annotation></xs:enumeration>
+ <xs:enumeration value="double" >
<xs:annotation>
<xs:documentation>The value should be a double</xs:documentation></xs:annotation></xs:enumeration>
</xs:restriction>
}
fSeriesData.put(quark, new SeriesData(xvalues.length, display.getAttributeQuark(quark), seriesName, entry.getType()));
}
- double yvalue = 0.0;
for (int i = 0; i < xvalues.length; i++) {
if (monitor != null && monitor.isCanceled()) {
return;
time = time > traceEnd ? traceEnd : time;
for (int quark : quarks) {
+ double yvalue = 0.0;
SeriesData data = checkNotNull(fSeriesData.get(quark));
try {
- yvalue = ss.querySingleState(time, data.getDisplayQuark()).getStateValue().unboxLong();
+ ITmfStateValue value = ss.querySingleState(time, data.getDisplayQuark()).getStateValue();
+ switch (value.getType()) {
+ case DOUBLE:
+ yvalue = value.unboxDouble();
+ break;
+ case LONG:
+ yvalue = value.unboxLong();
+ break;
+ case INTEGER:
+ yvalue = value.unboxInt();
+ break;
+ case NULL:
+ case STRING:
+ default:
+ break;
+ }
data.setYValue(i, yvalue);
} catch (TimeRangeException e) {
data.setYValue(i, 0);