T - the type of objects that are to be transformedS - the resulting type of the transformed objectspublic abstract class AbstractIteratorTransformer<T,S> extends Object implements ITransformer<Iterator<T>,Iterator<S>>
| Constructor and Description |
|---|
AbstractIteratorTransformer() |
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
Closes potentially open readers/writers and finishes the Transformation process
if it is still ongoing.
|
void |
init(AbstractETL<?,?> etl)
Initializes the transformer for a new harvest.
|
Iterator<S> |
transform(Iterator<T> elements)
Transforms an extracted element to a document that can be loaded.
|
protected abstract S |
transformElement(T source)
Transforms a single element.
|
public void init(AbstractETL<?,?> etl)
ITransformerinit in interface ITransformer<Iterator<T>,Iterator<S>>etl - the AbstractETL to which the transformer belongsprotected abstract S transformElement(T source) throws TransformerException
source - a single elementTransformerException - thrown when an element cannot be transformedpublic Iterator<S> transform(Iterator<T> elements) throws TransformerException
ITransformertransform in interface ITransformer<Iterator<T>,Iterator<S>>elements - an extracted elementTransformerException - thrown when an element cannot be transformedpublic void clear()
ITransformerCopyright © 2017–2019. All rights reserved.