-
-
Notifications
You must be signed in to change notification settings - Fork 517
bbc sounds support #364
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bbc sounds support #364
Conversation
Some videos, especially those that have low views, don't have the usual direct links to all streams, this fix it by properly parsing the DASH manifest from those special cases.
Rely on the DASH manifest streams instead.
|
@Isira-Seneviratne you can make a single review out of multiple code comments instead of a different one for each comment |
Okay, I will. |
| //noinspection EqualsReplaceableByObjectsCall | ||
| return url != null ? url.equals(hls.url) : hls.url == null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since Java 8 support has been enabled in NewPipe, Objects.equals() will be backported for API levels below 19.
| //noinspection EqualsReplaceableByObjectsCall | |
| return url != null ? url.equals(hls.url) : hls.url == null; | |
| return Objects.equals(url, direct.url); |
|
|
||
| @Override | ||
| public int hashCode() { | ||
| return url != null ? url.hashCode() : 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same for Objects.hashCode().
| return url != null ? url.hashCode() : 0; | |
| return Objects.hashCode(url); |
| //noinspection EqualsReplaceableByObjectsCall | ||
| if (baseUrl != null ? !baseUrl.equals(that.baseUrl) : that.baseUrl != null) { | ||
| return false; | ||
| } | ||
|
|
||
| //noinspection EqualsReplaceableByObjectsCall | ||
| return manualDashManifest != null | ||
| ? manualDashManifest.equals(that.manualDashManifest) | ||
| : that.manualDashManifest == null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| //noinspection EqualsReplaceableByObjectsCall | |
| if (baseUrl != null ? !baseUrl.equals(that.baseUrl) : that.baseUrl != null) { | |
| return false; | |
| } | |
| //noinspection EqualsReplaceableByObjectsCall | |
| return manualDashManifest != null | |
| ? manualDashManifest.equals(that.manualDashManifest) | |
| : that.manualDashManifest == null; | |
| return Objects.equals(baseUrl, that.baseUrl) && Objects.equals(manualDashManifest, that.manualDashManifest); |
| int result = baseUrl != null ? baseUrl.hashCode() : 0; | ||
| result = 31 * result + (manualDashManifest != null ? manualDashManifest.hashCode() : 0); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| int result = baseUrl != null ? baseUrl.hashCode() : 0; | |
| result = 31 * result + (manualDashManifest != null ? manualDashManifest.hashCode() : 0); | |
| int result = Objects.hashCode(baseUrl); | |
| result = 31 * result + Objects.hashCode(manualDashManifest); |
| //noinspection EqualsReplaceableByObjectsCall | ||
| return url != null ? url.equals(direct.url) : direct.url == null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| //noinspection EqualsReplaceableByObjectsCall | |
| return url != null ? url.equals(direct.url) : direct.url == null; | |
| return Objects.equals(url, direct.url); |
|
|
||
| @Override | ||
| public int hashCode() { | ||
| return url != null ? url.hashCode() : 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| return url != null ? url.hashCode() : 0; | |
| return Objects.hashCode(url); |
|
@yausername thank you very much, BBC Sounds would be a great addition. What's your status are you still working on it? |
|
Hey, Unfortunately I can't find time. I would be happy to review if someone else wants to take this PR. |
TobiGr
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
uhm. Why did you use kotlin? We decided to keep the extractor kotlin-free / Java-only to help beginners to easily get into extending and fixing the extractor.
Hey @TobiGr If nothing happens I'll take it up when I'm available. |
Requires #358
Closes #304