@Test public void test_descriptor() throws Exception { init(false); DefaultSensorDescriptor sensorDescriptor = new DefaultSensorDescriptor(); sensor.describe(sensorDescriptor); assertThat(sensorDescriptor.name()).isEqualTo("XML Sensor"); assertThat(sensorDescriptor.languages()).containsOnly(Xml.KEY); }
@Override public void describe(SensorDescriptor descriptor) { descriptor .onlyOnLanguage(Xml.KEY) .name("XML Sensor"); }
XmlSensor implements Sensor { @Override public void describe(SensorDescriptor descriptor) { descriptor .onlyOnLanguage(Xml.KEY) .name("XML Sensor"); } }
XmlSensor implements Sensor { @Override public void describe(SensorDescriptor descriptor) { descriptor .onlyOnLanguage(Xml.KEY) .name("XML Sensor"); } XmlSensor(FileSystem fileSystem, CheckFactory checkFactory, FileLinesContextFactory fileLinesContextFactory); }
XmlSensor implements Sensor { @Override public void describe(SensorDescriptor descriptor) { descriptor .onlyOnLanguage(Xml.KEY) .name("XML Sensor"); } XmlSensor(FileSystem fileSystem, CheckFactory checkFactory, FileLinesContextFactory fileLinesContextFactory); @Override void execute(SensorContext context); @Override String toString(); @Override void describe(SensorDescriptor descriptor); }
XmlSensor implements Sensor { @Override public void describe(SensorDescriptor descriptor) { descriptor .onlyOnLanguage(Xml.KEY) .name("XML Sensor"); } XmlSensor(FileSystem fileSystem, CheckFactory checkFactory, FileLinesContextFactory fileLinesContextFactory); @Override void execute(SensorContext context); @Override String toString(); @Override void describe(SensorDescriptor descriptor);  }