Code improvements
This commit is contained in:
parent
e062c8cb0d
commit
5bf9fddba9
|
@ -27,11 +27,9 @@ import static org.schabi.newpipe.extractor.services.bandcamp.extractors.Bandcamp
|
||||||
public class BandcampRadioStreamExtractor extends BandcampStreamExtractor {
|
public class BandcampRadioStreamExtractor extends BandcampStreamExtractor {
|
||||||
|
|
||||||
private JsonObject showInfo;
|
private JsonObject showInfo;
|
||||||
private LinkHandler linkHandler;
|
|
||||||
|
|
||||||
public BandcampRadioStreamExtractor(final StreamingService service, final LinkHandler linkHandler) {
|
public BandcampRadioStreamExtractor(final StreamingService service, final LinkHandler linkHandler) {
|
||||||
super(service, linkHandler);
|
super(service, linkHandler);
|
||||||
this.linkHandler = linkHandler;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static JsonObject query(final int id) throws ParsingException {
|
static JsonObject query(final int id) throws ParsingException {
|
||||||
|
@ -64,7 +62,7 @@ public class BandcampRadioStreamExtractor extends BandcampStreamExtractor {
|
||||||
@Nonnull
|
@Nonnull
|
||||||
@Override
|
@Override
|
||||||
public String getUrl() throws ParsingException {
|
public String getUrl() throws ParsingException {
|
||||||
return linkHandler.getUrl();
|
return getLinkHandler().getUrl();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Nonnull
|
@Nonnull
|
||||||
|
|
|
@ -10,7 +10,6 @@ import org.schabi.newpipe.extractor.exceptions.ParsingException;
|
||||||
import org.schabi.newpipe.extractor.services.bandcamp.linkHandler.BandcampChannelLinkHandlerFactory;
|
import org.schabi.newpipe.extractor.services.bandcamp.linkHandler.BandcampChannelLinkHandlerFactory;
|
||||||
|
|
||||||
import static org.junit.Assert.*;
|
import static org.junit.Assert.*;
|
||||||
import static org.junit.Assert.assertTrue;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Test for {@link BandcampChannelLinkHandlerFactory}
|
* Test for {@link BandcampChannelLinkHandlerFactory}
|
||||||
|
|
|
@ -10,7 +10,6 @@ import org.schabi.newpipe.extractor.exceptions.ParsingException;
|
||||||
import org.schabi.newpipe.extractor.services.bandcamp.linkHandler.BandcampStreamLinkHandlerFactory;
|
import org.schabi.newpipe.extractor.services.bandcamp.linkHandler.BandcampStreamLinkHandlerFactory;
|
||||||
|
|
||||||
import static org.junit.Assert.*;
|
import static org.junit.Assert.*;
|
||||||
import static org.junit.Assert.assertFalse;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Test for {@link BandcampStreamLinkHandlerFactory}
|
* Test for {@link BandcampStreamLinkHandlerFactory}
|
||||||
|
|
Loading…
Reference in New Issue