public class RoadSampler
extends org.opentrafficsim.kpi.sampling.Sampler
implements nl.tudelft.simulation.event.EventListenerInterface
 Copyright (c) 2013-2016 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved. 
 BSD-style license. See OpenTrafficSim License.
 
| Constructor and Description | 
|---|
RoadSampler(org.opentrafficsim.core.dsol.OTSDEVSSimulatorInterface simulator)
Constructor which uses the operational plan updates of GTU's as sampling interval. 
 | 
RoadSampler(org.opentrafficsim.core.dsol.OTSDEVSSimulatorInterface simulator,
           org.djunits.value.vdouble.scalar.Frequency frequency)
Constructor which uses the given frequency to determine the sampling interval. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
boolean | 
equals(Object obj) | 
void | 
finalizeRecording(org.opentrafficsim.kpi.sampling.KpiLaneDirection kpiLaneDirection) | 
int | 
hashCode() | 
void | 
initRecording(org.opentrafficsim.kpi.sampling.KpiLaneDirection kpiLaneDirection) | 
void | 
notify(nl.tudelft.simulation.event.EventInterface event) | 
void | 
notifySample(LaneBasedGTU gtu,
            LaneDirection laneDirection)
Samples a gtu and schedules the next sampling event. 
 | 
org.djunits.value.vdouble.scalar.Time | 
now() | 
void | 
scheduleStartRecording(org.djunits.value.vdouble.scalar.Time time,
                      org.opentrafficsim.kpi.sampling.KpiLaneDirection kpiLaneDirection) | 
void | 
scheduleStopRecording(org.djunits.value.vdouble.scalar.Time time,
                     org.opentrafficsim.kpi.sampling.KpiLaneDirection kpiLaneDirection) | 
String | 
toString() | 
public RoadSampler(org.opentrafficsim.core.dsol.OTSDEVSSimulatorInterface simulator)
simulator - simulatorNullPointerException - if the simulator is nullpublic RoadSampler(org.opentrafficsim.core.dsol.OTSDEVSSimulatorInterface simulator,
                   org.djunits.value.vdouble.scalar.Frequency frequency)
simulator - simulatorfrequency - sampling frequencyNullPointerException - if an input is nullIllegalArgumentException - if frequency is negative or zeropublic final org.djunits.value.vdouble.scalar.Time now()
now in class org.opentrafficsim.kpi.sampling.Samplerpublic final void scheduleStartRecording(org.djunits.value.vdouble.scalar.Time time,
                                         org.opentrafficsim.kpi.sampling.KpiLaneDirection kpiLaneDirection)
scheduleStartRecording in class org.opentrafficsim.kpi.sampling.Samplerpublic final void scheduleStopRecording(org.djunits.value.vdouble.scalar.Time time,
                                        org.opentrafficsim.kpi.sampling.KpiLaneDirection kpiLaneDirection)
scheduleStopRecording in class org.opentrafficsim.kpi.sampling.Samplerpublic final void initRecording(org.opentrafficsim.kpi.sampling.KpiLaneDirection kpiLaneDirection)
initRecording in class org.opentrafficsim.kpi.sampling.Samplerpublic final void finalizeRecording(org.opentrafficsim.kpi.sampling.KpiLaneDirection kpiLaneDirection)
finalizeRecording in class org.opentrafficsim.kpi.sampling.Samplerpublic final void notify(nl.tudelft.simulation.event.EventInterface event)
                  throws RemoteException
notify in interface nl.tudelft.simulation.event.EventListenerInterfaceRemoteExceptionpublic final void notifySample(LaneBasedGTU gtu, LaneDirection laneDirection)
gtu - gtu to samplelaneDirection - lane direction where the gtu is atpublic final int hashCode()
hashCode in class org.opentrafficsim.kpi.sampling.Samplerpublic final boolean equals(Object obj)
equals in class org.opentrafficsim.kpi.sampling.SamplerCopyright © 2014–2017 Delft University of Technology. All rights reserved.