CreateAppRequest.cc 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  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/cloudapi/model/CreateAppRequest.h>
  17. using AlibabaCloud::CloudAPI::Model::CreateAppRequest;
  18. CreateAppRequest::CreateAppRequest() :
  19. RpcServiceRequest("cloudapi", "2016-07-14", "CreateApp")
  20. {}
  21. CreateAppRequest::~CreateAppRequest()
  22. {}
  23. std::string CreateAppRequest::getDescription()const
  24. {
  25. return description_;
  26. }
  27. void CreateAppRequest::setDescription(const std::string& description)
  28. {
  29. description_ = description;
  30. setCoreParameter("Description", description);
  31. }
  32. std::string CreateAppRequest::getAccessKeyId()const
  33. {
  34. return accessKeyId_;
  35. }
  36. void CreateAppRequest::setAccessKeyId(const std::string& accessKeyId)
  37. {
  38. accessKeyId_ = accessKeyId;
  39. setCoreParameter("AccessKeyId", accessKeyId);
  40. }
  41. std::string CreateAppRequest::getAppName()const
  42. {
  43. return appName_;
  44. }
  45. void CreateAppRequest::setAppName(const std::string& appName)
  46. {
  47. appName_ = appName;
  48. setCoreParameter("AppName", appName);
  49. }
  50. std::string CreateAppRequest::getSecurityToken()const
  51. {
  52. return securityToken_;
  53. }
  54. void CreateAppRequest::setSecurityToken(const std::string& securityToken)
  55. {
  56. securityToken_ = securityToken;
  57. setCoreParameter("SecurityToken", securityToken);
  58. }
  59. std::vector<CreateAppRequest::Tag> CreateAppRequest::getTag()const
  60. {
  61. return tag_;
  62. }
  63. void CreateAppRequest::setTag(const std::vector<Tag>& tag)
  64. {
  65. tag_ = tag;
  66. int i = 0;
  67. for(int i = 0; i!= tag.size(); i++) {
  68. auto obj = tag.at(i);
  69. std::string str ="Tag."+ std::to_string(i);
  70. setCoreParameter(str + ".Value", obj.value);
  71. setCoreParameter(str + ".Key", obj.key);
  72. }
  73. }