StartMPUTaskRequest.cc 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
  1. /*
  2. * Copyright 2009-2017 Alibaba Cloud All rights reserved.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. #include <alibabacloud/rtc/model/StartMPUTaskRequest.h>
  17. using AlibabaCloud::Rtc::Model::StartMPUTaskRequest;
  18. StartMPUTaskRequest::StartMPUTaskRequest() :
  19. RpcServiceRequest("rtc", "2018-01-11", "StartMPUTask")
  20. {
  21. setMethod(HttpRequest::Method::Post);
  22. }
  23. StartMPUTaskRequest::~StartMPUTaskRequest()
  24. {}
  25. std::vector<StartMPUTaskRequest::UserPanes> StartMPUTaskRequest::getUserPanes()const
  26. {
  27. return userPanes_;
  28. }
  29. void StartMPUTaskRequest::setUserPanes(const std::vector<UserPanes>& userPanes)
  30. {
  31. userPanes_ = userPanes;
  32. for(int dep1 = 0; dep1!= userPanes.size(); dep1++) {
  33. auto userPanesObj = userPanes.at(dep1);
  34. std::string userPanesObjStr = "UserPanes." + std::to_string(dep1 + 1);
  35. setParameter(userPanesObjStr + ".PaneId", std::to_string(userPanesObj.paneId));
  36. setParameter(userPanesObjStr + ".UserId", userPanesObj.userId);
  37. setParameter(userPanesObjStr + ".SourceType", userPanesObj.sourceType);
  38. }
  39. }
  40. int StartMPUTaskRequest::getBackgroundColor()const
  41. {
  42. return backgroundColor_;
  43. }
  44. void StartMPUTaskRequest::setBackgroundColor(int backgroundColor)
  45. {
  46. backgroundColor_ = backgroundColor;
  47. setParameter("BackgroundColor", std::to_string(backgroundColor));
  48. }
  49. int StartMPUTaskRequest::getCropMode()const
  50. {
  51. return cropMode_;
  52. }
  53. void StartMPUTaskRequest::setCropMode(int cropMode)
  54. {
  55. cropMode_ = cropMode;
  56. setParameter("CropMode", std::to_string(cropMode));
  57. }
  58. std::string StartMPUTaskRequest::getTaskProfile()const
  59. {
  60. return taskProfile_;
  61. }
  62. void StartMPUTaskRequest::setTaskProfile(const std::string& taskProfile)
  63. {
  64. taskProfile_ = taskProfile;
  65. setParameter("TaskProfile", taskProfile);
  66. }
  67. std::vector<long> StartMPUTaskRequest::getLayoutIds()const
  68. {
  69. return layoutIds_;
  70. }
  71. void StartMPUTaskRequest::setLayoutIds(const std::vector<long>& layoutIds)
  72. {
  73. layoutIds_ = layoutIds;
  74. for(int dep1 = 0; dep1!= layoutIds.size(); dep1++) {
  75. setParameter("LayoutIds."+ std::to_string(dep1), std::to_string(layoutIds.at(dep1)));
  76. }
  77. }
  78. std::string StartMPUTaskRequest::getTaskId()const
  79. {
  80. return taskId_;
  81. }
  82. void StartMPUTaskRequest::setTaskId(const std::string& taskId)
  83. {
  84. taskId_ = taskId;
  85. setParameter("TaskId", taskId);
  86. }
  87. std::string StartMPUTaskRequest::getStreamURL()const
  88. {
  89. return streamURL_;
  90. }
  91. void StartMPUTaskRequest::setStreamURL(const std::string& streamURL)
  92. {
  93. streamURL_ = streamURL;
  94. setParameter("StreamURL", streamURL);
  95. }
  96. long StartMPUTaskRequest::getOwnerId()const
  97. {
  98. return ownerId_;
  99. }
  100. void StartMPUTaskRequest::setOwnerId(long ownerId)
  101. {
  102. ownerId_ = ownerId;
  103. setParameter("OwnerId", std::to_string(ownerId));
  104. }
  105. std::vector<std::string> StartMPUTaskRequest::getSubSpecUsers()const
  106. {
  107. return subSpecUsers_;
  108. }
  109. void StartMPUTaskRequest::setSubSpecUsers(const std::vector<std::string>& subSpecUsers)
  110. {
  111. subSpecUsers_ = subSpecUsers;
  112. for(int dep1 = 0; dep1!= subSpecUsers.size(); dep1++) {
  113. setParameter("SubSpecUsers."+ std::to_string(dep1), subSpecUsers.at(dep1));
  114. }
  115. }
  116. std::string StartMPUTaskRequest::getAppId()const
  117. {
  118. return appId_;
  119. }
  120. void StartMPUTaskRequest::setAppId(const std::string& appId)
  121. {
  122. appId_ = appId;
  123. setParameter("AppId", appId);
  124. }
  125. int StartMPUTaskRequest::getMediaEncode()const
  126. {
  127. return mediaEncode_;
  128. }
  129. void StartMPUTaskRequest::setMediaEncode(int mediaEncode)
  130. {
  131. mediaEncode_ = mediaEncode;
  132. setParameter("MediaEncode", std::to_string(mediaEncode));
  133. }
  134. std::string StartMPUTaskRequest::getChannelId()const
  135. {
  136. return channelId_;
  137. }
  138. void StartMPUTaskRequest::setChannelId(const std::string& channelId)
  139. {
  140. channelId_ = channelId;
  141. setParameter("ChannelId", channelId);
  142. }