Interface CoGroupTaskIterator<T1,T2>
- Type Parameters:
T1- The generic type of the first input's data type.T2- The generic type of the second input's data type.
- All Known Implementing Classes:
NonReusingSortMergeCoGroupIterator,ReusingSortMergeCoGroupIterator
public interface CoGroupTaskIterator<T1,T2>
Interface describing the methods that have to be implemented by local strategies for the CoGroup
Pact.
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()General-purpose close method.Returns an iterable over the left input values for the current key.Returns an iterable over the left input values for the current key.booleannext()Moves the internal pointer to the next key (if present).voidopen()General-purpose open method.
-
Method Details
-
open
General-purpose open method. -
close
void close()General-purpose close method. -
next
Moves the internal pointer to the next key (if present). Returns true if the operation was successful or false if no more keys are present.The key is not necessarily shared by both inputs. In that case an empty iterator is returned by getValues1() or getValues2().
- Returns:
- true on success, false if no more keys are present
- Throws:
IOException
-
getValues1
Returns an iterable over the left input values for the current key.- Returns:
- an iterable over the left input values for the current key.
-
getValues2
Returns an iterable over the left input values for the current key.- Returns:
- an iterable over the left input values for the current key.
-