@Test public void testOneScope() { JsonExporter exporter = new JsonExporter(); MetricRegistries.get(MetricRegistry.Type.VENDOR).counter("c1"); String result = exporter.exportOneScope(MetricRegistry.Type.VENDOR).toString(); JsonObject json = Json.createReader(new StringReader(result)).read().asJsonObject(); assertEquals(0, json.getInt("c1")); }
@Override public StringBuilder exportOneScope(MetricRegistry.Type scope) { return stringify(exportOneRegistry(MetricRegistries.get(scope))); }
JsonExporter implements Exporter { @Override public StringBuilder exportOneScope(MetricRegistry.Type scope) { return stringify(exportOneRegistry(MetricRegistries.get(scope))); } }
JsonExporter implements Exporter { @Override public StringBuilder exportOneScope(MetricRegistry.Type scope) { return stringify(exportOneRegistry(MetricRegistries.get(scope))); } JsonExporter(); }
JsonExporter implements Exporter { @Override public StringBuilder exportOneScope(MetricRegistry.Type scope) { return stringify(exportOneRegistry(MetricRegistries.get(scope))); } JsonExporter(); @Override StringBuilder exportOneScope(MetricRegistry.Type scope); @Override StringBuilder exportAllScopes(); @Override StringBuilder exportOneMetric(MetricRegistry.Type scope, MetricID metricID); @Override StringBuilder exportMetricsByName(MetricRegistry.Type scope, String name); @Override String getContentType(); }
JsonExporter implements Exporter { @Override public StringBuilder exportOneScope(MetricRegistry.Type scope) { return stringify(exportOneRegistry(MetricRegistries.get(scope))); } JsonExporter(); @Override StringBuilder exportOneScope(MetricRegistry.Type scope); @Override StringBuilder exportAllScopes(); @Override StringBuilder exportOneMetric(MetricRegistry.Type scope, MetricID metricID); @Override StringBuilder exportMetricsByName(MetricRegistry.Type scope, String name); @Override String getContentType();  }