Package org.schabi.newpipe.extractor
Class MultiInfoItemsCollector
- java.lang.Object
- 
- org.schabi.newpipe.extractor.InfoItemsCollector<InfoItem,InfoItemExtractor>
- 
- org.schabi.newpipe.extractor.MultiInfoItemsCollector
 
 
- 
- All Implemented Interfaces:
- Collector<InfoItem,InfoItemExtractor>
 
 public class MultiInfoItemsCollector extends InfoItemsCollector<InfoItem,InfoItemExtractor> A collector that can handle many extractor types, to be used when a list contains items of different types (e.g. search)This collector can handle the following extractor types: Callingextract(InfoItemExtractor)orInfoItemsCollector.commit(InfoItemExtractor)with any other extractor type will raise an exception.
- 
- 
Constructor SummaryConstructors Constructor Description MultiInfoItemsCollector(int serviceId)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description InfoItemextract(InfoItemExtractor extractor)Try to extract the item from an extractor without adding it to the collectionjava.util.List<java.lang.Throwable>getErrors()Get all errorsvoidreset()Reset all collected items and errors- 
Methods inherited from class org.schabi.newpipe.extractor.InfoItemsCollectoraddError, addItem, commit, getItems, getServiceId
 
- 
 
- 
- 
- 
Method Detail- 
getErrorspublic java.util.List<java.lang.Throwable> getErrors() Description copied from interface:CollectorGet all errors- Specified by:
- getErrorsin interface- Collector<InfoItem,InfoItemExtractor>
- Overrides:
- getErrorsin class- InfoItemsCollector<InfoItem,InfoItemExtractor>
- Returns:
- the errors
 
 - 
resetpublic void reset() Description copied from interface:CollectorReset all collected items and errors- Specified by:
- resetin interface- Collector<InfoItem,InfoItemExtractor>
- Overrides:
- resetin class- InfoItemsCollector<InfoItem,InfoItemExtractor>
 
 - 
extractpublic InfoItem extract(InfoItemExtractor extractor) throws ParsingException Description copied from interface:CollectorTry 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.
 
 
- 
 
-