List of usage examples for org.apache.spark.api.java.function PairFunction subclass-usage
From source file org.apache.crunch.impl.spark.collect.ToByteArrayFunction.java
public class ToByteArrayFunction extends PairFunction<Tuple2<IntByteArray, List<byte[]>>, ByteArray, List<byte[]>> { @Override public Tuple2<ByteArray, List<byte[]>> call(Tuple2<IntByteArray, List<byte[]>> t) throws Exception { return new Tuple2<ByteArray, List<byte[]>>(t._1, t._2); } }
From source file org.apache.crunch.impl.spark.fn.MapOutputFunction.java
public class MapOutputFunction<K, V> extends PairFunction<Pair<K, V>, ByteArray, byte[]> { private final SerDe keySerde; private final SerDe valueSerde; public MapOutputFunction(SerDe keySerde, SerDe valueSerde) {
From source file org.apache.crunch.impl.spark.fn.OutputConverterFunction.java
public class OutputConverterFunction<K, V, S> extends PairFunction<S, K, V> { private Converter<K, V, S, ?> converter; public OutputConverterFunction(Converter<K, V, S, ?> converter) { this.converter = converter; }
From source file org.apache.crunch.impl.spark.fn.PairMapIterableFunction.java
public class PairMapIterableFunction<K, V, S, T> extends PairFunction<Pair<K, List<V>>, S, Iterable<T>> { private final MapFn<Pair<K, List<V>>, Pair<S, Iterable<T>>> fn; private final SparkRuntimeContext runtimeContext; private boolean initialized;
From source file org.apache.crunch.impl.spark.fn.PartitionedMapOutputFunction.java
public class PartitionedMapOutputFunction<K, V> extends PairFunction<Pair<K, V>, IntByteArray, byte[]> { private final SerDe<K> keySerde; private final SerDe<V> valueSerde; private final PGroupedTableType<K, V> ptype; private final Class<? extends Partitioner> partitionerClass;