1 package org.opentrafficsim.road.gtu.lane.perception.categories; 2 3 import org.opentrafficsim.road.gtu.lane.perception.PerceptionCollectable; 4 import org.opentrafficsim.road.gtu.lane.perception.RelativeLane; 5 import org.opentrafficsim.road.gtu.lane.perception.headway.HeadwayConflict; 6 import org.opentrafficsim.road.gtu.lane.perception.headway.HeadwayTrafficLight; 7 import org.opentrafficsim.road.network.lane.conflict.Conflict; 8 9 /** 10 * Perception category for traffic lights and conflicts. 11 * <p> 12 * Copyright (c) 2013-2019 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved. <br> 13 * BSD-style license. See <a href="http://opentrafficsim.org/node/13">OpenTrafficSim License</a>. 14 * <p> 15 * @version $Revision$, $LastChangedDate$, by $Author$, initial version 14 feb. 2017 <br> 16 * @author <a href="http://www.tbm.tudelft.nl/averbraeck">Alexander Verbraeck</a> 17 * @author <a href="http://www.tudelft.nl/pknoppers">Peter Knoppers</a> 18 * @author <a href="http://www.transport.citg.tudelft.nl">Wouter Schakel</a> 19 */ 20 public interface IntersectionPerception extends LaneBasedPerceptionCategory 21 { 22 23 /** 24 * Returns a set of traffic lights along the route. Traffic lights are sorted by headway value. 25 * @param lane RelativeLane; lane 26 * @return set of traffic lights along the route 27 */ 28 Iterable<HeadwayTrafficLight> getTrafficLights(RelativeLane lane); 29 30 /** 31 * Returns a set of conflicts along the route. Conflicts are sorted by headway value. 32 * @param lane RelativeLane; lane 33 * @return set of conflicts along the route 34 */ 35 PerceptionCollectable<HeadwayConflict, Conflict> getConflicts(RelativeLane lane); 36 37 /** 38 * Returns whether there is a conflict alongside to the left. 39 * @return whether there is a conflict alongside to the left 40 */ 41 boolean isAlongsideConflictLeft(); 42 43 /** 44 * Returns whether there is a conflict alongside to the right. 45 * @return whether there is a conflict alongside to the right 46 */ 47 boolean isAlongsideConflictRight(); 48 49 }