singleMetricEntity.setTags(e.getTags()); singleMetricEntity.setValue(e.getValue()[i]);
singleMetricEntity.setTags(e.getTags()); singleMetricEntity.setValue(e.getValue()[i]);
@Override public void entityCreated(TaggedLogAPIEntity entity) throws Exception { GenericMetricEntity e = (GenericMetricEntity)entity; double[] value = e.getValue(); if (value != null) { int count = value.length; @SuppressWarnings("unused") Class<?> cls = ed.getMetricDefinition().getSingleTimestampEntityClass(); for (int i = 0; i < count; i++) { long ts = entity.getTimestamp() + i * ed.getMetricDefinition().getInterval(); // exclude those entity which is not within the time range in search condition. [start, end) if (ts < start || ts >= end) { continue; } single.setTimestamp(ts); single.setTags(entity.getTags()); single.setValue(e.getValue()[i]); for (EntityCreationListener l : listeners) { l.entityCreated(single); } } } }
@Override public void entityCreated(TaggedLogAPIEntity entity) throws Exception{ GenericMetricEntity e = (GenericMetricEntity)entity; double[] value = e.getValue(); if(value != null) { int count =value.length; @SuppressWarnings("unused") Class<?> cls = ed.getMetricDefinition().getSingleTimestampEntityClass(); for (int i = 0; i < count; i++) { long ts = entity.getTimestamp() + i * ed.getMetricDefinition().getInterval(); // exclude those entity which is not within the time range in search condition. [start, end) if (ts < start || ts >= end) { continue; } single.setTimestamp(ts); single.setTags(entity.getTags()); single.setValue(e.getValue()[i]); for (EntityCreationListener l : _listeners) { l.entityCreated(single); } } } }