CreateImageRequest.cc 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  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/ecd/model/CreateImageRequest.h>
  17. using AlibabaCloud::Ecd::Model::CreateImageRequest;
  18. CreateImageRequest::CreateImageRequest()
  19. : RpcServiceRequest("ecd", "2020-09-30", "CreateImage") {
  20. setMethod(HttpRequest::Method::Post);
  21. }
  22. CreateImageRequest::~CreateImageRequest() {}
  23. std::string CreateImageRequest::getSnapshotId() const {
  24. return snapshotId_;
  25. }
  26. void CreateImageRequest::setSnapshotId(const std::string &snapshotId) {
  27. snapshotId_ = snapshotId;
  28. setParameter(std::string("SnapshotId"), snapshotId);
  29. }
  30. std::vector<std::string> CreateImageRequest::getSnapshotIds() const {
  31. return snapshotIds_;
  32. }
  33. void CreateImageRequest::setSnapshotIds(const std::vector<std::string> &snapshotIds) {
  34. snapshotIds_ = snapshotIds;
  35. }
  36. std::string CreateImageRequest::getDescription() const {
  37. return description_;
  38. }
  39. void CreateImageRequest::setDescription(const std::string &description) {
  40. description_ = description;
  41. setParameter(std::string("Description"), description);
  42. }
  43. std::string CreateImageRequest::getDiskType() const {
  44. return diskType_;
  45. }
  46. void CreateImageRequest::setDiskType(const std::string &diskType) {
  47. diskType_ = diskType;
  48. setParameter(std::string("DiskType"), diskType);
  49. }
  50. std::string CreateImageRequest::getRegionId() const {
  51. return regionId_;
  52. }
  53. void CreateImageRequest::setRegionId(const std::string &regionId) {
  54. regionId_ = regionId;
  55. setParameter(std::string("RegionId"), regionId);
  56. }
  57. std::string CreateImageRequest::getImageName() const {
  58. return imageName_;
  59. }
  60. void CreateImageRequest::setImageName(const std::string &imageName) {
  61. imageName_ = imageName;
  62. setParameter(std::string("ImageName"), imageName);
  63. }
  64. bool CreateImageRequest::getAutoCleanUserdata() const {
  65. return autoCleanUserdata_;
  66. }
  67. void CreateImageRequest::setAutoCleanUserdata(bool autoCleanUserdata) {
  68. autoCleanUserdata_ = autoCleanUserdata;
  69. setParameter(std::string("AutoCleanUserdata"), autoCleanUserdata ? "true" : "false");
  70. }
  71. std::string CreateImageRequest::getDesktopId() const {
  72. return desktopId_;
  73. }
  74. void CreateImageRequest::setDesktopId(const std::string &desktopId) {
  75. desktopId_ = desktopId;
  76. setParameter(std::string("DesktopId"), desktopId);
  77. }
  78. std::string CreateImageRequest::getImageResourceType() const {
  79. return imageResourceType_;
  80. }
  81. void CreateImageRequest::setImageResourceType(const std::string &imageResourceType) {
  82. imageResourceType_ = imageResourceType;
  83. setParameter(std::string("ImageResourceType"), imageResourceType);
  84. }