primaryIterator
Returns the primary iterator. This method is called once by AbstractPerceptionReiterable.
- Specified by:
primaryIteratorin classAbstractPerceptionReiterable<H extends Headway,U> - Returns:
- Iterator; primary iterator
H - headway typeU - underlying object typeC - counter typeIterable<H>, PerceptionCollectable<H,U> , PerceptionIterable<H>DownstreamNeighborsIterable, LaneBasedObjectIterable, UpstreamNeighborsIterable
Copyright (c) 2013-2024 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
protected class AbstractPerceptionReiterable.PerceptionIterator, AbstractPerceptionReiterable.PrimaryIteratorEntryPerceptionCollectable.Intermediate<I>, PerceptionCollectable.PerceptionAccumulator<U,I>, PerceptionCollectable.PerceptionCollector<C,U,I>, PerceptionCollectable.PerceptionFinalizer<C,I>, PerceptionCollectable.UnderlyingDistance<U> AbstractPerceptionIterable(LaneBasedGtu perceivingGtu,
LaneRecordInterface<?> root,
org.djunits.value.vdouble.scalar.Length initialPosition,
boolean downstream,
org.djunits.value.vdouble.scalar.Length maxDistance,
RelativePosition relativePosition,
Route route) protected abstract org.djunits.value.vdouble.scalar.LengthgetDistance(U object,
LaneRecordInterface<?> record,
org.djunits.value.vdouble.scalar.Length position) protected org.djunits.value.vdouble.scalar.LengthgetDx()protected abstract AbstractPerceptionIterable<H,U,C>.Entry getNext(LaneRecordInterface<?> record,
org.djunits.value.vdouble.scalar.Length position,
C counter) boolean(package private) final booleanisOnRoute(LaneRecordInterface<?> record) addNext, assureNext, collect, first, getGtu, getPrimaryIterator, isEmpty, iterator, perceive, underlying, underlyingWithDistanceclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorcollectperceivingGtu - LaneBasedGtu; perceiving GTUroot - LaneRecord<?>; root recordinitialPosition - Length; initial positiondownstream - boolean; search downstream (or upstream)maxDistance - Length; max distance to searchrelativePosition - RelativePosition; position to which distance are calculated by subclassesroute - Route; route of the GTU, may be nullprimaryIterator in class AbstractPerceptionReiterable<H extends Headway,U> null for
the first object(s). For following object(s) it is whatever value is given with the previous output Entry. Hence,
this method maintains its own counting system.record - LaneRecord<?>; record representing the lane and directionposition - Length; position to look beyondcounter - C; counternull if noneGtuException - on any exception in the processEntry returned
by getNext. The two methods need to be consistent with each other.object - U; underlying objectrecord - LaneRecord<?>; record representing the lane and directionposition - Length; position of the object on the lanerecord - LaneRecord<?>; record