2018-08-20 00:52:19 +02:00
|
|
|
package org.schabi.newpipe.extractor.comments;
|
|
|
|
|
|
|
|
import org.schabi.newpipe.extractor.ListExtractor;
|
|
|
|
import org.schabi.newpipe.extractor.StreamingService;
|
2021-07-29 19:53:43 +02:00
|
|
|
import org.schabi.newpipe.extractor.exceptions.ExtractionException;
|
2020-04-21 19:49:17 +02:00
|
|
|
import org.schabi.newpipe.extractor.exceptions.ParsingException;
|
2018-08-20 00:52:19 +02:00
|
|
|
import org.schabi.newpipe.extractor.linkhandler.ListLinkHandler;
|
|
|
|
|
2020-04-21 19:49:17 +02:00
|
|
|
import javax.annotation.Nonnull;
|
|
|
|
|
2018-08-20 00:52:19 +02:00
|
|
|
public abstract class CommentsExtractor extends ListExtractor<CommentsInfoItem> {
|
|
|
|
|
2021-06-13 17:49:22 +02:00
|
|
|
public CommentsExtractor(final StreamingService service, final ListLinkHandler uiHandler) {
|
2019-04-28 22:03:16 +02:00
|
|
|
super(service, uiHandler);
|
2021-06-13 17:49:22 +02:00
|
|
|
}
|
|
|
|
|
2021-07-07 20:41:59 +02:00
|
|
|
/**
|
|
|
|
* @apiNote Warning: This method is experimental and may get removed in a future release.
|
|
|
|
* @return <code>true</code> if the comments are disabled otherwise <code>false</code> (default)
|
|
|
|
*/
|
2021-07-29 19:53:43 +02:00
|
|
|
public boolean isCommentsDisabled() throws ExtractionException {
|
2021-06-13 17:49:22 +02:00
|
|
|
return false;
|
2019-04-28 22:03:16 +02:00
|
|
|
}
|
2018-08-20 00:52:19 +02:00
|
|
|
|
2022-02-08 11:44:55 +01:00
|
|
|
/**
|
2022-12-08 12:44:02 +01:00
|
|
|
* @return the total number of comments
|
2022-02-08 11:44:55 +01:00
|
|
|
*/
|
|
|
|
public int getCommentsCount() throws ExtractionException {
|
|
|
|
return -1;
|
|
|
|
}
|
|
|
|
|
2020-04-21 19:49:17 +02:00
|
|
|
@Nonnull
|
|
|
|
@Override
|
|
|
|
public String getName() throws ParsingException {
|
|
|
|
return "Comments";
|
|
|
|
}
|
2018-08-20 00:52:19 +02:00
|
|
|
}
|