Package srsim.domain

Examples of srsim.domain.IController.attachActuator()


  public void testAttachingSensors() throws SimulationConfigurationException {
    IController controller = new HeatingController();
    ISensor sensor = new TemperatureSensor();
    IActuator actuator = new HeatingActuator();
    controller.attachSensor(sensor);
    controller.attachActuator(actuator);
  }
 
  @Test
  public void testInitiatingActuatorChangeFromSensorUpdate() throws SimulationContextException {
    Simulation simulation = new Simulation(new SystemTimeTimeSource());
View Full Code Here


        JsonArray actuatorArray = controllerDescription
            .getJsonArray("actuators");
        if (actuatorArray != null) {
          for (JsonNumber actuatorId : actuatorArray
              .getValuesAs(JsonNumber.class)) {
            controller.attachActuator(actuatorMap.get(actuatorId
                .intValue()));
          }
        }
        room.addController(controller);
      }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.