CreateClusterRequest.cc 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481
  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/cs/model/CreateClusterRequest.h>
  17. using AlibabaCloud::CS::Model::CreateClusterRequest;
  18. CreateClusterRequest::CreateClusterRequest() :
  19. RoaServiceRequest("cs", "2015-12-15")
  20. {
  21. setResourcePath("/clusters");
  22. setMethod(HttpRequest::Method::Post);
  23. }
  24. CreateClusterRequest::~CreateClusterRequest()
  25. {}
  26. std::string CreateClusterRequest::getProxy_mode()const
  27. {
  28. return proxy_mode_;
  29. }
  30. void CreateClusterRequest::setProxy_mode(const std::string& proxy_mode)
  31. {
  32. proxy_mode_ = proxy_mode;
  33. setBodyParameter("Proxy_mode", proxy_mode);
  34. }
  35. std::string CreateClusterRequest::getMaster_system_disk_category()const
  36. {
  37. return master_system_disk_category_;
  38. }
  39. void CreateClusterRequest::setMaster_system_disk_category(const std::string& master_system_disk_category)
  40. {
  41. master_system_disk_category_ = master_system_disk_category;
  42. setBodyParameter("Master_system_disk_category", master_system_disk_category);
  43. }
  44. bool CreateClusterRequest::getCloud_monitor_flags()const
  45. {
  46. return cloud_monitor_flags_;
  47. }
  48. void CreateClusterRequest::setCloud_monitor_flags(bool cloud_monitor_flags)
  49. {
  50. cloud_monitor_flags_ = cloud_monitor_flags;
  51. setBodyParameter("Cloud_monitor_flags", cloud_monitor_flags ? "true" : "false");
  52. }
  53. int CreateClusterRequest::getMaster_period()const
  54. {
  55. return master_period_;
  56. }
  57. void CreateClusterRequest::setMaster_period(int master_period)
  58. {
  59. master_period_ = master_period;
  60. setBodyParameter("Master_period", std::to_string(master_period));
  61. }
  62. bool CreateClusterRequest::getSsh_flags()const
  63. {
  64. return ssh_flags_;
  65. }
  66. void CreateClusterRequest::setSsh_flags(bool ssh_flags)
  67. {
  68. ssh_flags_ = ssh_flags;
  69. setBodyParameter("Ssh_flags", ssh_flags ? "true" : "false");
  70. }
  71. std::string CreateClusterRequest::getSecurity_group_id()const
  72. {
  73. return security_group_id_;
  74. }
  75. void CreateClusterRequest::setSecurity_group_id(const std::string& security_group_id)
  76. {
  77. security_group_id_ = security_group_id;
  78. setBodyParameter("Security_group_id", security_group_id);
  79. }
  80. std::string CreateClusterRequest::getContainer_cidr()const
  81. {
  82. return container_cidr_;
  83. }
  84. void CreateClusterRequest::setContainer_cidr(const std::string& container_cidr)
  85. {
  86. container_cidr_ = container_cidr;
  87. setBodyParameter("Container_cidr", container_cidr);
  88. }
  89. std::string CreateClusterRequest::getCluster_type()const
  90. {
  91. return cluster_type_;
  92. }
  93. void CreateClusterRequest::setCluster_type(const std::string& cluster_type)
  94. {
  95. cluster_type_ = cluster_type;
  96. setBodyParameter("Cluster_type", cluster_type);
  97. }
  98. bool CreateClusterRequest::getEndpoint_public_access()const
  99. {
  100. return endpoint_public_access_;
  101. }
  102. void CreateClusterRequest::setEndpoint_public_access(bool endpoint_public_access)
  103. {
  104. endpoint_public_access_ = endpoint_public_access;
  105. setBodyParameter("Endpoint_public_access", endpoint_public_access ? "true" : "false");
  106. }
  107. bool CreateClusterRequest::getWorker_auto_renew()const
  108. {
  109. return worker_auto_renew_;
  110. }
  111. void CreateClusterRequest::setWorker_auto_renew(bool worker_auto_renew)
  112. {
  113. worker_auto_renew_ = worker_auto_renew;
  114. setBodyParameter("Worker_auto_renew", worker_auto_renew ? "true" : "false");
  115. }
  116. std::string CreateClusterRequest::getPlatform()const
  117. {
  118. return platform_;
  119. }
  120. void CreateClusterRequest::setPlatform(const std::string& platform)
  121. {
  122. platform_ = platform;
  123. setBodyParameter("Platform", platform);
  124. }
  125. std::string CreateClusterRequest::getNode_port_range()const
  126. {
  127. return node_port_range_;
  128. }
  129. void CreateClusterRequest::setNode_port_range(const std::string& node_port_range)
  130. {
  131. node_port_range_ = node_port_range;
  132. setBodyParameter("Node_port_range", node_port_range);
  133. }
  134. std::string CreateClusterRequest::getService_cidr()const
  135. {
  136. return service_cidr_;
  137. }
  138. void CreateClusterRequest::setService_cidr(const std::string& service_cidr)
  139. {
  140. service_cidr_ = service_cidr;
  141. setBodyParameter("Service_cidr", service_cidr);
  142. }
  143. std::string CreateClusterRequest::getLogin_password()const
  144. {
  145. return login_password_;
  146. }
  147. void CreateClusterRequest::setLogin_password(const std::string& login_password)
  148. {
  149. login_password_ = login_password;
  150. setBodyParameter("Login_password", login_password);
  151. }
  152. std::string CreateClusterRequest::getKubernetes_version()const
  153. {
  154. return kubernetes_version_;
  155. }
  156. void CreateClusterRequest::setKubernetes_version(const std::string& kubernetes_version)
  157. {
  158. kubernetes_version_ = kubernetes_version;
  159. setBodyParameter("Kubernetes_version", kubernetes_version);
  160. }
  161. std::string CreateClusterRequest::getMaster_period_unit()const
  162. {
  163. return master_period_unit_;
  164. }
  165. void CreateClusterRequest::setMaster_period_unit(const std::string& master_period_unit)
  166. {
  167. master_period_unit_ = master_period_unit;
  168. setBodyParameter("Master_period_unit", master_period_unit);
  169. }
  170. int CreateClusterRequest::getMaster_system_disk_size()const
  171. {
  172. return master_system_disk_size_;
  173. }
  174. void CreateClusterRequest::setMaster_system_disk_size(int master_system_disk_size)
  175. {
  176. master_system_disk_size_ = master_system_disk_size;
  177. setBodyParameter("Master_system_disk_size", std::to_string(master_system_disk_size));
  178. }
  179. int CreateClusterRequest::getMaster_count()const
  180. {
  181. return master_count_;
  182. }
  183. void CreateClusterRequest::setMaster_count(int master_count)
  184. {
  185. master_count_ = master_count;
  186. setBodyParameter("Master_count", std::to_string(master_count));
  187. }
  188. int CreateClusterRequest::getNum_of_nodes()const
  189. {
  190. return num_of_nodes_;
  191. }
  192. void CreateClusterRequest::setNum_of_nodes(int num_of_nodes)
  193. {
  194. num_of_nodes_ = num_of_nodes;
  195. setBodyParameter("Num_of_nodes", std::to_string(num_of_nodes));
  196. }
  197. bool CreateClusterRequest::getDeletion_protection()const
  198. {
  199. return deletion_protection_;
  200. }
  201. void CreateClusterRequest::setDeletion_protection(bool deletion_protection)
  202. {
  203. deletion_protection_ = deletion_protection;
  204. setBodyParameter("Deletion_protection", deletion_protection ? "true" : "false");
  205. }
  206. std::string CreateClusterRequest::getKey_pair()const
  207. {
  208. return key_pair_;
  209. }
  210. void CreateClusterRequest::setKey_pair(const std::string& key_pair)
  211. {
  212. key_pair_ = key_pair;
  213. setBodyParameter("Key_pair", key_pair);
  214. }
  215. bool CreateClusterRequest::getWorker_data_disk()const
  216. {
  217. return worker_data_disk_;
  218. }
  219. void CreateClusterRequest::setWorker_data_disk(bool worker_data_disk)
  220. {
  221. worker_data_disk_ = worker_data_disk;
  222. setBodyParameter("Worker_data_disk", worker_data_disk ? "true" : "false");
  223. }
  224. bool CreateClusterRequest::getMaster_auto_renew()const
  225. {
  226. return master_auto_renew_;
  227. }
  228. void CreateClusterRequest::setMaster_auto_renew(bool master_auto_renew)
  229. {
  230. master_auto_renew_ = master_auto_renew;
  231. setBodyParameter("Master_auto_renew", master_auto_renew ? "true" : "false");
  232. }
  233. std::string CreateClusterRequest::getRegion_id()const
  234. {
  235. return region_id_;
  236. }
  237. void CreateClusterRequest::setRegion_id(const std::string& region_id)
  238. {
  239. region_id_ = region_id;
  240. setBodyParameter("Region_id", region_id);
  241. }
  242. bool CreateClusterRequest::getSnat_entry()const
  243. {
  244. return snat_entry_;
  245. }
  246. void CreateClusterRequest::setSnat_entry(bool snat_entry)
  247. {
  248. snat_entry_ = snat_entry;
  249. setBodyParameter("Snat_entry", snat_entry ? "true" : "false");
  250. }
  251. std::string CreateClusterRequest::getWorker_system_disk_category()const
  252. {
  253. return worker_system_disk_category_;
  254. }
  255. void CreateClusterRequest::setWorker_system_disk_category(const std::string& worker_system_disk_category)
  256. {
  257. worker_system_disk_category_ = worker_system_disk_category;
  258. setBodyParameter("Worker_system_disk_category", worker_system_disk_category);
  259. }
  260. std::string CreateClusterRequest::getRuntime()const
  261. {
  262. return runtime_;
  263. }
  264. void CreateClusterRequest::setRuntime(const std::string& runtime)
  265. {
  266. runtime_ = runtime;
  267. setBodyParameter("Runtime", runtime);
  268. }
  269. std::string CreateClusterRequest::getWorker_period_unit()const
  270. {
  271. return worker_period_unit_;
  272. }
  273. void CreateClusterRequest::setWorker_period_unit(const std::string& worker_period_unit)
  274. {
  275. worker_period_unit_ = worker_period_unit;
  276. setBodyParameter("Worker_period_unit", worker_period_unit);
  277. }
  278. std::string CreateClusterRequest::getMaster_instance_charge_type()const
  279. {
  280. return master_instance_charge_type_;
  281. }
  282. void CreateClusterRequest::setMaster_instance_charge_type(const std::string& master_instance_charge_type)
  283. {
  284. master_instance_charge_type_ = master_instance_charge_type;
  285. setBodyParameter("Master_instance_charge_type", master_instance_charge_type);
  286. }
  287. std::string CreateClusterRequest::getNode_cidr_mask()const
  288. {
  289. return node_cidr_mask_;
  290. }
  291. void CreateClusterRequest::setNode_cidr_mask(const std::string& node_cidr_mask)
  292. {
  293. node_cidr_mask_ = node_cidr_mask;
  294. setBodyParameter("Node_cidr_mask", node_cidr_mask);
  295. }
  296. int CreateClusterRequest::getWorker_auto_renew_period()const
  297. {
  298. return worker_auto_renew_period_;
  299. }
  300. void CreateClusterRequest::setWorker_auto_renew_period(int worker_auto_renew_period)
  301. {
  302. worker_auto_renew_period_ = worker_auto_renew_period;
  303. setBodyParameter("Worker_auto_renew_period", std::to_string(worker_auto_renew_period));
  304. }
  305. int CreateClusterRequest::getMaster_auto_renew_period()const
  306. {
  307. return master_auto_renew_period_;
  308. }
  309. void CreateClusterRequest::setMaster_auto_renew_period(int master_auto_renew_period)
  310. {
  311. master_auto_renew_period_ = master_auto_renew_period;
  312. setBodyParameter("Master_auto_renew_period", std::to_string(master_auto_renew_period));
  313. }
  314. int CreateClusterRequest::getWorker_period()const
  315. {
  316. return worker_period_;
  317. }
  318. void CreateClusterRequest::setWorker_period(int worker_period)
  319. {
  320. worker_period_ = worker_period;
  321. setBodyParameter("Worker_period", std::to_string(worker_period));
  322. }
  323. int CreateClusterRequest::getTimeout_mins()const
  324. {
  325. return timeout_mins_;
  326. }
  327. void CreateClusterRequest::setTimeout_mins(int timeout_mins)
  328. {
  329. timeout_mins_ = timeout_mins;
  330. setBodyParameter("Timeout_mins", std::to_string(timeout_mins));
  331. }
  332. int CreateClusterRequest::getWorker_system_disk_size()const
  333. {
  334. return worker_system_disk_size_;
  335. }
  336. void CreateClusterRequest::setWorker_system_disk_size(int worker_system_disk_size)
  337. {
  338. worker_system_disk_size_ = worker_system_disk_size;
  339. setBodyParameter("Worker_system_disk_size", std::to_string(worker_system_disk_size));
  340. }
  341. std::string CreateClusterRequest::getOs_type()const
  342. {
  343. return os_type_;
  344. }
  345. void CreateClusterRequest::setOs_type(const std::string& os_type)
  346. {
  347. os_type_ = os_type;
  348. setBodyParameter("Os_type", os_type);
  349. }
  350. std::string CreateClusterRequest::getCpu_policy()const
  351. {
  352. return cpu_policy_;
  353. }
  354. void CreateClusterRequest::setCpu_policy(const std::string& cpu_policy)
  355. {
  356. cpu_policy_ = cpu_policy;
  357. setBodyParameter("Cpu_policy", cpu_policy);
  358. }
  359. std::string CreateClusterRequest::getVpcid()const
  360. {
  361. return vpcid_;
  362. }
  363. void CreateClusterRequest::setVpcid(const std::string& vpcid)
  364. {
  365. vpcid_ = vpcid;
  366. setBodyParameter("Vpcid", vpcid);
  367. }
  368. std::string CreateClusterRequest::getName()const
  369. {
  370. return name_;
  371. }
  372. void CreateClusterRequest::setName(const std::string& name)
  373. {
  374. name_ = name;
  375. setBodyParameter("Name", name);
  376. }
  377. bool CreateClusterRequest::getDisable_rollback()const
  378. {
  379. return disable_rollback_;
  380. }
  381. void CreateClusterRequest::setDisable_rollback(bool disable_rollback)
  382. {
  383. disable_rollback_ = disable_rollback;
  384. setBodyParameter("Disable_rollback", disable_rollback ? "true" : "false");
  385. }
  386. std::string CreateClusterRequest::getWorker_instance_charge_type()const
  387. {
  388. return worker_instance_charge_type_;
  389. }
  390. void CreateClusterRequest::setWorker_instance_charge_type(const std::string& worker_instance_charge_type)
  391. {
  392. worker_instance_charge_type_ = worker_instance_charge_type;
  393. setBodyParameter("Worker_instance_charge_type", worker_instance_charge_type);
  394. }