Interface PerceptionCollectable.PerceptionAccumulator<U,I>
- Type Parameters:
U
- underlying object typeI
- intermediate result type
- Enclosing interface:
- PerceptionCollectable<H extends Headway,
U>
public static interface PerceptionCollectable.PerceptionAccumulator<U,I>
Accumulates an object one at a time in to an accumulating intermediate result.
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.
- Author:
- Alexander Verbraeck, Peter Knoppers, Wouter Schakel
-
Method Summary
Modifier and TypeMethodDescriptionaccumulate
(PerceptionCollectable.Intermediate<I> intermediate, U object, org.djunits.value.vdouble.scalar.Length distance) Accumulate the next object to intermediate result.
-
Method Details
-
accumulate
PerceptionCollectable.Intermediate<I> accumulate(PerceptionCollectable.Intermediate<I> intermediate, U object, org.djunits.value.vdouble.scalar.Length distance) Accumulate the next object to intermediate result.- Parameters:
intermediate
- Intermediate<I>; intermediate result before accumulation of objectobject
- U; next object to includedistance
- Length; distance to the considered object- Returns:
- I; intermediate result after accumulation of object
-