|
@@ -3,6 +3,7 @@ package com.ym.mec.biz.dal.vo;
|
|
|
import com.ym.mec.biz.dal.entity.ImLiveRoomVideo;
|
|
|
import io.swagger.annotations.ApiModel;
|
|
|
import io.swagger.annotations.ApiModelProperty;
|
|
|
+import org.apache.commons.lang3.StringUtils;
|
|
|
|
|
|
import java.io.Serializable;
|
|
|
|
|
@@ -12,6 +13,9 @@ public class ImLiveRoomVideoVo extends ImLiveRoomVideo implements Serializable {
|
|
|
@ApiModelProperty(value = "播出端- pc网页端 移动端mobile")
|
|
|
private String os;
|
|
|
|
|
|
+ @ApiModelProperty("视频类型")
|
|
|
+ private String videoType;
|
|
|
+
|
|
|
public String getOs() {
|
|
|
return os;
|
|
|
}
|
|
@@ -19,4 +23,22 @@ public class ImLiveRoomVideoVo extends ImLiveRoomVideo implements Serializable {
|
|
|
public void setOs(String os) {
|
|
|
this.os = os;
|
|
|
}
|
|
|
+
|
|
|
+ public String getVideoType() {
|
|
|
+
|
|
|
+ if (StringUtils.isNotEmpty(getUrl())) {
|
|
|
+
|
|
|
+ String fileName = getUrl();
|
|
|
+ int indexOf = fileName.lastIndexOf("?");
|
|
|
+ if (indexOf > -1) {
|
|
|
+ fileName = getUrl().substring(0, indexOf);
|
|
|
+ }
|
|
|
+ return fileName.substring(fileName.lastIndexOf(".") + 1);
|
|
|
+ }
|
|
|
+ return videoType;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setVideoType(String videoType) {
|
|
|
+ this.videoType = videoType;
|
|
|
+ }
|
|
|
}
|