Package org.schabi.newpipe.extractor
Interface Collector<I,E>
- Type Parameters:
I- the item typeE- the extractor type
- All Known Implementing Classes:
ChannelInfoItemsCollector,CommentsInfoItemsCollector,InfoItemsCollector,MultiInfoItemsCollector,PlaylistInfoItemsCollector,StreamInfoItemsCollector
public interface Collector<I,E>
Collectors are used to simplify the collection of information
from extractors
-
Method Details
-
commit
Try to add an extractor to the collection- Parameters:
extractor- the extractor to add
-
extract
Try to extract the item from an extractor without adding it to the collection- Parameters:
extractor- the extractor to use- Returns:
- the item
- Throws:
ParsingException- thrown if there is an error extracting the required fields of the item.
-
getItems
Get all items- Returns:
- the items
-
getErrors
Get all errors- Returns:
- the errors
-
reset
void reset()Reset all collected items and errors
-