package org.opentrafficsim.draw.graphs;
import java.util.ArrayList;
import java.util.List;
import org.djunits.value.vdouble.scalar.Duration;
import org.djunits.value.vdouble.scalar.Length;
import org.djunits.value.vdouble.scalar.Time;
import org.opentrafficsim.core.dsol.OTSSimulatorInterface;
import org.opentrafficsim.draw.graphs.GraphPath.Section;
import org.opentrafficsim.kpi.sampling.KpiLaneDirection;
import org.opentrafficsim.kpi.sampling.Sampler;
import org.opentrafficsim.kpi.sampling.SpaceTimeRegion;
import org.opentrafficsim.kpi.sampling.TrajectoryGroup;
/**
* Super class for plots that use sampler data. Sub classes may obtain trajectories using {@code getTrajectories()}, or
* alternatively maintain some other -possibly more efficient- connection to the sampler. This class also connects the plot to a
* path, consisting of a list of lanes. Start distance along the path for each lane is provided to sub classes using
* {@code getStartDistance(KpiLaneDirection)}. Total length is obtained using {@code getEndLocation()}.
*
* Copyright (c) 2013-2019 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
* BSD-style license. See OpenTrafficSim License.
*
* @version $Revision$, $LastChangedDate$, by $Author$, initial version 4 okt. 2018
* @author Alexander Verbraeck
* @author Peter Knoppers
* @author Wouter Schakel
*/
public abstract class AbstractSamplerPlot extends AbstractSpaceTimePlot
{
/** */
private static final long serialVersionUID = 20181004L;
/** Sampler. */
private final Sampler> sampler;
/** KPI lane directions registered in the sampler. */
private final GraphPath path;
/** Time when trajectories were last updated per series in the path. */
private List