|
| 1 | +# coding=utf8 |
| 2 | + |
| 3 | +# Copyright 2018 JDCLOUD.COM |
| 4 | +# |
| 5 | +# Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | +# you may not use this file except in compliance with the License. |
| 7 | +# You may obtain a copy of the License at |
| 8 | +# |
| 9 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | +# |
| 11 | +# Unless required by applicable law or agreed to in writing, software |
| 12 | +# distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | +# See the License for the specific language governing permissions and |
| 15 | +# limitations under the License. |
| 16 | +# |
| 17 | +# NOTE: This class is auto generated by the jdcloud code generator program. |
| 18 | + |
| 19 | +from jdcloud_sdk.core.jdcloudrequest import JDCloudRequest |
| 20 | + |
| 21 | + |
| 22 | +class CreateLiveToVodTaskRequest(JDCloudRequest): |
| 23 | + """ |
| 24 | + 创建直播转点播任务 |
| 25 | + """ |
| 26 | + |
| 27 | + def __init__(self, parameters, header=None, version="v1"): |
| 28 | + super(CreateLiveToVodTaskRequest, self).__init__( |
| 29 | + '/createLiveToVodTask', 'POST', header, version) |
| 30 | + self.parameters = parameters |
| 31 | + |
| 32 | + |
| 33 | +class CreateLiveToVodTaskParameters(object): |
| 34 | + |
| 35 | + def __init__(self, title, fileName, publishDomain, appName, streamName, recordTimes, recordFileType, ): |
| 36 | + """ |
| 37 | + :param title: 视频标题 |
| 38 | + :param fileName: 文件名称 |
| 39 | + :param publishDomain: 推流域名 |
| 40 | + :param appName: 应用名称 |
| 41 | + :param streamName: 流名称 |
| 42 | + :param recordTimes: 录制时间段集合 |
| 43 | +- 支持自定义1-10个时间段,拼接成一个文件 |
| 44 | +- 每个时间段不小于10s |
| 45 | +- 总跨度不超过12小时 |
| 46 | +- 时间段按升序排列且无重叠 |
| 47 | +
|
| 48 | + :param recordFileType: 录制文件类型: |
| 49 | +- 取值: ts, flv, mp4 |
| 50 | +- 不区分大小写 |
| 51 | +
|
| 52 | + """ |
| 53 | + |
| 54 | + self.title = title |
| 55 | + self.fileName = fileName |
| 56 | + self.fileSize = None |
| 57 | + self.coverUrl = None |
| 58 | + self.description = None |
| 59 | + self.categoryId = None |
| 60 | + self.tags = None |
| 61 | + self.transcodeTemplateIds = None |
| 62 | + self.watermarkIds = None |
| 63 | + self.publishDomain = publishDomain |
| 64 | + self.appName = appName |
| 65 | + self.streamName = streamName |
| 66 | + self.recordTimes = recordTimes |
| 67 | + self.recordFileType = recordFileType |
| 68 | + self.taskExternalId = None |
| 69 | + self.priority = None |
| 70 | + |
| 71 | + def setFileSize(self, fileSize): |
| 72 | + """ |
| 73 | + :param fileSize: (Optional) 文件大小 |
| 74 | + """ |
| 75 | + self.fileSize = fileSize |
| 76 | + |
| 77 | + def setCoverUrl(self, coverUrl): |
| 78 | + """ |
| 79 | + :param coverUrl: (Optional) 封面地址 |
| 80 | + """ |
| 81 | + self.coverUrl = coverUrl |
| 82 | + |
| 83 | + def setDescription(self, description): |
| 84 | + """ |
| 85 | + :param description: (Optional) 视频描述 |
| 86 | + """ |
| 87 | + self.description = description |
| 88 | + |
| 89 | + def setCategoryId(self, categoryId): |
| 90 | + """ |
| 91 | + :param categoryId: (Optional) 分类ID |
| 92 | + """ |
| 93 | + self.categoryId = categoryId |
| 94 | + |
| 95 | + def setTags(self, tags): |
| 96 | + """ |
| 97 | + :param tags: (Optional) 视频标签集合 |
| 98 | + """ |
| 99 | + self.tags = tags |
| 100 | + |
| 101 | + def setTranscodeTemplateIds(self, transcodeTemplateIds): |
| 102 | + """ |
| 103 | + :param transcodeTemplateIds: (Optional) 转码模板ID集合 |
| 104 | + """ |
| 105 | + self.transcodeTemplateIds = transcodeTemplateIds |
| 106 | + |
| 107 | + def setWatermarkIds(self, watermarkIds): |
| 108 | + """ |
| 109 | + :param watermarkIds: (Optional) 水印ID集合 |
| 110 | + """ |
| 111 | + self.watermarkIds = watermarkIds |
| 112 | + |
| 113 | + def setTaskExternalId(self, taskExternalId): |
| 114 | + """ |
| 115 | + :param taskExternalId: (Optional) 直播录制任务外键 |
| 116 | + """ |
| 117 | + self.taskExternalId = taskExternalId |
| 118 | + |
| 119 | + def setPriority(self, priority): |
| 120 | + """ |
| 121 | + :param priority: (Optional) 任务优先级: |
| 122 | +- 取值: low, medium, high |
| 123 | +- 不区分大小写 |
| 124 | +
|
| 125 | + """ |
| 126 | + self.priority = priority |
| 127 | + |
0 commit comments