org.gcube.data.streams.generators
Interface Generator<E1,E2>
- Type Parameters:
E1 - the type of elements in the input streamE2 - the type of elements in the output stream
- All Known Implementing Classes:
- Filter, LoggingListener, NoOpGenerator, Processor
public interface Generator<E1,E2>
Yields elements of a Stream from elements of another Stream.
- Author:
- Fabio Simeoni
- See Also:
Stream
yield
E2 yield(E1 element)
throws StreamSkipException,
StreamContingencyException
- Yields an element of a
Stream from an element of another Stream.
- Parameters:
element - the input element
- Returns:
- the output element
- Throws:
StreamSkipException - if no element should be yielded from the input element
StreamContingencyException - if no element can be yielded, because the input element violates pre-conditions
RuntimeException - if no element can be yielded from the input element, becuase of an unrecoverable condition
Copyright © 2012. All Rights Reserved.