@Test public void testSensorBuilderOnSwitchSensor() throws Exception { Element sensor1001 = deployer.queryElementById(1001); Sensor s = sensorBuilder.build(sensor1001); s.start(); Assert.assertTrue(s.getSensorID() == 1001); Assert.assertTrue(s instanceof SwitchSensor); Assert.assertTrue(s.isRunning()); Assert.assertTrue(s.getProperties().size() == 0); }
public abstract Component build(Element componentElement, String commandParam) throws InitializationException;
ComponentBuilder { public abstract Component build(Element componentElement, String commandParam) throws InitializationException; }
ComponentBuilder { public abstract Component build(Element componentElement, String commandParam) throws InitializationException;  }
ComponentBuilder { public abstract Component build(Element componentElement, String commandParam) throws InitializationException;  abstract Component build(Element componentElement, String commandParam); void setCommandFactory(CommandFactory commandFactory); }
ComponentBuilder { public abstract Component build(Element componentElement, String commandParam) throws InitializationException;  abstract Component build(Element componentElement, String commandParam); void setCommandFactory(CommandFactory commandFactory);  }