Merge pull request #331 from wb9688/playlist-subchannel

Add sub-channel stuff to PlaylistInfo
This commit is contained in:
wb9688 2020-05-12 10:49:13 +02:00 committed by GitHub
commit efafbbb88a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 42 additions and 0 deletions

View File

@ -84,6 +84,21 @@ public class PlaylistInfo extends ListInfo<StreamInfoItem> {
info.setUploaderAvatarUrl("");
uploaderParsingErrors.add(e);
}
try {
info.setSubChannelUrl(extractor.getSubChannelUrl());
} catch (Exception e) {
uploaderParsingErrors.add(e);
}
try {
info.setSubChannelName(extractor.getSubChannelName());
} catch (Exception e) {
uploaderParsingErrors.add(e);
}
try {
info.setSubChannelAvatarUrl(extractor.getSubChannelAvatarUrl());
} catch (Exception e) {
uploaderParsingErrors.add(e);
}
try {
info.setBannerUrl(extractor.getBannerUrl());
} catch (Exception e) {
@ -107,6 +122,9 @@ public class PlaylistInfo extends ListInfo<StreamInfoItem> {
private String uploaderUrl;
private String uploaderName;
private String uploaderAvatarUrl;
private String subChannelUrl;
private String subChannelName;
private String subChannelAvatarUrl;
private long streamCount = 0;
public String getThumbnailUrl() {
@ -149,6 +167,30 @@ public class PlaylistInfo extends ListInfo<StreamInfoItem> {
this.uploaderAvatarUrl = uploaderAvatarUrl;
}
public String getSubChannelUrl() {
return subChannelUrl;
}
public void setSubChannelUrl(String subChannelUrl) {
this.subChannelUrl = subChannelUrl;
}
public String getSubChannelName() {
return subChannelName;
}
public void setSubChannelName(String subChannelName) {
this.subChannelName = subChannelName;
}
public String getSubChannelAvatarUrl() {
return subChannelAvatarUrl;
}
public void setSubChannelAvatarUrl(String subChannelAvatarUrl) {
this.subChannelAvatarUrl = subChannelAvatarUrl;
}
public long getStreamCount() {
return streamCount;
}