public class PrintForeachAction<K,V> extends java.lang.Object implements ForeachAction<K,V>
Modifier and Type | Method and Description |
---|---|
void |
apply(K key,
V value)
Perform an action for each record of a stream.
|
void |
close() |
public void apply(K key, V value)
ForeachAction
apply
in interface ForeachAction<K,V>
key
- the key of the recordvalue
- the value of the recordpublic void close()