Add ImageFamily paramters and apis, in Instance creation apis and Image query apis, and add DescribeImageFromFamily.
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
2020-03-16 Version: 1.36.319
|
||||
- Add ImageFamily paramters and apis, in Instance creation apis and Image query apis, and add DescribeImageFromFamily.
|
||||
- Add Instance batch operation apis RebootInstances StartInstances and StopInstances.
|
||||
- Add EncryptAlgorithm paramter in instance creati
|
||||
|
||||
2020-03-13 Version: 1.36.318
|
||||
- ACM POP SDK.
|
||||
|
||||
|
||||
@@ -241,6 +241,8 @@ set(ecs_public_header_model
|
||||
include/alibabacloud/ecs/model/DescribeHaVipsResult.h
|
||||
include/alibabacloud/ecs/model/DescribeHpcClustersRequest.h
|
||||
include/alibabacloud/ecs/model/DescribeHpcClustersResult.h
|
||||
include/alibabacloud/ecs/model/DescribeImageFromFamilyRequest.h
|
||||
include/alibabacloud/ecs/model/DescribeImageFromFamilyResult.h
|
||||
include/alibabacloud/ecs/model/DescribeImageSharePermissionRequest.h
|
||||
include/alibabacloud/ecs/model/DescribeImageSharePermissionResult.h
|
||||
include/alibabacloud/ecs/model/DescribeImageSupportInstanceTypesRequest.h
|
||||
@@ -509,6 +511,8 @@ set(ecs_public_header_model
|
||||
include/alibabacloud/ecs/model/ReInitDiskResult.h
|
||||
include/alibabacloud/ecs/model/RebootInstanceRequest.h
|
||||
include/alibabacloud/ecs/model/RebootInstanceResult.h
|
||||
include/alibabacloud/ecs/model/RebootInstancesRequest.h
|
||||
include/alibabacloud/ecs/model/RebootInstancesResult.h
|
||||
include/alibabacloud/ecs/model/RecoverVirtualBorderRouterRequest.h
|
||||
include/alibabacloud/ecs/model/RecoverVirtualBorderRouterResult.h
|
||||
include/alibabacloud/ecs/model/RedeployDedicatedHostRequest.h
|
||||
@@ -547,8 +551,12 @@ set(ecs_public_header_model
|
||||
include/alibabacloud/ecs/model/RunInstancesResult.h
|
||||
include/alibabacloud/ecs/model/StartInstanceRequest.h
|
||||
include/alibabacloud/ecs/model/StartInstanceResult.h
|
||||
include/alibabacloud/ecs/model/StartInstancesRequest.h
|
||||
include/alibabacloud/ecs/model/StartInstancesResult.h
|
||||
include/alibabacloud/ecs/model/StopInstanceRequest.h
|
||||
include/alibabacloud/ecs/model/StopInstanceResult.h
|
||||
include/alibabacloud/ecs/model/StopInstancesRequest.h
|
||||
include/alibabacloud/ecs/model/StopInstancesResult.h
|
||||
include/alibabacloud/ecs/model/StopInvocationRequest.h
|
||||
include/alibabacloud/ecs/model/StopInvocationResult.h
|
||||
include/alibabacloud/ecs/model/TagResourcesRequest.h
|
||||
@@ -790,6 +798,8 @@ set(ecs_src
|
||||
src/model/DescribeHaVipsResult.cc
|
||||
src/model/DescribeHpcClustersRequest.cc
|
||||
src/model/DescribeHpcClustersResult.cc
|
||||
src/model/DescribeImageFromFamilyRequest.cc
|
||||
src/model/DescribeImageFromFamilyResult.cc
|
||||
src/model/DescribeImageSharePermissionRequest.cc
|
||||
src/model/DescribeImageSharePermissionResult.cc
|
||||
src/model/DescribeImageSupportInstanceTypesRequest.cc
|
||||
@@ -1058,6 +1068,8 @@ set(ecs_src
|
||||
src/model/ReInitDiskResult.cc
|
||||
src/model/RebootInstanceRequest.cc
|
||||
src/model/RebootInstanceResult.cc
|
||||
src/model/RebootInstancesRequest.cc
|
||||
src/model/RebootInstancesResult.cc
|
||||
src/model/RecoverVirtualBorderRouterRequest.cc
|
||||
src/model/RecoverVirtualBorderRouterResult.cc
|
||||
src/model/RedeployDedicatedHostRequest.cc
|
||||
@@ -1096,8 +1108,12 @@ set(ecs_src
|
||||
src/model/RunInstancesResult.cc
|
||||
src/model/StartInstanceRequest.cc
|
||||
src/model/StartInstanceResult.cc
|
||||
src/model/StartInstancesRequest.cc
|
||||
src/model/StartInstancesResult.cc
|
||||
src/model/StopInstanceRequest.cc
|
||||
src/model/StopInstanceResult.cc
|
||||
src/model/StopInstancesRequest.cc
|
||||
src/model/StopInstancesResult.cc
|
||||
src/model/StopInvocationRequest.cc
|
||||
src/model/StopInvocationResult.cc
|
||||
src/model/TagResourcesRequest.cc
|
||||
|
||||
@@ -242,6 +242,8 @@
|
||||
#include "model/DescribeHaVipsResult.h"
|
||||
#include "model/DescribeHpcClustersRequest.h"
|
||||
#include "model/DescribeHpcClustersResult.h"
|
||||
#include "model/DescribeImageFromFamilyRequest.h"
|
||||
#include "model/DescribeImageFromFamilyResult.h"
|
||||
#include "model/DescribeImageSharePermissionRequest.h"
|
||||
#include "model/DescribeImageSharePermissionResult.h"
|
||||
#include "model/DescribeImageSupportInstanceTypesRequest.h"
|
||||
@@ -510,6 +512,8 @@
|
||||
#include "model/ReInitDiskResult.h"
|
||||
#include "model/RebootInstanceRequest.h"
|
||||
#include "model/RebootInstanceResult.h"
|
||||
#include "model/RebootInstancesRequest.h"
|
||||
#include "model/RebootInstancesResult.h"
|
||||
#include "model/RecoverVirtualBorderRouterRequest.h"
|
||||
#include "model/RecoverVirtualBorderRouterResult.h"
|
||||
#include "model/RedeployDedicatedHostRequest.h"
|
||||
@@ -548,8 +552,12 @@
|
||||
#include "model/RunInstancesResult.h"
|
||||
#include "model/StartInstanceRequest.h"
|
||||
#include "model/StartInstanceResult.h"
|
||||
#include "model/StartInstancesRequest.h"
|
||||
#include "model/StartInstancesResult.h"
|
||||
#include "model/StopInstanceRequest.h"
|
||||
#include "model/StopInstanceResult.h"
|
||||
#include "model/StopInstancesRequest.h"
|
||||
#include "model/StopInstancesResult.h"
|
||||
#include "model/StopInvocationRequest.h"
|
||||
#include "model/StopInvocationResult.h"
|
||||
#include "model/TagResourcesRequest.h"
|
||||
@@ -907,6 +915,9 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::DescribeHpcClustersResult> DescribeHpcClustersOutcome;
|
||||
typedef std::future<DescribeHpcClustersOutcome> DescribeHpcClustersOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::DescribeHpcClustersRequest&, const DescribeHpcClustersOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeHpcClustersAsyncHandler;
|
||||
typedef Outcome<Error, Model::DescribeImageFromFamilyResult> DescribeImageFromFamilyOutcome;
|
||||
typedef std::future<DescribeImageFromFamilyOutcome> DescribeImageFromFamilyOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::DescribeImageFromFamilyRequest&, const DescribeImageFromFamilyOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeImageFromFamilyAsyncHandler;
|
||||
typedef Outcome<Error, Model::DescribeImageSharePermissionResult> DescribeImageSharePermissionOutcome;
|
||||
typedef std::future<DescribeImageSharePermissionOutcome> DescribeImageSharePermissionOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::DescribeImageSharePermissionRequest&, const DescribeImageSharePermissionOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeImageSharePermissionAsyncHandler;
|
||||
@@ -1309,6 +1320,9 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::RebootInstanceResult> RebootInstanceOutcome;
|
||||
typedef std::future<RebootInstanceOutcome> RebootInstanceOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::RebootInstanceRequest&, const RebootInstanceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RebootInstanceAsyncHandler;
|
||||
typedef Outcome<Error, Model::RebootInstancesResult> RebootInstancesOutcome;
|
||||
typedef std::future<RebootInstancesOutcome> RebootInstancesOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::RebootInstancesRequest&, const RebootInstancesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RebootInstancesAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecoverVirtualBorderRouterResult> RecoverVirtualBorderRouterOutcome;
|
||||
typedef std::future<RecoverVirtualBorderRouterOutcome> RecoverVirtualBorderRouterOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::RecoverVirtualBorderRouterRequest&, const RecoverVirtualBorderRouterOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecoverVirtualBorderRouterAsyncHandler;
|
||||
@@ -1366,9 +1380,15 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::StartInstanceResult> StartInstanceOutcome;
|
||||
typedef std::future<StartInstanceOutcome> StartInstanceOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::StartInstanceRequest&, const StartInstanceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> StartInstanceAsyncHandler;
|
||||
typedef Outcome<Error, Model::StartInstancesResult> StartInstancesOutcome;
|
||||
typedef std::future<StartInstancesOutcome> StartInstancesOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::StartInstancesRequest&, const StartInstancesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> StartInstancesAsyncHandler;
|
||||
typedef Outcome<Error, Model::StopInstanceResult> StopInstanceOutcome;
|
||||
typedef std::future<StopInstanceOutcome> StopInstanceOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::StopInstanceRequest&, const StopInstanceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> StopInstanceAsyncHandler;
|
||||
typedef Outcome<Error, Model::StopInstancesResult> StopInstancesOutcome;
|
||||
typedef std::future<StopInstancesOutcome> StopInstancesOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::StopInstancesRequest&, const StopInstancesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> StopInstancesAsyncHandler;
|
||||
typedef Outcome<Error, Model::StopInvocationResult> StopInvocationOutcome;
|
||||
typedef std::future<StopInvocationOutcome> StopInvocationOutcomeCallable;
|
||||
typedef std::function<void(const EcsClient*, const Model::StopInvocationRequest&, const StopInvocationOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> StopInvocationAsyncHandler;
|
||||
@@ -1731,6 +1751,9 @@ namespace AlibabaCloud
|
||||
DescribeHpcClustersOutcome describeHpcClusters(const Model::DescribeHpcClustersRequest &request)const;
|
||||
void describeHpcClustersAsync(const Model::DescribeHpcClustersRequest& request, const DescribeHpcClustersAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DescribeHpcClustersOutcomeCallable describeHpcClustersCallable(const Model::DescribeHpcClustersRequest& request) const;
|
||||
DescribeImageFromFamilyOutcome describeImageFromFamily(const Model::DescribeImageFromFamilyRequest &request)const;
|
||||
void describeImageFromFamilyAsync(const Model::DescribeImageFromFamilyRequest& request, const DescribeImageFromFamilyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DescribeImageFromFamilyOutcomeCallable describeImageFromFamilyCallable(const Model::DescribeImageFromFamilyRequest& request) const;
|
||||
DescribeImageSharePermissionOutcome describeImageSharePermission(const Model::DescribeImageSharePermissionRequest &request)const;
|
||||
void describeImageSharePermissionAsync(const Model::DescribeImageSharePermissionRequest& request, const DescribeImageSharePermissionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DescribeImageSharePermissionOutcomeCallable describeImageSharePermissionCallable(const Model::DescribeImageSharePermissionRequest& request) const;
|
||||
@@ -2133,6 +2156,9 @@ namespace AlibabaCloud
|
||||
RebootInstanceOutcome rebootInstance(const Model::RebootInstanceRequest &request)const;
|
||||
void rebootInstanceAsync(const Model::RebootInstanceRequest& request, const RebootInstanceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RebootInstanceOutcomeCallable rebootInstanceCallable(const Model::RebootInstanceRequest& request) const;
|
||||
RebootInstancesOutcome rebootInstances(const Model::RebootInstancesRequest &request)const;
|
||||
void rebootInstancesAsync(const Model::RebootInstancesRequest& request, const RebootInstancesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RebootInstancesOutcomeCallable rebootInstancesCallable(const Model::RebootInstancesRequest& request) const;
|
||||
RecoverVirtualBorderRouterOutcome recoverVirtualBorderRouter(const Model::RecoverVirtualBorderRouterRequest &request)const;
|
||||
void recoverVirtualBorderRouterAsync(const Model::RecoverVirtualBorderRouterRequest& request, const RecoverVirtualBorderRouterAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecoverVirtualBorderRouterOutcomeCallable recoverVirtualBorderRouterCallable(const Model::RecoverVirtualBorderRouterRequest& request) const;
|
||||
@@ -2190,9 +2216,15 @@ namespace AlibabaCloud
|
||||
StartInstanceOutcome startInstance(const Model::StartInstanceRequest &request)const;
|
||||
void startInstanceAsync(const Model::StartInstanceRequest& request, const StartInstanceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
StartInstanceOutcomeCallable startInstanceCallable(const Model::StartInstanceRequest& request) const;
|
||||
StartInstancesOutcome startInstances(const Model::StartInstancesRequest &request)const;
|
||||
void startInstancesAsync(const Model::StartInstancesRequest& request, const StartInstancesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
StartInstancesOutcomeCallable startInstancesCallable(const Model::StartInstancesRequest& request) const;
|
||||
StopInstanceOutcome stopInstance(const Model::StopInstanceRequest &request)const;
|
||||
void stopInstanceAsync(const Model::StopInstanceRequest& request, const StopInstanceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
StopInstanceOutcomeCallable stopInstanceCallable(const Model::StopInstanceRequest& request) const;
|
||||
StopInstancesOutcome stopInstances(const Model::StopInstancesRequest &request)const;
|
||||
void stopInstancesAsync(const Model::StopInstancesRequest& request, const StopInstancesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
StopInstancesOutcomeCallable stopInstancesCallable(const Model::StopInstancesRequest& request) const;
|
||||
StopInvocationOutcome stopInvocation(const Model::StopInvocationRequest &request)const;
|
||||
void stopInvocationAsync(const Model::StopInvocationRequest& request, const StopInvocationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
StopInvocationOutcomeCallable stopInvocationCallable(const Model::StopInvocationRequest& request) const;
|
||||
|
||||
@@ -45,6 +45,8 @@ namespace AlibabaCloud
|
||||
void setResourceOwnerId(long resourceOwnerId);
|
||||
std::string getImageId()const;
|
||||
void setImageId(const std::string& imageId);
|
||||
std::string getEncryptAlgorithm()const;
|
||||
void setEncryptAlgorithm(const std::string& encryptAlgorithm);
|
||||
std::string getDestinationRegionId()const;
|
||||
void setDestinationRegionId(const std::string& destinationRegionId);
|
||||
std::string getRegionId()const;
|
||||
@@ -69,6 +71,7 @@ namespace AlibabaCloud
|
||||
private:
|
||||
long resourceOwnerId_;
|
||||
std::string imageId_;
|
||||
std::string encryptAlgorithm_;
|
||||
std::string destinationRegionId_;
|
||||
std::string regionId_;
|
||||
std::vector<Tag> tag_;
|
||||
|
||||
@@ -53,6 +53,8 @@ namespace AlibabaCloud
|
||||
void setSnapshotId(const std::string& snapshotId);
|
||||
std::string getClientToken()const;
|
||||
void setClientToken(const std::string& clientToken);
|
||||
std::string getEncryptAlgorithm()const;
|
||||
void setEncryptAlgorithm(const std::string& encryptAlgorithm);
|
||||
std::string getDescription()const;
|
||||
void setDescription(const std::string& description);
|
||||
std::string getDiskName()const;
|
||||
@@ -96,6 +98,7 @@ namespace AlibabaCloud
|
||||
long resourceOwnerId_;
|
||||
std::string snapshotId_;
|
||||
std::string clientToken_;
|
||||
std::string encryptAlgorithm_;
|
||||
std::string description_;
|
||||
std::string diskName_;
|
||||
std::string resourceGroupId_;
|
||||
|
||||
@@ -78,6 +78,8 @@ namespace AlibabaCloud
|
||||
void setOwnerId(long ownerId);
|
||||
std::string getInstanceId()const;
|
||||
void setInstanceId(const std::string& instanceId);
|
||||
std::string getImageFamily()const;
|
||||
void setImageFamily(const std::string& imageFamily);
|
||||
std::string getImageVersion()const;
|
||||
void setImageVersion(const std::string& imageVersion);
|
||||
|
||||
@@ -97,6 +99,7 @@ namespace AlibabaCloud
|
||||
std::string ownerAccount_;
|
||||
long ownerId_;
|
||||
std::string instanceId_;
|
||||
std::string imageFamily_;
|
||||
std::string imageVersion_;
|
||||
|
||||
};
|
||||
|
||||
@@ -49,6 +49,7 @@ namespace AlibabaCloud
|
||||
int size;
|
||||
bool encrypted;
|
||||
std::string performanceLevel;
|
||||
std::string encryptAlgorithm;
|
||||
std::string description;
|
||||
std::string category;
|
||||
std::string kMSKeyId;
|
||||
@@ -178,6 +179,8 @@ namespace AlibabaCloud
|
||||
void setStorageSetId(const std::string& storageSetId);
|
||||
int getSystemDiskSize()const;
|
||||
void setSystemDiskSize(int systemDiskSize);
|
||||
std::string getImageFamily()const;
|
||||
void setImageFamily(const std::string& imageFamily);
|
||||
std::string getSystemDiskDescription()const;
|
||||
void setSystemDiskDescription(const std::string& systemDiskDescription);
|
||||
|
||||
@@ -241,6 +244,7 @@ namespace AlibabaCloud
|
||||
std::vector<DataDisk> dataDisk_;
|
||||
std::string storageSetId_;
|
||||
int systemDiskSize_;
|
||||
std::string imageFamily_;
|
||||
std::string systemDiskDescription_;
|
||||
|
||||
};
|
||||
|
||||
@@ -40,6 +40,7 @@ namespace AlibabaCloud
|
||||
std::string instanceChargeType;
|
||||
std::string expiredTime;
|
||||
std::string value;
|
||||
std::string diskCategory;
|
||||
int count;
|
||||
std::string instanceType;
|
||||
};
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ECS_MODEL_DESCRIBEIMAGEFROMFAMILYREQUEST_H_
|
||||
#define ALIBABACLOUD_ECS_MODEL_DESCRIBEIMAGEFROMFAMILYREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/ecs/EcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ecs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ECS_EXPORT DescribeImageFromFamilyRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
DescribeImageFromFamilyRequest();
|
||||
~DescribeImageFromFamilyRequest();
|
||||
|
||||
long getResourceOwnerId()const;
|
||||
void setResourceOwnerId(long resourceOwnerId);
|
||||
std::string getRegionId()const;
|
||||
void setRegionId(const std::string& regionId);
|
||||
std::string getResourceOwnerAccount()const;
|
||||
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
|
||||
std::string getOwnerAccount()const;
|
||||
void setOwnerAccount(const std::string& ownerAccount);
|
||||
long getOwnerId()const;
|
||||
void setOwnerId(long ownerId);
|
||||
std::string getImageFamily()const;
|
||||
void setImageFamily(const std::string& imageFamily);
|
||||
|
||||
private:
|
||||
long resourceOwnerId_;
|
||||
std::string regionId_;
|
||||
std::string resourceOwnerAccount_;
|
||||
std::string ownerAccount_;
|
||||
long ownerId_;
|
||||
std::string imageFamily_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ECS_MODEL_DESCRIBEIMAGEFROMFAMILYREQUEST_H_
|
||||
@@ -0,0 +1,92 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ECS_MODEL_DESCRIBEIMAGEFROMFAMILYRESULT_H_
|
||||
#define ALIBABACLOUD_ECS_MODEL_DESCRIBEIMAGEFROMFAMILYRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ecs/EcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ecs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ECS_EXPORT DescribeImageFromFamilyResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Image
|
||||
{
|
||||
struct DiskDeviceMapping
|
||||
{
|
||||
std::string snapshotId;
|
||||
std::string type;
|
||||
std::string format;
|
||||
std::string size;
|
||||
std::string device;
|
||||
std::string importOSSBucket;
|
||||
std::string importOSSObject;
|
||||
};
|
||||
struct Tag
|
||||
{
|
||||
std::string tagKey;
|
||||
std::string tagValue;
|
||||
};
|
||||
std::string imageOwnerAlias;
|
||||
std::string status;
|
||||
std::string progress;
|
||||
std::string usage;
|
||||
std::string description;
|
||||
std::string isSelfShared;
|
||||
std::string architecture;
|
||||
std::string platform;
|
||||
std::string productCode;
|
||||
int size;
|
||||
bool isSubscribed;
|
||||
bool isCopied;
|
||||
std::string imageFamily;
|
||||
std::string oSName;
|
||||
bool isSupportIoOptimized;
|
||||
bool isSupportCloudinit;
|
||||
std::string imageName;
|
||||
std::vector<DiskDeviceMapping> diskDeviceMappings;
|
||||
std::string imageVersion;
|
||||
std::string oSType;
|
||||
std::string imageId;
|
||||
std::string creationTime;
|
||||
std::vector<Tag> tags;
|
||||
};
|
||||
|
||||
|
||||
DescribeImageFromFamilyResult();
|
||||
explicit DescribeImageFromFamilyResult(const std::string &payload);
|
||||
~DescribeImageFromFamilyResult();
|
||||
Image getImage()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Image image_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ECS_MODEL_DESCRIBEIMAGEFROMFAMILYRESULT_H_
|
||||
@@ -92,6 +92,8 @@ namespace AlibabaCloud
|
||||
void setOwnerId(long ownerId);
|
||||
std::vector<Filter> getFilter()const;
|
||||
void setFilter(const std::vector<Filter>& filter);
|
||||
std::string getImageFamily()const;
|
||||
void setImageFamily(const std::string& imageFamily);
|
||||
std::string getStatus()const;
|
||||
void setStatus(const std::string& status);
|
||||
|
||||
@@ -119,6 +121,7 @@ namespace AlibabaCloud
|
||||
std::string oSType_;
|
||||
long ownerId_;
|
||||
std::vector<Filter> filter_;
|
||||
std::string imageFamily_;
|
||||
std::string status_;
|
||||
|
||||
};
|
||||
|
||||
@@ -52,29 +52,30 @@ namespace AlibabaCloud
|
||||
std::string tagValue;
|
||||
};
|
||||
std::string imageOwnerAlias;
|
||||
std::string description;
|
||||
std::string isSelfShared;
|
||||
std::string platform;
|
||||
std::string resourceGroupId;
|
||||
int size;
|
||||
bool isSubscribed;
|
||||
std::string oSName;
|
||||
std::string imageId;
|
||||
std::vector<Image::Tag> tags;
|
||||
std::string oSNameEn;
|
||||
std::string status;
|
||||
std::string progress;
|
||||
std::string usage;
|
||||
std::string description;
|
||||
std::string isSelfShared;
|
||||
std::string architecture;
|
||||
std::string platform;
|
||||
std::string resourceGroupId;
|
||||
std::string productCode;
|
||||
int size;
|
||||
bool isSubscribed;
|
||||
bool isCopied;
|
||||
std::string oSName;
|
||||
std::string imageFamily;
|
||||
bool isSupportIoOptimized;
|
||||
bool isSupportCloudinit;
|
||||
std::string imageName;
|
||||
std::vector<Image::DiskDeviceMapping> diskDeviceMappings;
|
||||
std::string imageVersion;
|
||||
std::string oSType;
|
||||
std::string imageId;
|
||||
std::string creationTime;
|
||||
std::vector<Image::Tag> tags;
|
||||
std::string oSNameEn;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -51,6 +51,8 @@ namespace AlibabaCloud
|
||||
void setClusterId(const std::string& clusterId);
|
||||
long getOwnerId()const;
|
||||
void setOwnerId(long ownerId);
|
||||
std::vector<std::string> getInstanceId()const;
|
||||
void setInstanceId(const std::vector<std::string>& instanceId);
|
||||
std::string getZoneId()const;
|
||||
void setZoneId(const std::string& zoneId);
|
||||
|
||||
@@ -63,6 +65,7 @@ namespace AlibabaCloud
|
||||
std::string ownerAccount_;
|
||||
std::string clusterId_;
|
||||
long ownerId_;
|
||||
std::vector<std::string> instanceId_;
|
||||
std::string zoneId_;
|
||||
|
||||
};
|
||||
|
||||
@@ -76,6 +76,7 @@ namespace AlibabaCloud
|
||||
std::vector<NetworkInterfaceSet::Ipv6Set> ipv6Sets;
|
||||
int queueNumber;
|
||||
std::string vpcId;
|
||||
std::string ownerId;
|
||||
AssociatedPublicIp associatedPublicIp;
|
||||
std::string creationTime;
|
||||
std::vector<NetworkInterfaceSet::Tag> tags;
|
||||
|
||||
@@ -57,6 +57,7 @@ namespace AlibabaCloud
|
||||
std::string sourceDiskSize;
|
||||
std::string creationTime;
|
||||
std::string lastModifiedTime;
|
||||
std::string snapshotType;
|
||||
std::string sourceDiskType;
|
||||
int remainTime;
|
||||
std::vector<Snapshot::Tag> tags;
|
||||
|
||||
@@ -30,6 +30,12 @@ namespace AlibabaCloud
|
||||
{
|
||||
class ALIBABACLOUD_ECS_EXPORT ImportKeyPairRequest : public RpcServiceRequest
|
||||
{
|
||||
public:
|
||||
struct Tag
|
||||
{
|
||||
std::string value;
|
||||
std::string key;
|
||||
};
|
||||
|
||||
public:
|
||||
ImportKeyPairRequest();
|
||||
@@ -39,8 +45,12 @@ namespace AlibabaCloud
|
||||
void setResourceOwnerId(long resourceOwnerId);
|
||||
std::string getKeyPairName()const;
|
||||
void setKeyPairName(const std::string& keyPairName);
|
||||
std::string getResourceGroupId()const;
|
||||
void setResourceGroupId(const std::string& resourceGroupId);
|
||||
std::string getRegionId()const;
|
||||
void setRegionId(const std::string& regionId);
|
||||
std::vector<Tag> getTag()const;
|
||||
void setTag(const std::vector<Tag>& tag);
|
||||
std::string getResourceOwnerAccount()const;
|
||||
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
|
||||
std::string getPublicKeyBody()const;
|
||||
@@ -51,7 +61,9 @@ namespace AlibabaCloud
|
||||
private:
|
||||
long resourceOwnerId_;
|
||||
std::string keyPairName_;
|
||||
std::string resourceGroupId_;
|
||||
std::string regionId_;
|
||||
std::vector<Tag> tag_;
|
||||
std::string resourceOwnerAccount_;
|
||||
std::string publicKeyBody_;
|
||||
long ownerId_;
|
||||
|
||||
@@ -51,6 +51,8 @@ namespace AlibabaCloud
|
||||
void setOwnerAccount(const std::string& ownerAccount);
|
||||
long getOwnerId()const;
|
||||
void setOwnerId(long ownerId);
|
||||
std::string getStatus()const;
|
||||
void setStatus(const std::string& status);
|
||||
|
||||
private:
|
||||
long resourceOwnerId_;
|
||||
@@ -61,6 +63,7 @@ namespace AlibabaCloud
|
||||
std::string resourceOwnerAccount_;
|
||||
std::string ownerAccount_;
|
||||
long ownerId_;
|
||||
std::string status_;
|
||||
|
||||
};
|
||||
}
|
||||
|
||||
69
ecs/include/alibabacloud/ecs/model/RebootInstancesRequest.h
Normal file
69
ecs/include/alibabacloud/ecs/model/RebootInstancesRequest.h
Normal file
@@ -0,0 +1,69 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ECS_MODEL_REBOOTINSTANCESREQUEST_H_
|
||||
#define ALIBABACLOUD_ECS_MODEL_REBOOTINSTANCESREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/ecs/EcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ecs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ECS_EXPORT RebootInstancesRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
RebootInstancesRequest();
|
||||
~RebootInstancesRequest();
|
||||
|
||||
long getResourceOwnerId()const;
|
||||
void setResourceOwnerId(long resourceOwnerId);
|
||||
std::string getRegionId()const;
|
||||
void setRegionId(const std::string& regionId);
|
||||
bool getDryRun()const;
|
||||
void setDryRun(bool dryRun);
|
||||
std::string getResourceOwnerAccount()const;
|
||||
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
|
||||
std::string getOwnerAccount()const;
|
||||
void setOwnerAccount(const std::string& ownerAccount);
|
||||
long getOwnerId()const;
|
||||
void setOwnerId(long ownerId);
|
||||
bool getForceReboot()const;
|
||||
void setForceReboot(bool forceReboot);
|
||||
std::vector<std::string> getInstanceId()const;
|
||||
void setInstanceId(const std::vector<std::string>& instanceId);
|
||||
|
||||
private:
|
||||
long resourceOwnerId_;
|
||||
std::string regionId_;
|
||||
bool dryRun_;
|
||||
std::string resourceOwnerAccount_;
|
||||
std::string ownerAccount_;
|
||||
long ownerId_;
|
||||
bool forceReboot_;
|
||||
std::vector<std::string> instanceId_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ECS_MODEL_REBOOTINSTANCESREQUEST_H_
|
||||
49
ecs/include/alibabacloud/ecs/model/RebootInstancesResult.h
Normal file
49
ecs/include/alibabacloud/ecs/model/RebootInstancesResult.h
Normal file
@@ -0,0 +1,49 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ECS_MODEL_REBOOTINSTANCESRESULT_H_
|
||||
#define ALIBABACLOUD_ECS_MODEL_REBOOTINSTANCESRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ecs/EcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ecs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ECS_EXPORT RebootInstancesResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
RebootInstancesResult();
|
||||
explicit RebootInstancesResult(const std::string &payload);
|
||||
~RebootInstancesResult();
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ECS_MODEL_REBOOTINSTANCESRESULT_H_
|
||||
@@ -58,6 +58,7 @@ namespace AlibabaCloud
|
||||
bool deleteWithInstance;
|
||||
std::string performanceLevel;
|
||||
std::string autoSnapshotPolicyId;
|
||||
std::string encryptAlgorithm;
|
||||
};
|
||||
|
||||
public:
|
||||
@@ -202,6 +203,8 @@ namespace AlibabaCloud
|
||||
void setStorageSetId(const std::string& storageSetId);
|
||||
std::string getSystemDiskSize()const;
|
||||
void setSystemDiskSize(const std::string& systemDiskSize);
|
||||
std::string getImageFamily()const;
|
||||
void setImageFamily(const std::string& imageFamily);
|
||||
std::string getSystemDiskDescription()const;
|
||||
void setSystemDiskDescription(const std::string& systemDiskDescription);
|
||||
|
||||
@@ -275,6 +278,7 @@ namespace AlibabaCloud
|
||||
long launchTemplateVersion_;
|
||||
std::string storageSetId_;
|
||||
std::string systemDiskSize_;
|
||||
std::string imageFamily_;
|
||||
std::string systemDiskDescription_;
|
||||
|
||||
};
|
||||
|
||||
66
ecs/include/alibabacloud/ecs/model/StartInstancesRequest.h
Normal file
66
ecs/include/alibabacloud/ecs/model/StartInstancesRequest.h
Normal file
@@ -0,0 +1,66 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ECS_MODEL_STARTINSTANCESREQUEST_H_
|
||||
#define ALIBABACLOUD_ECS_MODEL_STARTINSTANCESREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/ecs/EcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ecs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ECS_EXPORT StartInstancesRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
StartInstancesRequest();
|
||||
~StartInstancesRequest();
|
||||
|
||||
long getResourceOwnerId()const;
|
||||
void setResourceOwnerId(long resourceOwnerId);
|
||||
std::string getRegionId()const;
|
||||
void setRegionId(const std::string& regionId);
|
||||
bool getDryRun()const;
|
||||
void setDryRun(bool dryRun);
|
||||
std::string getResourceOwnerAccount()const;
|
||||
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
|
||||
std::string getOwnerAccount()const;
|
||||
void setOwnerAccount(const std::string& ownerAccount);
|
||||
long getOwnerId()const;
|
||||
void setOwnerId(long ownerId);
|
||||
std::vector<std::string> getInstanceId()const;
|
||||
void setInstanceId(const std::vector<std::string>& instanceId);
|
||||
|
||||
private:
|
||||
long resourceOwnerId_;
|
||||
std::string regionId_;
|
||||
bool dryRun_;
|
||||
std::string resourceOwnerAccount_;
|
||||
std::string ownerAccount_;
|
||||
long ownerId_;
|
||||
std::vector<std::string> instanceId_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ECS_MODEL_STARTINSTANCESREQUEST_H_
|
||||
49
ecs/include/alibabacloud/ecs/model/StartInstancesResult.h
Normal file
49
ecs/include/alibabacloud/ecs/model/StartInstancesResult.h
Normal file
@@ -0,0 +1,49 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ECS_MODEL_STARTINSTANCESRESULT_H_
|
||||
#define ALIBABACLOUD_ECS_MODEL_STARTINSTANCESRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ecs/EcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ecs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ECS_EXPORT StartInstancesResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
StartInstancesResult();
|
||||
explicit StartInstancesResult(const std::string &payload);
|
||||
~StartInstancesResult();
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ECS_MODEL_STARTINSTANCESRESULT_H_
|
||||
72
ecs/include/alibabacloud/ecs/model/StopInstancesRequest.h
Normal file
72
ecs/include/alibabacloud/ecs/model/StopInstancesRequest.h
Normal file
@@ -0,0 +1,72 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ECS_MODEL_STOPINSTANCESREQUEST_H_
|
||||
#define ALIBABACLOUD_ECS_MODEL_STOPINSTANCESREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/ecs/EcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ecs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ECS_EXPORT StopInstancesRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
StopInstancesRequest();
|
||||
~StopInstancesRequest();
|
||||
|
||||
long getResourceOwnerId()const;
|
||||
void setResourceOwnerId(long resourceOwnerId);
|
||||
std::string getStoppedMode()const;
|
||||
void setStoppedMode(const std::string& stoppedMode);
|
||||
bool getForceStop()const;
|
||||
void setForceStop(bool forceStop);
|
||||
std::string getRegionId()const;
|
||||
void setRegionId(const std::string& regionId);
|
||||
bool getDryRun()const;
|
||||
void setDryRun(bool dryRun);
|
||||
std::string getResourceOwnerAccount()const;
|
||||
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
|
||||
std::string getOwnerAccount()const;
|
||||
void setOwnerAccount(const std::string& ownerAccount);
|
||||
long getOwnerId()const;
|
||||
void setOwnerId(long ownerId);
|
||||
std::vector<std::string> getInstanceId()const;
|
||||
void setInstanceId(const std::vector<std::string>& instanceId);
|
||||
|
||||
private:
|
||||
long resourceOwnerId_;
|
||||
std::string stoppedMode_;
|
||||
bool forceStop_;
|
||||
std::string regionId_;
|
||||
bool dryRun_;
|
||||
std::string resourceOwnerAccount_;
|
||||
std::string ownerAccount_;
|
||||
long ownerId_;
|
||||
std::vector<std::string> instanceId_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ECS_MODEL_STOPINSTANCESREQUEST_H_
|
||||
49
ecs/include/alibabacloud/ecs/model/StopInstancesResult.h
Normal file
49
ecs/include/alibabacloud/ecs/model/StopInstancesResult.h
Normal file
@@ -0,0 +1,49 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ECS_MODEL_STOPINSTANCESRESULT_H_
|
||||
#define ALIBABACLOUD_ECS_MODEL_STOPINSTANCESRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ecs/EcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ecs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ECS_EXPORT StopInstancesResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
StopInstancesResult();
|
||||
explicit StopInstancesResult(const std::string &payload);
|
||||
~StopInstancesResult();
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ECS_MODEL_STOPINSTANCESRESULT_H_
|
||||
@@ -4011,6 +4011,42 @@ EcsClient::DescribeHpcClustersOutcomeCallable EcsClient::describeHpcClustersCall
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::DescribeImageFromFamilyOutcome EcsClient::describeImageFromFamily(const DescribeImageFromFamilyRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeImageFromFamilyOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeImageFromFamilyOutcome(DescribeImageFromFamilyResult(outcome.result()));
|
||||
else
|
||||
return DescribeImageFromFamilyOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EcsClient::describeImageFromFamilyAsync(const DescribeImageFromFamilyRequest& request, const DescribeImageFromFamilyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeImageFromFamily(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EcsClient::DescribeImageFromFamilyOutcomeCallable EcsClient::describeImageFromFamilyCallable(const DescribeImageFromFamilyRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeImageFromFamilyOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeImageFromFamily(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::DescribeImageSharePermissionOutcome EcsClient::describeImageSharePermission(const DescribeImageSharePermissionRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -8835,6 +8871,42 @@ EcsClient::RebootInstanceOutcomeCallable EcsClient::rebootInstanceCallable(const
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::RebootInstancesOutcome EcsClient::rebootInstances(const RebootInstancesRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return RebootInstancesOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return RebootInstancesOutcome(RebootInstancesResult(outcome.result()));
|
||||
else
|
||||
return RebootInstancesOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EcsClient::rebootInstancesAsync(const RebootInstancesRequest& request, const RebootInstancesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, rebootInstances(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EcsClient::RebootInstancesOutcomeCallable EcsClient::rebootInstancesCallable(const RebootInstancesRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<RebootInstancesOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->rebootInstances(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::RecoverVirtualBorderRouterOutcome EcsClient::recoverVirtualBorderRouter(const RecoverVirtualBorderRouterRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -9519,6 +9591,42 @@ EcsClient::StartInstanceOutcomeCallable EcsClient::startInstanceCallable(const S
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::StartInstancesOutcome EcsClient::startInstances(const StartInstancesRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return StartInstancesOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return StartInstancesOutcome(StartInstancesResult(outcome.result()));
|
||||
else
|
||||
return StartInstancesOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EcsClient::startInstancesAsync(const StartInstancesRequest& request, const StartInstancesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, startInstances(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EcsClient::StartInstancesOutcomeCallable EcsClient::startInstancesCallable(const StartInstancesRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<StartInstancesOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->startInstances(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::StopInstanceOutcome EcsClient::stopInstance(const StopInstanceRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -9555,6 +9663,42 @@ EcsClient::StopInstanceOutcomeCallable EcsClient::stopInstanceCallable(const Sto
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::StopInstancesOutcome EcsClient::stopInstances(const StopInstancesRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return StopInstancesOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return StopInstancesOutcome(StopInstancesResult(outcome.result()));
|
||||
else
|
||||
return StopInstancesOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EcsClient::stopInstancesAsync(const StopInstancesRequest& request, const StopInstancesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, stopInstances(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EcsClient::StopInstancesOutcomeCallable EcsClient::stopInstancesCallable(const StopInstancesRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<StopInstancesOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->stopInstances(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::StopInvocationOutcome EcsClient::stopInvocation(const StopInvocationRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
|
||||
@@ -49,6 +49,17 @@ void CopyImageRequest::setImageId(const std::string& imageId)
|
||||
setParameter("ImageId", imageId);
|
||||
}
|
||||
|
||||
std::string CopyImageRequest::getEncryptAlgorithm()const
|
||||
{
|
||||
return encryptAlgorithm_;
|
||||
}
|
||||
|
||||
void CopyImageRequest::setEncryptAlgorithm(const std::string& encryptAlgorithm)
|
||||
{
|
||||
encryptAlgorithm_ = encryptAlgorithm;
|
||||
setParameter("EncryptAlgorithm", encryptAlgorithm);
|
||||
}
|
||||
|
||||
std::string CopyImageRequest::getDestinationRegionId()const
|
||||
{
|
||||
return destinationRegionId_;
|
||||
|
||||
@@ -60,6 +60,17 @@ void CreateDiskRequest::setClientToken(const std::string& clientToken)
|
||||
setParameter("ClientToken", clientToken);
|
||||
}
|
||||
|
||||
std::string CreateDiskRequest::getEncryptAlgorithm()const
|
||||
{
|
||||
return encryptAlgorithm_;
|
||||
}
|
||||
|
||||
void CreateDiskRequest::setEncryptAlgorithm(const std::string& encryptAlgorithm)
|
||||
{
|
||||
encryptAlgorithm_ = encryptAlgorithm;
|
||||
setParameter("EncryptAlgorithm", encryptAlgorithm);
|
||||
}
|
||||
|
||||
std::string CreateDiskRequest::getDescription()const
|
||||
{
|
||||
return description_;
|
||||
|
||||
@@ -204,6 +204,17 @@ void CreateImageRequest::setInstanceId(const std::string& instanceId)
|
||||
setParameter("InstanceId", instanceId);
|
||||
}
|
||||
|
||||
std::string CreateImageRequest::getImageFamily()const
|
||||
{
|
||||
return imageFamily_;
|
||||
}
|
||||
|
||||
void CreateImageRequest::setImageFamily(const std::string& imageFamily)
|
||||
{
|
||||
imageFamily_ = imageFamily;
|
||||
setParameter("ImageFamily", imageFamily);
|
||||
}
|
||||
|
||||
std::string CreateImageRequest::getImageVersion()const
|
||||
{
|
||||
return imageVersion_;
|
||||
|
||||
@@ -670,6 +670,7 @@ void CreateInstanceRequest::setDataDisk(const std::vector<DataDisk>& dataDisk)
|
||||
setParameter(dataDiskObjStr + ".Size", std::to_string(dataDiskObj.size));
|
||||
setParameter(dataDiskObjStr + ".Encrypted", dataDiskObj.encrypted ? "true" : "false");
|
||||
setParameter(dataDiskObjStr + ".PerformanceLevel", dataDiskObj.performanceLevel);
|
||||
setParameter(dataDiskObjStr + ".EncryptAlgorithm", dataDiskObj.encryptAlgorithm);
|
||||
setParameter(dataDiskObjStr + ".Description", dataDiskObj.description);
|
||||
setParameter(dataDiskObjStr + ".Category", dataDiskObj.category);
|
||||
setParameter(dataDiskObjStr + ".KMSKeyId", dataDiskObj.kMSKeyId);
|
||||
@@ -700,6 +701,17 @@ void CreateInstanceRequest::setSystemDiskSize(int systemDiskSize)
|
||||
setParameter("SystemDiskSize", std::to_string(systemDiskSize));
|
||||
}
|
||||
|
||||
std::string CreateInstanceRequest::getImageFamily()const
|
||||
{
|
||||
return imageFamily_;
|
||||
}
|
||||
|
||||
void CreateInstanceRequest::setImageFamily(const std::string& imageFamily)
|
||||
{
|
||||
imageFamily_ = imageFamily;
|
||||
setParameter("ImageFamily", imageFamily);
|
||||
}
|
||||
|
||||
std::string CreateInstanceRequest::getSystemDiskDescription()const
|
||||
{
|
||||
return systemDiskDescription_;
|
||||
|
||||
@@ -61,6 +61,8 @@ void DescribeAccountAttributesResult::parse(const std::string &payload)
|
||||
attributeValuesObject.instanceType = allAccountAttributeItemsNodeAttributeValuesValueItem["InstanceType"].asString();
|
||||
if(!allAccountAttributeItemsNodeAttributeValuesValueItem["Count"].isNull())
|
||||
attributeValuesObject.count = std::stoi(allAccountAttributeItemsNodeAttributeValuesValueItem["Count"].asString());
|
||||
if(!allAccountAttributeItemsNodeAttributeValuesValueItem["DiskCategory"].isNull())
|
||||
attributeValuesObject.diskCategory = allAccountAttributeItemsNodeAttributeValuesValueItem["DiskCategory"].asString();
|
||||
accountAttributeItemsObject.attributeValues.push_back(attributeValuesObject);
|
||||
}
|
||||
accountAttributeItems_.push_back(accountAttributeItemsObject);
|
||||
|
||||
95
ecs/src/model/DescribeImageFromFamilyRequest.cc
Normal file
95
ecs/src/model/DescribeImageFromFamilyRequest.cc
Normal file
@@ -0,0 +1,95 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ecs/model/DescribeImageFromFamilyRequest.h>
|
||||
|
||||
using AlibabaCloud::Ecs::Model::DescribeImageFromFamilyRequest;
|
||||
|
||||
DescribeImageFromFamilyRequest::DescribeImageFromFamilyRequest() :
|
||||
RpcServiceRequest("ecs", "2014-05-26", "DescribeImageFromFamily")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DescribeImageFromFamilyRequest::~DescribeImageFromFamilyRequest()
|
||||
{}
|
||||
|
||||
long DescribeImageFromFamilyRequest::getResourceOwnerId()const
|
||||
{
|
||||
return resourceOwnerId_;
|
||||
}
|
||||
|
||||
void DescribeImageFromFamilyRequest::setResourceOwnerId(long resourceOwnerId)
|
||||
{
|
||||
resourceOwnerId_ = resourceOwnerId;
|
||||
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
|
||||
}
|
||||
|
||||
std::string DescribeImageFromFamilyRequest::getRegionId()const
|
||||
{
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void DescribeImageFromFamilyRequest::setRegionId(const std::string& regionId)
|
||||
{
|
||||
regionId_ = regionId;
|
||||
setParameter("RegionId", regionId);
|
||||
}
|
||||
|
||||
std::string DescribeImageFromFamilyRequest::getResourceOwnerAccount()const
|
||||
{
|
||||
return resourceOwnerAccount_;
|
||||
}
|
||||
|
||||
void DescribeImageFromFamilyRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
|
||||
{
|
||||
resourceOwnerAccount_ = resourceOwnerAccount;
|
||||
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
|
||||
}
|
||||
|
||||
std::string DescribeImageFromFamilyRequest::getOwnerAccount()const
|
||||
{
|
||||
return ownerAccount_;
|
||||
}
|
||||
|
||||
void DescribeImageFromFamilyRequest::setOwnerAccount(const std::string& ownerAccount)
|
||||
{
|
||||
ownerAccount_ = ownerAccount;
|
||||
setParameter("OwnerAccount", ownerAccount);
|
||||
}
|
||||
|
||||
long DescribeImageFromFamilyRequest::getOwnerId()const
|
||||
{
|
||||
return ownerId_;
|
||||
}
|
||||
|
||||
void DescribeImageFromFamilyRequest::setOwnerId(long ownerId)
|
||||
{
|
||||
ownerId_ = ownerId;
|
||||
setParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::string DescribeImageFromFamilyRequest::getImageFamily()const
|
||||
{
|
||||
return imageFamily_;
|
||||
}
|
||||
|
||||
void DescribeImageFromFamilyRequest::setImageFamily(const std::string& imageFamily)
|
||||
{
|
||||
imageFamily_ = imageFamily;
|
||||
setParameter("ImageFamily", imageFamily);
|
||||
}
|
||||
|
||||
122
ecs/src/model/DescribeImageFromFamilyResult.cc
Normal file
122
ecs/src/model/DescribeImageFromFamilyResult.cc
Normal file
@@ -0,0 +1,122 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ecs/model/DescribeImageFromFamilyResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ecs;
|
||||
using namespace AlibabaCloud::Ecs::Model;
|
||||
|
||||
DescribeImageFromFamilyResult::DescribeImageFromFamilyResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DescribeImageFromFamilyResult::DescribeImageFromFamilyResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DescribeImageFromFamilyResult::~DescribeImageFromFamilyResult()
|
||||
{}
|
||||
|
||||
void DescribeImageFromFamilyResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto imageNode = value["Image"];
|
||||
if(!imageNode["Progress"].isNull())
|
||||
image_.progress = imageNode["Progress"].asString();
|
||||
if(!imageNode["ImageId"].isNull())
|
||||
image_.imageId = imageNode["ImageId"].asString();
|
||||
if(!imageNode["ImageName"].isNull())
|
||||
image_.imageName = imageNode["ImageName"].asString();
|
||||
if(!imageNode["ImageFamily"].isNull())
|
||||
image_.imageFamily = imageNode["ImageFamily"].asString();
|
||||
if(!imageNode["ImageVersion"].isNull())
|
||||
image_.imageVersion = imageNode["ImageVersion"].asString();
|
||||
if(!imageNode["Description"].isNull())
|
||||
image_.description = imageNode["Description"].asString();
|
||||
if(!imageNode["Size"].isNull())
|
||||
image_.size = std::stoi(imageNode["Size"].asString());
|
||||
if(!imageNode["ImageOwnerAlias"].isNull())
|
||||
image_.imageOwnerAlias = imageNode["ImageOwnerAlias"].asString();
|
||||
if(!imageNode["IsSupportIoOptimized"].isNull())
|
||||
image_.isSupportIoOptimized = imageNode["IsSupportIoOptimized"].asString() == "true";
|
||||
if(!imageNode["IsSupportCloudinit"].isNull())
|
||||
image_.isSupportCloudinit = imageNode["IsSupportCloudinit"].asString() == "true";
|
||||
if(!imageNode["OSName"].isNull())
|
||||
image_.oSName = imageNode["OSName"].asString();
|
||||
if(!imageNode["Architecture"].isNull())
|
||||
image_.architecture = imageNode["Architecture"].asString();
|
||||
if(!imageNode["Status"].isNull())
|
||||
image_.status = imageNode["Status"].asString();
|
||||
if(!imageNode["ProductCode"].isNull())
|
||||
image_.productCode = imageNode["ProductCode"].asString();
|
||||
if(!imageNode["IsSubscribed"].isNull())
|
||||
image_.isSubscribed = imageNode["IsSubscribed"].asString() == "true";
|
||||
if(!imageNode["CreationTime"].isNull())
|
||||
image_.creationTime = imageNode["CreationTime"].asString();
|
||||
if(!imageNode["IsSelfShared"].isNull())
|
||||
image_.isSelfShared = imageNode["IsSelfShared"].asString();
|
||||
if(!imageNode["OSType"].isNull())
|
||||
image_.oSType = imageNode["OSType"].asString();
|
||||
if(!imageNode["Platform"].isNull())
|
||||
image_.platform = imageNode["Platform"].asString();
|
||||
if(!imageNode["Usage"].isNull())
|
||||
image_.usage = imageNode["Usage"].asString();
|
||||
if(!imageNode["IsCopied"].isNull())
|
||||
image_.isCopied = imageNode["IsCopied"].asString() == "true";
|
||||
auto allDiskDeviceMappingsNode = imageNode["DiskDeviceMappings"]["DiskDeviceMapping"];
|
||||
for (auto imageNodeDiskDeviceMappingsDiskDeviceMapping : allDiskDeviceMappingsNode)
|
||||
{
|
||||
Image::DiskDeviceMapping diskDeviceMappingObject;
|
||||
if(!imageNodeDiskDeviceMappingsDiskDeviceMapping["SnapshotId"].isNull())
|
||||
diskDeviceMappingObject.snapshotId = imageNodeDiskDeviceMappingsDiskDeviceMapping["SnapshotId"].asString();
|
||||
if(!imageNodeDiskDeviceMappingsDiskDeviceMapping["Size"].isNull())
|
||||
diskDeviceMappingObject.size = imageNodeDiskDeviceMappingsDiskDeviceMapping["Size"].asString();
|
||||
if(!imageNodeDiskDeviceMappingsDiskDeviceMapping["Device"].isNull())
|
||||
diskDeviceMappingObject.device = imageNodeDiskDeviceMappingsDiskDeviceMapping["Device"].asString();
|
||||
if(!imageNodeDiskDeviceMappingsDiskDeviceMapping["Type"].isNull())
|
||||
diskDeviceMappingObject.type = imageNodeDiskDeviceMappingsDiskDeviceMapping["Type"].asString();
|
||||
if(!imageNodeDiskDeviceMappingsDiskDeviceMapping["Format"].isNull())
|
||||
diskDeviceMappingObject.format = imageNodeDiskDeviceMappingsDiskDeviceMapping["Format"].asString();
|
||||
if(!imageNodeDiskDeviceMappingsDiskDeviceMapping["ImportOSSBucket"].isNull())
|
||||
diskDeviceMappingObject.importOSSBucket = imageNodeDiskDeviceMappingsDiskDeviceMapping["ImportOSSBucket"].asString();
|
||||
if(!imageNodeDiskDeviceMappingsDiskDeviceMapping["ImportOSSObject"].isNull())
|
||||
diskDeviceMappingObject.importOSSObject = imageNodeDiskDeviceMappingsDiskDeviceMapping["ImportOSSObject"].asString();
|
||||
image_.diskDeviceMappings.push_back(diskDeviceMappingObject);
|
||||
}
|
||||
auto allTagsNode = imageNode["Tags"]["Tag"];
|
||||
for (auto imageNodeTagsTag : allTagsNode)
|
||||
{
|
||||
Image::Tag tagObject;
|
||||
if(!imageNodeTagsTag["TagKey"].isNull())
|
||||
tagObject.tagKey = imageNodeTagsTag["TagKey"].asString();
|
||||
if(!imageNodeTagsTag["TagValue"].isNull())
|
||||
tagObject.tagValue = imageNodeTagsTag["TagValue"].asString();
|
||||
image_.tags.push_back(tagObject);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
DescribeImageFromFamilyResult::Image DescribeImageFromFamilyResult::getImage()const
|
||||
{
|
||||
return image_;
|
||||
}
|
||||
|
||||
@@ -290,6 +290,17 @@ void DescribeImagesRequest::setFilter(const std::vector<Filter>& filter)
|
||||
}
|
||||
}
|
||||
|
||||
std::string DescribeImagesRequest::getImageFamily()const
|
||||
{
|
||||
return imageFamily_;
|
||||
}
|
||||
|
||||
void DescribeImagesRequest::setImageFamily(const std::string& imageFamily)
|
||||
{
|
||||
imageFamily_ = imageFamily;
|
||||
setParameter("ImageFamily", imageFamily);
|
||||
}
|
||||
|
||||
std::string DescribeImagesRequest::getStatus()const
|
||||
{
|
||||
return status_;
|
||||
|
||||
@@ -49,6 +49,8 @@ void DescribeImagesResult::parse(const std::string &payload)
|
||||
imagesObject.imageId = valueImagesImage["ImageId"].asString();
|
||||
if(!valueImagesImage["ImageName"].isNull())
|
||||
imagesObject.imageName = valueImagesImage["ImageName"].asString();
|
||||
if(!valueImagesImage["ImageFamily"].isNull())
|
||||
imagesObject.imageFamily = valueImagesImage["ImageFamily"].asString();
|
||||
if(!valueImagesImage["ImageVersion"].isNull())
|
||||
imagesObject.imageVersion = valueImagesImage["ImageVersion"].asString();
|
||||
if(!valueImagesImage["Description"].isNull())
|
||||
|
||||
@@ -115,6 +115,19 @@ void DescribeInstanceStatusRequest::setOwnerId(long ownerId)
|
||||
setParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::vector<std::string> DescribeInstanceStatusRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void DescribeInstanceStatusRequest::setInstanceId(const std::vector<std::string>& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
for(int dep1 = 0; dep1!= instanceId.size(); dep1++) {
|
||||
setParameter("InstanceId."+ std::to_string(dep1), instanceId.at(dep1));
|
||||
}
|
||||
}
|
||||
|
||||
std::string DescribeInstanceStatusRequest::getZoneId()const
|
||||
{
|
||||
return zoneId_;
|
||||
|
||||
@@ -75,6 +75,8 @@ void DescribeNetworkInterfacesResult::parse(const std::string &payload)
|
||||
networkInterfaceSetsObject.serviceManaged = valueNetworkInterfaceSetsNetworkInterfaceSet["ServiceManaged"].asString() == "true";
|
||||
if(!valueNetworkInterfaceSetsNetworkInterfaceSet["QueueNumber"].isNull())
|
||||
networkInterfaceSetsObject.queueNumber = std::stoi(valueNetworkInterfaceSetsNetworkInterfaceSet["QueueNumber"].asString());
|
||||
if(!valueNetworkInterfaceSetsNetworkInterfaceSet["OwnerId"].isNull())
|
||||
networkInterfaceSetsObject.ownerId = valueNetworkInterfaceSetsNetworkInterfaceSet["OwnerId"].asString();
|
||||
auto allPrivateIpSetsNode = allNetworkInterfaceSetsNode["PrivateIpSets"]["PrivateIpSet"];
|
||||
for (auto allNetworkInterfaceSetsNodePrivateIpSetsPrivateIpSet : allPrivateIpSetsNode)
|
||||
{
|
||||
|
||||
@@ -83,6 +83,8 @@ void DescribeSnapshotsResult::parse(const std::string &payload)
|
||||
snapshotsObject.kMSKeyId = valueSnapshotsSnapshot["KMSKeyId"].asString();
|
||||
if(!valueSnapshotsSnapshot["Category"].isNull())
|
||||
snapshotsObject.category = valueSnapshotsSnapshot["Category"].asString();
|
||||
if(!valueSnapshotsSnapshot["SnapshotType"].isNull())
|
||||
snapshotsObject.snapshotType = valueSnapshotsSnapshot["SnapshotType"].asString();
|
||||
auto allTagsNode = allSnapshotsNode["Tags"]["Tag"];
|
||||
for (auto allSnapshotsNodeTagsTag : allTagsNode)
|
||||
{
|
||||
|
||||
@@ -49,6 +49,17 @@ void ImportKeyPairRequest::setKeyPairName(const std::string& keyPairName)
|
||||
setParameter("KeyPairName", keyPairName);
|
||||
}
|
||||
|
||||
std::string ImportKeyPairRequest::getResourceGroupId()const
|
||||
{
|
||||
return resourceGroupId_;
|
||||
}
|
||||
|
||||
void ImportKeyPairRequest::setResourceGroupId(const std::string& resourceGroupId)
|
||||
{
|
||||
resourceGroupId_ = resourceGroupId;
|
||||
setParameter("ResourceGroupId", resourceGroupId);
|
||||
}
|
||||
|
||||
std::string ImportKeyPairRequest::getRegionId()const
|
||||
{
|
||||
return regionId_;
|
||||
@@ -60,6 +71,22 @@ void ImportKeyPairRequest::setRegionId(const std::string& regionId)
|
||||
setParameter("RegionId", regionId);
|
||||
}
|
||||
|
||||
std::vector<ImportKeyPairRequest::Tag> ImportKeyPairRequest::getTag()const
|
||||
{
|
||||
return tag_;
|
||||
}
|
||||
|
||||
void ImportKeyPairRequest::setTag(const std::vector<Tag>& tag)
|
||||
{
|
||||
tag_ = tag;
|
||||
for(int dep1 = 0; dep1!= tag.size(); dep1++) {
|
||||
auto tagObj = tag.at(dep1);
|
||||
std::string tagObjStr = "Tag." + std::to_string(dep1 + 1);
|
||||
setParameter(tagObjStr + ".Value", tagObj.value);
|
||||
setParameter(tagObjStr + ".Key", tagObj.key);
|
||||
}
|
||||
}
|
||||
|
||||
std::string ImportKeyPairRequest::getResourceOwnerAccount()const
|
||||
{
|
||||
return resourceOwnerAccount_;
|
||||
|
||||
@@ -115,3 +115,14 @@ void ModifyImageAttributeRequest::setOwnerId(long ownerId)
|
||||
setParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::string ModifyImageAttributeRequest::getStatus()const
|
||||
{
|
||||
return status_;
|
||||
}
|
||||
|
||||
void ModifyImageAttributeRequest::setStatus(const std::string& status)
|
||||
{
|
||||
status_ = status;
|
||||
setParameter("Status", status);
|
||||
}
|
||||
|
||||
|
||||
119
ecs/src/model/RebootInstancesRequest.cc
Normal file
119
ecs/src/model/RebootInstancesRequest.cc
Normal file
@@ -0,0 +1,119 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ecs/model/RebootInstancesRequest.h>
|
||||
|
||||
using AlibabaCloud::Ecs::Model::RebootInstancesRequest;
|
||||
|
||||
RebootInstancesRequest::RebootInstancesRequest() :
|
||||
RpcServiceRequest("ecs", "2014-05-26", "RebootInstances")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
RebootInstancesRequest::~RebootInstancesRequest()
|
||||
{}
|
||||
|
||||
long RebootInstancesRequest::getResourceOwnerId()const
|
||||
{
|
||||
return resourceOwnerId_;
|
||||
}
|
||||
|
||||
void RebootInstancesRequest::setResourceOwnerId(long resourceOwnerId)
|
||||
{
|
||||
resourceOwnerId_ = resourceOwnerId;
|
||||
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
|
||||
}
|
||||
|
||||
std::string RebootInstancesRequest::getRegionId()const
|
||||
{
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void RebootInstancesRequest::setRegionId(const std::string& regionId)
|
||||
{
|
||||
regionId_ = regionId;
|
||||
setParameter("RegionId", regionId);
|
||||
}
|
||||
|
||||
bool RebootInstancesRequest::getDryRun()const
|
||||
{
|
||||
return dryRun_;
|
||||
}
|
||||
|
||||
void RebootInstancesRequest::setDryRun(bool dryRun)
|
||||
{
|
||||
dryRun_ = dryRun;
|
||||
setParameter("DryRun", dryRun ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string RebootInstancesRequest::getResourceOwnerAccount()const
|
||||
{
|
||||
return resourceOwnerAccount_;
|
||||
}
|
||||
|
||||
void RebootInstancesRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
|
||||
{
|
||||
resourceOwnerAccount_ = resourceOwnerAccount;
|
||||
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
|
||||
}
|
||||
|
||||
std::string RebootInstancesRequest::getOwnerAccount()const
|
||||
{
|
||||
return ownerAccount_;
|
||||
}
|
||||
|
||||
void RebootInstancesRequest::setOwnerAccount(const std::string& ownerAccount)
|
||||
{
|
||||
ownerAccount_ = ownerAccount;
|
||||
setParameter("OwnerAccount", ownerAccount);
|
||||
}
|
||||
|
||||
long RebootInstancesRequest::getOwnerId()const
|
||||
{
|
||||
return ownerId_;
|
||||
}
|
||||
|
||||
void RebootInstancesRequest::setOwnerId(long ownerId)
|
||||
{
|
||||
ownerId_ = ownerId;
|
||||
setParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
bool RebootInstancesRequest::getForceReboot()const
|
||||
{
|
||||
return forceReboot_;
|
||||
}
|
||||
|
||||
void RebootInstancesRequest::setForceReboot(bool forceReboot)
|
||||
{
|
||||
forceReboot_ = forceReboot;
|
||||
setParameter("ForceReboot", forceReboot ? "true" : "false");
|
||||
}
|
||||
|
||||
std::vector<std::string> RebootInstancesRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void RebootInstancesRequest::setInstanceId(const std::vector<std::string>& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
for(int dep1 = 0; dep1!= instanceId.size(); dep1++) {
|
||||
setParameter("InstanceId."+ std::to_string(dep1), instanceId.at(dep1));
|
||||
}
|
||||
}
|
||||
|
||||
44
ecs/src/model/RebootInstancesResult.cc
Normal file
44
ecs/src/model/RebootInstancesResult.cc
Normal file
@@ -0,0 +1,44 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ecs/model/RebootInstancesResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ecs;
|
||||
using namespace AlibabaCloud::Ecs::Model;
|
||||
|
||||
RebootInstancesResult::RebootInstancesResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
RebootInstancesResult::RebootInstancesResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
RebootInstancesResult::~RebootInstancesResult()
|
||||
{}
|
||||
|
||||
void RebootInstancesResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
@@ -784,6 +784,7 @@ void RunInstancesRequest::setDataDisk(const std::vector<DataDisk>& dataDisk)
|
||||
setParameter(dataDiskObjStr + ".DeleteWithInstance", dataDiskObj.deleteWithInstance ? "true" : "false");
|
||||
setParameter(dataDiskObjStr + ".PerformanceLevel", dataDiskObj.performanceLevel);
|
||||
setParameter(dataDiskObjStr + ".AutoSnapshotPolicyId", dataDiskObj.autoSnapshotPolicyId);
|
||||
setParameter(dataDiskObjStr + ".EncryptAlgorithm", dataDiskObj.encryptAlgorithm);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -820,6 +821,17 @@ void RunInstancesRequest::setSystemDiskSize(const std::string& systemDiskSize)
|
||||
setParameter("SystemDiskSize", systemDiskSize);
|
||||
}
|
||||
|
||||
std::string RunInstancesRequest::getImageFamily()const
|
||||
{
|
||||
return imageFamily_;
|
||||
}
|
||||
|
||||
void RunInstancesRequest::setImageFamily(const std::string& imageFamily)
|
||||
{
|
||||
imageFamily_ = imageFamily;
|
||||
setParameter("ImageFamily", imageFamily);
|
||||
}
|
||||
|
||||
std::string RunInstancesRequest::getSystemDiskDescription()const
|
||||
{
|
||||
return systemDiskDescription_;
|
||||
|
||||
108
ecs/src/model/StartInstancesRequest.cc
Normal file
108
ecs/src/model/StartInstancesRequest.cc
Normal file
@@ -0,0 +1,108 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ecs/model/StartInstancesRequest.h>
|
||||
|
||||
using AlibabaCloud::Ecs::Model::StartInstancesRequest;
|
||||
|
||||
StartInstancesRequest::StartInstancesRequest() :
|
||||
RpcServiceRequest("ecs", "2014-05-26", "StartInstances")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
StartInstancesRequest::~StartInstancesRequest()
|
||||
{}
|
||||
|
||||
long StartInstancesRequest::getResourceOwnerId()const
|
||||
{
|
||||
return resourceOwnerId_;
|
||||
}
|
||||
|
||||
void StartInstancesRequest::setResourceOwnerId(long resourceOwnerId)
|
||||
{
|
||||
resourceOwnerId_ = resourceOwnerId;
|
||||
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
|
||||
}
|
||||
|
||||
std::string StartInstancesRequest::getRegionId()const
|
||||
{
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void StartInstancesRequest::setRegionId(const std::string& regionId)
|
||||
{
|
||||
regionId_ = regionId;
|
||||
setParameter("RegionId", regionId);
|
||||
}
|
||||
|
||||
bool StartInstancesRequest::getDryRun()const
|
||||
{
|
||||
return dryRun_;
|
||||
}
|
||||
|
||||
void StartInstancesRequest::setDryRun(bool dryRun)
|
||||
{
|
||||
dryRun_ = dryRun;
|
||||
setParameter("DryRun", dryRun ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string StartInstancesRequest::getResourceOwnerAccount()const
|
||||
{
|
||||
return resourceOwnerAccount_;
|
||||
}
|
||||
|
||||
void StartInstancesRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
|
||||
{
|
||||
resourceOwnerAccount_ = resourceOwnerAccount;
|
||||
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
|
||||
}
|
||||
|
||||
std::string StartInstancesRequest::getOwnerAccount()const
|
||||
{
|
||||
return ownerAccount_;
|
||||
}
|
||||
|
||||
void StartInstancesRequest::setOwnerAccount(const std::string& ownerAccount)
|
||||
{
|
||||
ownerAccount_ = ownerAccount;
|
||||
setParameter("OwnerAccount", ownerAccount);
|
||||
}
|
||||
|
||||
long StartInstancesRequest::getOwnerId()const
|
||||
{
|
||||
return ownerId_;
|
||||
}
|
||||
|
||||
void StartInstancesRequest::setOwnerId(long ownerId)
|
||||
{
|
||||
ownerId_ = ownerId;
|
||||
setParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::vector<std::string> StartInstancesRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void StartInstancesRequest::setInstanceId(const std::vector<std::string>& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
for(int dep1 = 0; dep1!= instanceId.size(); dep1++) {
|
||||
setParameter("InstanceId."+ std::to_string(dep1), instanceId.at(dep1));
|
||||
}
|
||||
}
|
||||
|
||||
44
ecs/src/model/StartInstancesResult.cc
Normal file
44
ecs/src/model/StartInstancesResult.cc
Normal file
@@ -0,0 +1,44 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ecs/model/StartInstancesResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ecs;
|
||||
using namespace AlibabaCloud::Ecs::Model;
|
||||
|
||||
StartInstancesResult::StartInstancesResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
StartInstancesResult::StartInstancesResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
StartInstancesResult::~StartInstancesResult()
|
||||
{}
|
||||
|
||||
void StartInstancesResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
130
ecs/src/model/StopInstancesRequest.cc
Normal file
130
ecs/src/model/StopInstancesRequest.cc
Normal file
@@ -0,0 +1,130 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ecs/model/StopInstancesRequest.h>
|
||||
|
||||
using AlibabaCloud::Ecs::Model::StopInstancesRequest;
|
||||
|
||||
StopInstancesRequest::StopInstancesRequest() :
|
||||
RpcServiceRequest("ecs", "2014-05-26", "StopInstances")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
StopInstancesRequest::~StopInstancesRequest()
|
||||
{}
|
||||
|
||||
long StopInstancesRequest::getResourceOwnerId()const
|
||||
{
|
||||
return resourceOwnerId_;
|
||||
}
|
||||
|
||||
void StopInstancesRequest::setResourceOwnerId(long resourceOwnerId)
|
||||
{
|
||||
resourceOwnerId_ = resourceOwnerId;
|
||||
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
|
||||
}
|
||||
|
||||
std::string StopInstancesRequest::getStoppedMode()const
|
||||
{
|
||||
return stoppedMode_;
|
||||
}
|
||||
|
||||
void StopInstancesRequest::setStoppedMode(const std::string& stoppedMode)
|
||||
{
|
||||
stoppedMode_ = stoppedMode;
|
||||
setParameter("StoppedMode", stoppedMode);
|
||||
}
|
||||
|
||||
bool StopInstancesRequest::getForceStop()const
|
||||
{
|
||||
return forceStop_;
|
||||
}
|
||||
|
||||
void StopInstancesRequest::setForceStop(bool forceStop)
|
||||
{
|
||||
forceStop_ = forceStop;
|
||||
setParameter("ForceStop", forceStop ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string StopInstancesRequest::getRegionId()const
|
||||
{
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void StopInstancesRequest::setRegionId(const std::string& regionId)
|
||||
{
|
||||
regionId_ = regionId;
|
||||
setParameter("RegionId", regionId);
|
||||
}
|
||||
|
||||
bool StopInstancesRequest::getDryRun()const
|
||||
{
|
||||
return dryRun_;
|
||||
}
|
||||
|
||||
void StopInstancesRequest::setDryRun(bool dryRun)
|
||||
{
|
||||
dryRun_ = dryRun;
|
||||
setParameter("DryRun", dryRun ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string StopInstancesRequest::getResourceOwnerAccount()const
|
||||
{
|
||||
return resourceOwnerAccount_;
|
||||
}
|
||||
|
||||
void StopInstancesRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
|
||||
{
|
||||
resourceOwnerAccount_ = resourceOwnerAccount;
|
||||
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
|
||||
}
|
||||
|
||||
std::string StopInstancesRequest::getOwnerAccount()const
|
||||
{
|
||||
return ownerAccount_;
|
||||
}
|
||||
|
||||
void StopInstancesRequest::setOwnerAccount(const std::string& ownerAccount)
|
||||
{
|
||||
ownerAccount_ = ownerAccount;
|
||||
setParameter("OwnerAccount", ownerAccount);
|
||||
}
|
||||
|
||||
long StopInstancesRequest::getOwnerId()const
|
||||
{
|
||||
return ownerId_;
|
||||
}
|
||||
|
||||
void StopInstancesRequest::setOwnerId(long ownerId)
|
||||
{
|
||||
ownerId_ = ownerId;
|
||||
setParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::vector<std::string> StopInstancesRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void StopInstancesRequest::setInstanceId(const std::vector<std::string>& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
for(int dep1 = 0; dep1!= instanceId.size(); dep1++) {
|
||||
setParameter("InstanceId."+ std::to_string(dep1), instanceId.at(dep1));
|
||||
}
|
||||
}
|
||||
|
||||
44
ecs/src/model/StopInstancesResult.cc
Normal file
44
ecs/src/model/StopInstancesResult.cc
Normal file
@@ -0,0 +1,44 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ecs/model/StopInstancesResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ecs;
|
||||
using namespace AlibabaCloud::Ecs::Model;
|
||||
|
||||
StopInstancesResult::StopInstancesResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
StopInstancesResult::StopInstancesResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
StopInstancesResult::~StopInstancesResult()
|
||||
{}
|
||||
|
||||
void StopInstancesResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user