示例#1
0
 @Override
 public IMetricValue convert(MetricCollector collector) {
   CubeSearcher searcher = collector.getSearcher();
   FieldDefinition fieldDef = collector.getFieldDefinition();
   MetricValueText.Max txt = new MetricValueText.Max();
   if (metric != Long.MIN_VALUE) {
     IdSearcher ids = searcher.getIdSearcher(fieldDef.getLinkExtent());
     txt.value = ids.getId((int) metric).toString();
   }
   return txt;
 }
示例#2
0
 @Override
 public IMetricValue convert(MetricCollector collector) {
   CubeSearcher searcher = collector.getSearcher();
   FieldDefinition fieldDef = collector.getFieldDefinition();
   MetricValueText.Max txt = new MetricValueText.Max();
   if (metric != Long.MIN_VALUE) {
     ValueSearcher vs = searcher.getValueSearcher(fieldDef.getTableName(), fieldDef.getName());
     txt.value = vs.getValue((int) metric).toString();
   }
   return txt;
 }