@Test public void testRecordLevelEnum() { Sensor.RecordingLevel configLevel = Sensor.RecordingLevel.INFO; assertTrue(Sensor.RecordingLevel.INFO.shouldRecord(configLevel.id)); assertFalse(Sensor.RecordingLevel.DEBUG.shouldRecord(configLevel.id)); configLevel = Sensor.RecordingLevel.DEBUG; assertTrue(Sensor.RecordingLevel.INFO.shouldRecord(configLevel.id)); assertTrue(Sensor.RecordingLevel.DEBUG.shouldRecord(configLevel.id)); assertEquals(Sensor.RecordingLevel.valueOf(Sensor.RecordingLevel.DEBUG.toString()), Sensor.RecordingLevel.DEBUG); assertEquals(Sensor.RecordingLevel.valueOf(Sensor.RecordingLevel.INFO.toString()), Sensor.RecordingLevel.INFO); }
public boolean shouldRecord() { return this.recordingLevel.shouldRecord(config.recordLevel().id); }
Sensor { public boolean shouldRecord() { return this.recordingLevel.shouldRecord(config.recordLevel().id); } }
Sensor { public boolean shouldRecord() { return this.recordingLevel.shouldRecord(config.recordLevel().id); } Sensor(Metrics registry, String name, Sensor[] parents, MetricConfig config, Time time,
           long inactiveSensorExpirationTimeSeconds, RecordingLevel recordingLevel); }
Sensor { public boolean shouldRecord() { return this.recordingLevel.shouldRecord(config.recordLevel().id); } Sensor(Metrics registry, String name, Sensor[] parents, MetricConfig config, Time time,
           long inactiveSensorExpirationTimeSeconds, RecordingLevel recordingLevel); String name(); void record(); boolean shouldRecord(); void record(double value); void record(double value, long timeMs); void record(double value, long timeMs, boolean checkQuotas); void checkQuotas(); void checkQuotas(long timeMs); void add(CompoundStat stat); synchronized void add(CompoundStat stat, MetricConfig config); void add(MetricName metricName, MeasurableStat stat); synchronized void add(MetricName metricName, MeasurableStat stat, MetricConfig config); boolean hasExpired(); }
Sensor { public boolean shouldRecord() { return this.recordingLevel.shouldRecord(config.recordLevel().id); } Sensor(Metrics registry, String name, Sensor[] parents, MetricConfig config, Time time,
           long inactiveSensorExpirationTimeSeconds, RecordingLevel recordingLevel); String name(); void record(); boolean shouldRecord(); void record(double value); void record(double value, long timeMs); void record(double value, long timeMs, boolean checkQuotas); void checkQuotas(); void checkQuotas(long timeMs); void add(CompoundStat stat); synchronized void add(CompoundStat stat, MetricConfig config); void add(MetricName metricName, MeasurableStat stat); synchronized void add(MetricName metricName, MeasurableStat stat, MetricConfig config); boolean hasExpired();  }