Package control
Class AbstractController
- java.lang.Object
-
- control.AbstractController
-
- All Implemented Interfaces:
core.InterfaceEventWriter,core.InterfaceScenarioElement,dispatch.Pokable
- Direct Known Subclasses:
ControllerSignal
public abstract class AbstractController extends Object implements dispatch.Pokable, core.InterfaceScenarioElement, core.InterfaceEventWriter
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAbstractController.Algorithm
-
Field Summary
Fields Modifier and Type Field Description Map<String,AbstractActuator>actuator_by_usageMap<Long,AbstractActuator>actuatorsMap<Long,control.command.InterfaceCommand>commandFloatdtfloatend_timeoutput.OutputControllerevent_outputlongidScenarioscenarioMap<String,AbstractSensor>sensor_by_usageSet<AbstractSensor>sensorsfloatstart_timeAbstractController.Algorithmtype
-
Constructor Summary
Constructors Constructor Description AbstractController(Scenario scenario, jaxb.Controller jaxb_controller)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract Classget_actuator_class()control.command.InterfaceCommandget_command_for_actuator_id(Long act_id)control.command.InterfaceCommandget_command_for_actuator_usage(String act_usage)LonggetId()core.ScenarioElementTypegetSEType()voidinitialize(Scenario scenario, boolean override_targets)booleanis_inbuilt(String name)voidpoke(dispatch.Dispatcher dispatcher, float timestamp)voidset_event_output(output.AbstractOutputEvent e)error.OTMErrorLogto_jaxb()abstract voidupdate_command(dispatch.Dispatcher dispatcher)error.OTMErrorLogvalidate_post_init()voidvalidate_pre_init(error.OTMErrorLog errorLog)
-
-
-
Field Detail
-
scenario
public final Scenario scenario
-
id
public final long id
-
type
public final AbstractController.Algorithm type
-
dt
public Float dt
-
start_time
public float start_time
-
end_time
public float end_time
-
actuators
public Map<Long,AbstractActuator> actuators
-
actuator_by_usage
public Map<String,AbstractActuator> actuator_by_usage
-
sensors
public Set<AbstractSensor> sensors
-
sensor_by_usage
public Map<String,AbstractSensor> sensor_by_usage
-
event_output
public output.OutputController event_output
-
-
Constructor Detail
-
AbstractController
public AbstractController(Scenario scenario, jaxb.Controller jaxb_controller) throws error.OTMException
- Throws:
error.OTMException
-
-
Method Detail
-
update_command
public abstract void update_command(dispatch.Dispatcher dispatcher) throws error.OTMException- Throws:
error.OTMException
-
get_actuator_class
public abstract Class get_actuator_class()
-
initialize
public final void initialize(Scenario scenario, boolean override_targets) throws error.OTMException
- Throws:
error.OTMException
-
getId
public final Long getId()
- Specified by:
getIdin interfacecore.InterfaceScenarioElement
-
getSEType
public final core.ScenarioElementType getSEType()
- Specified by:
getSETypein interfacecore.InterfaceScenarioElement
-
validate_pre_init
public void validate_pre_init(error.OTMErrorLog errorLog)
-
validate_post_init
public error.OTMErrorLog validate_post_init()
-
to_jaxb
public error.OTMErrorLog to_jaxb()
- Specified by:
to_jaxbin interfacecore.InterfaceScenarioElement
-
poke
public final void poke(dispatch.Dispatcher dispatcher, float timestamp) throws error.OTMException- Specified by:
pokein interfacedispatch.Pokable- Throws:
error.OTMException
-
set_event_output
public void set_event_output(output.AbstractOutputEvent e) throws error.OTMException- Specified by:
set_event_outputin interfacecore.InterfaceEventWriter- Throws:
error.OTMException
-
is_inbuilt
public boolean is_inbuilt(String name)
-
get_command_for_actuator_id
public final control.command.InterfaceCommand get_command_for_actuator_id(Long act_id)
-
get_command_for_actuator_usage
public final control.command.InterfaceCommand get_command_for_actuator_usage(String act_usage)
-
-