Package sensor
Class FixedSensor
- java.lang.Object
-
- sensor.AbstractSensor
-
- sensor.FixedSensor
-
- All Implemented Interfaces:
InterfaceScenarioElement
,Pokable
public class FixedSensor extends AbstractSensor
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
FixedSensor.Measurement
class
FixedSensor.SubSensor
-
Nested classes/interfaces inherited from class sensor.AbstractSensor
AbstractSensor.Type
-
-
Field Summary
Fields Modifier and Type Field Description int
end_lane
int
start_lane
-
Constructor Summary
Constructors Constructor Description FixedSensor(float dt, Link link, int start_lane, int end_lane, float position, Set<Long> commids)
FixedSensor(Scenario scenario, Sensor jaxb_sensor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description double
get_flow_vph()
double
get_flow_vph(long comm_id)
Link
get_link()
float
get_position()
double
get_vehicles()
double
get_vehicles(long comm_id)
void
initialize(Scenario scenario)
void
take_measurement(Dispatcher dispatcher, float timestamp)
-
Methods inherited from class sensor.AbstractSensor
getId, getSEType, poke, to_jaxb, validate_post_init
-
-
-
-
Constructor Detail
-
FixedSensor
public FixedSensor(float dt, Link link, int start_lane, int end_lane, float position, Set<Long> commids) throws OTMException
- Throws:
OTMException
-
FixedSensor
public FixedSensor(Scenario scenario, Sensor jaxb_sensor) throws OTMException
- Throws:
OTMException
-
-
Method Detail
-
initialize
public void initialize(Scenario scenario) throws OTMException
- Overrides:
initialize
in classAbstractSensor
- Throws:
OTMException
-
take_measurement
public void take_measurement(Dispatcher dispatcher, float timestamp)
- Specified by:
take_measurement
in classAbstractSensor
-
get_position
public float get_position()
-
get_flow_vph
public double get_flow_vph()
-
get_flow_vph
public double get_flow_vph(long comm_id)
-
get_vehicles
public double get_vehicles()
-
get_vehicles
public double get_vehicles(long comm_id)
-
get_link
public Link get_link()
-
-