org.heigit.bigspatialdata.oshdb.api.mapreducer.MapAggregatable Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of oshdb-api Show documentation
Show all versions of oshdb-api Show documentation
API to query the OpenStreetMap History Database. Includes MapReduce functionality to filter, analyze and aggregate data.
package org.heigit.bigspatialdata.oshdb.api.mapreducer;
import java.io.Serializable;
import org.heigit.bigspatialdata.oshdb.api.generic.function.SerializableFunction;
/**
* Interface for MapReducers or MapAggregators that can be aggregated by an arbitrary index.
*
* @param the resulting class of the aggregateBy operation
* @param the data type the index function is supplied with
*/
interface MapAggregatable {
/**
* Sets a custom aggregation function that is used to (further) group output results into.
*
* @param indexer a function that will be called for each input element and returns a value that
* will be used to group the results by
* @param data type of the values used to aggregate the output. has to be a comparable type
* @return a MapAggregator object with the equivalent state (settings, filters, map function,
* etc.) of the current MapReducer object
*/
& Serializable> M aggregateBy(SerializableFunction indexer);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy