Package org.schabi.newpipe.extractor
Class InfoItemsCollector<I extends InfoItem,E extends InfoItemExtractor>
java.lang.Object
org.schabi.newpipe.extractor.InfoItemsCollector<I,E>
- All Implemented Interfaces:
Collector<I,E>
- Direct Known Subclasses:
ChannelInfoItemsCollector,CommentsInfoItemsCollector,MultiInfoItemsCollector,PlaylistInfoItemsCollector,StreamInfoItemsCollector
public abstract class InfoItemsCollector<I extends InfoItem,E extends InfoItemExtractor>
extends Object
implements Collector<I,E>
-
Constructor Summary
ConstructorsConstructorDescriptionInfoItemsCollector(int serviceId) Create a new collector with no comparator / sorting functionInfoItemsCollector(int serviceId, Comparator<I> comparator) Create a new collector -
Method Summary
-
Constructor Details
-
InfoItemsCollector
public InfoItemsCollector(int serviceId) Create a new collector with no comparator / sorting function- Parameters:
serviceId- the service id
-
InfoItemsCollector
Create a new collector- Parameters:
serviceId- the service id
-
-
Method Details
-
getItems
Description copied from interface:CollectorGet all items -
getErrors
Description copied from interface:CollectorGet all errors -
reset
public void reset()Description copied from interface:CollectorReset all collected items and errors -
addError
Add an error- Parameters:
error- the error
-
addItem
Add an item- Parameters:
item- the item
-
getServiceId
public int getServiceId()Get the service id- Returns:
- the service id
-
commit
Description copied from interface:CollectorTry to add an extractor to the collection
-