public class CarGeneratorFunction extends Object implements GeneratorFunction<Long,Tuple4<Integer,Integer,Double,Long>>
This generator function generates a stream of car data in a form of a four-element tuple. The
data includes the car's ID, its speed in kilometers per hour, the distance it has traveled in
meters, and the timestamp of the data generation. The speed and distance of each car are randomly
updated in each invocation of the map(Long)
method.
Constructor and Description |
---|
CarGeneratorFunction(int numOfCars) |
Modifier and Type | Method and Description |
---|---|
Tuple4<Integer,Integer,Double,Long> |
map(Long ignoredIndex) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
close, open
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.