Eni Supports Multi-SecurityGroup.
This commit is contained in:
@@ -1527,6 +1527,42 @@ EcsClient::CreateLaunchTemplateVersionOutcomeCallable EcsClient::createLaunchTem
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::CreateMaintenancePropertyOutcome EcsClient::createMaintenanceProperty(const CreateMaintenancePropertyRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return CreateMaintenancePropertyOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return CreateMaintenancePropertyOutcome(CreateMaintenancePropertyResult(outcome.result()));
|
||||
else
|
||||
return CreateMaintenancePropertyOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EcsClient::createMaintenancePropertyAsync(const CreateMaintenancePropertyRequest& request, const CreateMaintenancePropertyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, createMaintenanceProperty(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EcsClient::CreateMaintenancePropertyOutcomeCallable EcsClient::createMaintenancePropertyCallable(const CreateMaintenancePropertyRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<CreateMaintenancePropertyOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->createMaintenanceProperty(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::CreateNatGatewayOutcome EcsClient::createNatGateway(const CreateNatGatewayRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -2607,6 +2643,42 @@ EcsClient::DeleteLaunchTemplateVersionOutcomeCallable EcsClient::deleteLaunchTem
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::DeleteMaintenancePropertyOutcome EcsClient::deleteMaintenanceProperty(const DeleteMaintenancePropertyRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DeleteMaintenancePropertyOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DeleteMaintenancePropertyOutcome(DeleteMaintenancePropertyResult(outcome.result()));
|
||||
else
|
||||
return DeleteMaintenancePropertyOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EcsClient::deleteMaintenancePropertyAsync(const DeleteMaintenancePropertyRequest& request, const DeleteMaintenancePropertyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, deleteMaintenanceProperty(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EcsClient::DeleteMaintenancePropertyOutcomeCallable EcsClient::deleteMaintenancePropertyCallable(const DeleteMaintenancePropertyRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DeleteMaintenancePropertyOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->deleteMaintenanceProperty(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::DeleteNatGatewayOutcome EcsClient::deleteNatGateway(const DeleteNatGatewayRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -4803,6 +4875,42 @@ EcsClient::DescribeLimitationOutcomeCallable EcsClient::describeLimitationCallab
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::DescribeMaintenancePropertyOutcome EcsClient::describeMaintenanceProperty(const DescribeMaintenancePropertyRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeMaintenancePropertyOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeMaintenancePropertyOutcome(DescribeMaintenancePropertyResult(outcome.result()));
|
||||
else
|
||||
return DescribeMaintenancePropertyOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EcsClient::describeMaintenancePropertyAsync(const DescribeMaintenancePropertyRequest& request, const DescribeMaintenancePropertyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeMaintenanceProperty(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EcsClient::DescribeMaintenancePropertyOutcomeCallable EcsClient::describeMaintenancePropertyCallable(const DescribeMaintenancePropertyRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeMaintenancePropertyOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeMaintenanceProperty(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::DescribeNatGatewaysOutcome EcsClient::describeNatGateways(const DescribeNatGatewaysRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -7971,6 +8079,42 @@ EcsClient::ModifyLaunchTemplateDefaultVersionOutcomeCallable EcsClient::modifyLa
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::ModifyMaintenancePropertyOutcome EcsClient::modifyMaintenanceProperty(const ModifyMaintenancePropertyRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ModifyMaintenancePropertyOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ModifyMaintenancePropertyOutcome(ModifyMaintenancePropertyResult(outcome.result()));
|
||||
else
|
||||
return ModifyMaintenancePropertyOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EcsClient::modifyMaintenancePropertyAsync(const ModifyMaintenancePropertyRequest& request, const ModifyMaintenancePropertyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, modifyMaintenanceProperty(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EcsClient::ModifyMaintenancePropertyOutcomeCallable EcsClient::modifyMaintenancePropertyCallable(const ModifyMaintenancePropertyRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ModifyMaintenancePropertyOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->modifyMaintenanceProperty(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EcsClient::ModifyNetworkInterfaceAttributeOutcome EcsClient::modifyNetworkInterfaceAttribute(const ModifyNetworkInterfaceAttributeRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
|
||||
130
ecs/src/model/CreateMaintenancePropertyRequest.cc
Normal file
130
ecs/src/model/CreateMaintenancePropertyRequest.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/CreateMaintenancePropertyRequest.h>
|
||||
|
||||
using AlibabaCloud::Ecs::Model::CreateMaintenancePropertyRequest;
|
||||
|
||||
CreateMaintenancePropertyRequest::CreateMaintenancePropertyRequest() :
|
||||
RpcServiceRequest("ecs", "2014-05-26", "CreateMaintenanceProperty")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
CreateMaintenancePropertyRequest::~CreateMaintenancePropertyRequest()
|
||||
{}
|
||||
|
||||
long CreateMaintenancePropertyRequest::getResourceOwnerId()const
|
||||
{
|
||||
return resourceOwnerId_;
|
||||
}
|
||||
|
||||
void CreateMaintenancePropertyRequest::setResourceOwnerId(long resourceOwnerId)
|
||||
{
|
||||
resourceOwnerId_ = resourceOwnerId;
|
||||
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
|
||||
}
|
||||
|
||||
std::string CreateMaintenancePropertyRequest::getStartTime()const
|
||||
{
|
||||
return startTime_;
|
||||
}
|
||||
|
||||
void CreateMaintenancePropertyRequest::setStartTime(const std::string& startTime)
|
||||
{
|
||||
startTime_ = startTime;
|
||||
setCoreParameter("StartTime", startTime);
|
||||
}
|
||||
|
||||
std::string CreateMaintenancePropertyRequest::getRegionId()const
|
||||
{
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void CreateMaintenancePropertyRequest::setRegionId(const std::string& regionId)
|
||||
{
|
||||
regionId_ = regionId;
|
||||
setCoreParameter("RegionId", regionId);
|
||||
}
|
||||
|
||||
std::string CreateMaintenancePropertyRequest::getActionOnMaintenance()const
|
||||
{
|
||||
return actionOnMaintenance_;
|
||||
}
|
||||
|
||||
void CreateMaintenancePropertyRequest::setActionOnMaintenance(const std::string& actionOnMaintenance)
|
||||
{
|
||||
actionOnMaintenance_ = actionOnMaintenance;
|
||||
setCoreParameter("ActionOnMaintenance", actionOnMaintenance);
|
||||
}
|
||||
|
||||
std::string CreateMaintenancePropertyRequest::getResourceOwnerAccount()const
|
||||
{
|
||||
return resourceOwnerAccount_;
|
||||
}
|
||||
|
||||
void CreateMaintenancePropertyRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
|
||||
{
|
||||
resourceOwnerAccount_ = resourceOwnerAccount;
|
||||
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
|
||||
}
|
||||
|
||||
std::string CreateMaintenancePropertyRequest::getOwnerAccount()const
|
||||
{
|
||||
return ownerAccount_;
|
||||
}
|
||||
|
||||
void CreateMaintenancePropertyRequest::setOwnerAccount(const std::string& ownerAccount)
|
||||
{
|
||||
ownerAccount_ = ownerAccount;
|
||||
setCoreParameter("OwnerAccount", ownerAccount);
|
||||
}
|
||||
|
||||
std::string CreateMaintenancePropertyRequest::getEndTime()const
|
||||
{
|
||||
return endTime_;
|
||||
}
|
||||
|
||||
void CreateMaintenancePropertyRequest::setEndTime(const std::string& endTime)
|
||||
{
|
||||
endTime_ = endTime;
|
||||
setCoreParameter("EndTime", endTime);
|
||||
}
|
||||
|
||||
long CreateMaintenancePropertyRequest::getOwnerId()const
|
||||
{
|
||||
return ownerId_;
|
||||
}
|
||||
|
||||
void CreateMaintenancePropertyRequest::setOwnerId(long ownerId)
|
||||
{
|
||||
ownerId_ = ownerId;
|
||||
setCoreParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::vector<std::string> CreateMaintenancePropertyRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void CreateMaintenancePropertyRequest::setInstanceId(const std::vector<std::string>& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
for(int dep1 = 0; dep1!= instanceId.size(); dep1++) {
|
||||
setCoreParameter("InstanceId."+ std::to_string(dep1), instanceId.at(dep1));
|
||||
}
|
||||
}
|
||||
|
||||
44
ecs/src/model/CreateMaintenancePropertyResult.cc
Normal file
44
ecs/src/model/CreateMaintenancePropertyResult.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/CreateMaintenancePropertyResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ecs;
|
||||
using namespace AlibabaCloud::Ecs::Model;
|
||||
|
||||
CreateMaintenancePropertyResult::CreateMaintenancePropertyResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
CreateMaintenancePropertyResult::CreateMaintenancePropertyResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
CreateMaintenancePropertyResult::~CreateMaintenancePropertyResult()
|
||||
{}
|
||||
|
||||
void CreateMaintenancePropertyResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
@@ -175,6 +175,19 @@ void CreateNetworkInterfaceRequest::setOwnerId(long ownerId)
|
||||
setCoreParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::vector<std::string> CreateNetworkInterfaceRequest::getSecurityGroupIds()const
|
||||
{
|
||||
return securityGroupIds_;
|
||||
}
|
||||
|
||||
void CreateNetworkInterfaceRequest::setSecurityGroupIds(const std::vector<std::string>& securityGroupIds)
|
||||
{
|
||||
securityGroupIds_ = securityGroupIds;
|
||||
for(int dep1 = 0; dep1!= securityGroupIds.size(); dep1++) {
|
||||
setCoreParameter("SecurityGroupIds."+ std::to_string(dep1), securityGroupIds.at(dep1));
|
||||
}
|
||||
}
|
||||
|
||||
std::string CreateNetworkInterfaceRequest::getVSwitchId()const
|
||||
{
|
||||
return vSwitchId_;
|
||||
|
||||
97
ecs/src/model/DeleteMaintenancePropertyRequest.cc
Normal file
97
ecs/src/model/DeleteMaintenancePropertyRequest.cc
Normal file
@@ -0,0 +1,97 @@
|
||||
/*
|
||||
* 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/DeleteMaintenancePropertyRequest.h>
|
||||
|
||||
using AlibabaCloud::Ecs::Model::DeleteMaintenancePropertyRequest;
|
||||
|
||||
DeleteMaintenancePropertyRequest::DeleteMaintenancePropertyRequest() :
|
||||
RpcServiceRequest("ecs", "2014-05-26", "DeleteMaintenanceProperty")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DeleteMaintenancePropertyRequest::~DeleteMaintenancePropertyRequest()
|
||||
{}
|
||||
|
||||
long DeleteMaintenancePropertyRequest::getResourceOwnerId()const
|
||||
{
|
||||
return resourceOwnerId_;
|
||||
}
|
||||
|
||||
void DeleteMaintenancePropertyRequest::setResourceOwnerId(long resourceOwnerId)
|
||||
{
|
||||
resourceOwnerId_ = resourceOwnerId;
|
||||
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
|
||||
}
|
||||
|
||||
std::string DeleteMaintenancePropertyRequest::getRegionId()const
|
||||
{
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void DeleteMaintenancePropertyRequest::setRegionId(const std::string& regionId)
|
||||
{
|
||||
regionId_ = regionId;
|
||||
setCoreParameter("RegionId", regionId);
|
||||
}
|
||||
|
||||
std::string DeleteMaintenancePropertyRequest::getResourceOwnerAccount()const
|
||||
{
|
||||
return resourceOwnerAccount_;
|
||||
}
|
||||
|
||||
void DeleteMaintenancePropertyRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
|
||||
{
|
||||
resourceOwnerAccount_ = resourceOwnerAccount;
|
||||
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
|
||||
}
|
||||
|
||||
std::string DeleteMaintenancePropertyRequest::getOwnerAccount()const
|
||||
{
|
||||
return ownerAccount_;
|
||||
}
|
||||
|
||||
void DeleteMaintenancePropertyRequest::setOwnerAccount(const std::string& ownerAccount)
|
||||
{
|
||||
ownerAccount_ = ownerAccount;
|
||||
setCoreParameter("OwnerAccount", ownerAccount);
|
||||
}
|
||||
|
||||
long DeleteMaintenancePropertyRequest::getOwnerId()const
|
||||
{
|
||||
return ownerId_;
|
||||
}
|
||||
|
||||
void DeleteMaintenancePropertyRequest::setOwnerId(long ownerId)
|
||||
{
|
||||
ownerId_ = ownerId;
|
||||
setCoreParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::vector<std::string> DeleteMaintenancePropertyRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void DeleteMaintenancePropertyRequest::setInstanceId(const std::vector<std::string>& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
for(int dep1 = 0; dep1!= instanceId.size(); dep1++) {
|
||||
setCoreParameter("InstanceId."+ std::to_string(dep1), instanceId.at(dep1));
|
||||
}
|
||||
}
|
||||
|
||||
44
ecs/src/model/DeleteMaintenancePropertyResult.cc
Normal file
44
ecs/src/model/DeleteMaintenancePropertyResult.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/DeleteMaintenancePropertyResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ecs;
|
||||
using namespace AlibabaCloud::Ecs::Model;
|
||||
|
||||
DeleteMaintenancePropertyResult::DeleteMaintenancePropertyResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DeleteMaintenancePropertyResult::DeleteMaintenancePropertyResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DeleteMaintenancePropertyResult::~DeleteMaintenancePropertyResult()
|
||||
{}
|
||||
|
||||
void DeleteMaintenancePropertyResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
@@ -53,6 +53,8 @@ void DescribeDemandsResult::parse(const std::string &payload)
|
||||
demandsObject.demandId = valueDemandsDemand["DemandId"].asString();
|
||||
if(!valueDemandsDemand["DemandName"].isNull())
|
||||
demandsObject.demandName = valueDemandsDemand["DemandName"].asString();
|
||||
if(!valueDemandsDemand["Comment"].isNull())
|
||||
demandsObject.comment = valueDemandsDemand["Comment"].asString();
|
||||
if(!valueDemandsDemand["DemandDescription"].isNull())
|
||||
demandsObject.demandDescription = valueDemandsDemand["DemandDescription"].asString();
|
||||
if(!valueDemandsDemand["InstanceType"].isNull())
|
||||
|
||||
119
ecs/src/model/DescribeMaintenancePropertyRequest.cc
Normal file
119
ecs/src/model/DescribeMaintenancePropertyRequest.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/DescribeMaintenancePropertyRequest.h>
|
||||
|
||||
using AlibabaCloud::Ecs::Model::DescribeMaintenancePropertyRequest;
|
||||
|
||||
DescribeMaintenancePropertyRequest::DescribeMaintenancePropertyRequest() :
|
||||
RpcServiceRequest("ecs", "2014-05-26", "DescribeMaintenanceProperty")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DescribeMaintenancePropertyRequest::~DescribeMaintenancePropertyRequest()
|
||||
{}
|
||||
|
||||
long DescribeMaintenancePropertyRequest::getResourceOwnerId()const
|
||||
{
|
||||
return resourceOwnerId_;
|
||||
}
|
||||
|
||||
void DescribeMaintenancePropertyRequest::setResourceOwnerId(long resourceOwnerId)
|
||||
{
|
||||
resourceOwnerId_ = resourceOwnerId;
|
||||
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
|
||||
}
|
||||
|
||||
long DescribeMaintenancePropertyRequest::getPageNumber()const
|
||||
{
|
||||
return pageNumber_;
|
||||
}
|
||||
|
||||
void DescribeMaintenancePropertyRequest::setPageNumber(long pageNumber)
|
||||
{
|
||||
pageNumber_ = pageNumber;
|
||||
setCoreParameter("PageNumber", std::to_string(pageNumber));
|
||||
}
|
||||
|
||||
std::string DescribeMaintenancePropertyRequest::getRegionId()const
|
||||
{
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void DescribeMaintenancePropertyRequest::setRegionId(const std::string& regionId)
|
||||
{
|
||||
regionId_ = regionId;
|
||||
setCoreParameter("RegionId", regionId);
|
||||
}
|
||||
|
||||
long DescribeMaintenancePropertyRequest::getPageSize()const
|
||||
{
|
||||
return pageSize_;
|
||||
}
|
||||
|
||||
void DescribeMaintenancePropertyRequest::setPageSize(long pageSize)
|
||||
{
|
||||
pageSize_ = pageSize;
|
||||
setCoreParameter("PageSize", std::to_string(pageSize));
|
||||
}
|
||||
|
||||
std::string DescribeMaintenancePropertyRequest::getResourceOwnerAccount()const
|
||||
{
|
||||
return resourceOwnerAccount_;
|
||||
}
|
||||
|
||||
void DescribeMaintenancePropertyRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
|
||||
{
|
||||
resourceOwnerAccount_ = resourceOwnerAccount;
|
||||
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
|
||||
}
|
||||
|
||||
std::string DescribeMaintenancePropertyRequest::getOwnerAccount()const
|
||||
{
|
||||
return ownerAccount_;
|
||||
}
|
||||
|
||||
void DescribeMaintenancePropertyRequest::setOwnerAccount(const std::string& ownerAccount)
|
||||
{
|
||||
ownerAccount_ = ownerAccount;
|
||||
setCoreParameter("OwnerAccount", ownerAccount);
|
||||
}
|
||||
|
||||
long DescribeMaintenancePropertyRequest::getOwnerId()const
|
||||
{
|
||||
return ownerId_;
|
||||
}
|
||||
|
||||
void DescribeMaintenancePropertyRequest::setOwnerId(long ownerId)
|
||||
{
|
||||
ownerId_ = ownerId;
|
||||
setCoreParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::vector<std::string> DescribeMaintenancePropertyRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void DescribeMaintenancePropertyRequest::setInstanceId(const std::vector<std::string>& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
for(int dep1 = 0; dep1!= instanceId.size(); dep1++) {
|
||||
setCoreParameter("InstanceId."+ std::to_string(dep1), instanceId.at(dep1));
|
||||
}
|
||||
}
|
||||
|
||||
84
ecs/src/model/DescribeMaintenancePropertyResult.cc
Normal file
84
ecs/src/model/DescribeMaintenancePropertyResult.cc
Normal file
@@ -0,0 +1,84 @@
|
||||
/*
|
||||
* 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/DescribeMaintenancePropertyResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ecs;
|
||||
using namespace AlibabaCloud::Ecs::Model;
|
||||
|
||||
DescribeMaintenancePropertyResult::DescribeMaintenancePropertyResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DescribeMaintenancePropertyResult::DescribeMaintenancePropertyResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DescribeMaintenancePropertyResult::~DescribeMaintenancePropertyResult()
|
||||
{}
|
||||
|
||||
void DescribeMaintenancePropertyResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allMaintenancePropertySetNode = value["MaintenancePropertySet"]["MaintenanceProperty"];
|
||||
for (auto valueMaintenancePropertySetMaintenanceProperty : allMaintenancePropertySetNode)
|
||||
{
|
||||
MaintenanceProperty maintenancePropertySetObject;
|
||||
if(!valueMaintenancePropertySetMaintenanceProperty["InstanceId"].isNull())
|
||||
maintenancePropertySetObject.instanceId = valueMaintenancePropertySetMaintenanceProperty["InstanceId"].asString();
|
||||
if(!valueMaintenancePropertySetMaintenanceProperty["StartTime"].isNull())
|
||||
maintenancePropertySetObject.startTime = valueMaintenancePropertySetMaintenanceProperty["StartTime"].asString();
|
||||
if(!valueMaintenancePropertySetMaintenanceProperty["EndTime"].isNull())
|
||||
maintenancePropertySetObject.endTime = valueMaintenancePropertySetMaintenanceProperty["EndTime"].asString();
|
||||
if(!valueMaintenancePropertySetMaintenanceProperty["ActionOnMaintenance"].isNull())
|
||||
maintenancePropertySetObject.actionOnMaintenance = valueMaintenancePropertySetMaintenanceProperty["ActionOnMaintenance"].asString();
|
||||
maintenancePropertySet_.push_back(maintenancePropertySetObject);
|
||||
}
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = std::stoi(value["TotalCount"].asString());
|
||||
if(!value["PageNumber"].isNull())
|
||||
pageNumber_ = std::stoi(value["PageNumber"].asString());
|
||||
if(!value["PageSize"].isNull())
|
||||
pageSize_ = std::stoi(value["PageSize"].asString());
|
||||
|
||||
}
|
||||
|
||||
int DescribeMaintenancePropertyResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
int DescribeMaintenancePropertyResult::getPageSize()const
|
||||
{
|
||||
return pageSize_;
|
||||
}
|
||||
|
||||
int DescribeMaintenancePropertyResult::getPageNumber()const
|
||||
{
|
||||
return pageNumber_;
|
||||
}
|
||||
|
||||
std::vector<DescribeMaintenancePropertyResult::MaintenanceProperty> DescribeMaintenancePropertyResult::getMaintenancePropertySet()const
|
||||
{
|
||||
return maintenancePropertySet_;
|
||||
}
|
||||
|
||||
@@ -45,6 +45,8 @@ void DescribeSnapshotsResult::parse(const std::string &payload)
|
||||
Snapshot snapshotsObject;
|
||||
if(!valueSnapshotsSnapshot["SnapshotId"].isNull())
|
||||
snapshotsObject.snapshotId = valueSnapshotsSnapshot["SnapshotId"].asString();
|
||||
if(!valueSnapshotsSnapshot["SnapshotSN"].isNull())
|
||||
snapshotsObject.snapshotSN = valueSnapshotsSnapshot["SnapshotSN"].asString();
|
||||
if(!valueSnapshotsSnapshot["SnapshotName"].isNull())
|
||||
snapshotsObject.snapshotName = valueSnapshotsSnapshot["SnapshotName"].asString();
|
||||
if(!valueSnapshotsSnapshot["Progress"].isNull())
|
||||
|
||||
130
ecs/src/model/ModifyMaintenancePropertyRequest.cc
Normal file
130
ecs/src/model/ModifyMaintenancePropertyRequest.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/ModifyMaintenancePropertyRequest.h>
|
||||
|
||||
using AlibabaCloud::Ecs::Model::ModifyMaintenancePropertyRequest;
|
||||
|
||||
ModifyMaintenancePropertyRequest::ModifyMaintenancePropertyRequest() :
|
||||
RpcServiceRequest("ecs", "2014-05-26", "ModifyMaintenanceProperty")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
ModifyMaintenancePropertyRequest::~ModifyMaintenancePropertyRequest()
|
||||
{}
|
||||
|
||||
long ModifyMaintenancePropertyRequest::getResourceOwnerId()const
|
||||
{
|
||||
return resourceOwnerId_;
|
||||
}
|
||||
|
||||
void ModifyMaintenancePropertyRequest::setResourceOwnerId(long resourceOwnerId)
|
||||
{
|
||||
resourceOwnerId_ = resourceOwnerId;
|
||||
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
|
||||
}
|
||||
|
||||
std::string ModifyMaintenancePropertyRequest::getStartTime()const
|
||||
{
|
||||
return startTime_;
|
||||
}
|
||||
|
||||
void ModifyMaintenancePropertyRequest::setStartTime(const std::string& startTime)
|
||||
{
|
||||
startTime_ = startTime;
|
||||
setCoreParameter("StartTime", startTime);
|
||||
}
|
||||
|
||||
std::string ModifyMaintenancePropertyRequest::getRegionId()const
|
||||
{
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void ModifyMaintenancePropertyRequest::setRegionId(const std::string& regionId)
|
||||
{
|
||||
regionId_ = regionId;
|
||||
setCoreParameter("RegionId", regionId);
|
||||
}
|
||||
|
||||
std::string ModifyMaintenancePropertyRequest::getActionOnMaintenance()const
|
||||
{
|
||||
return actionOnMaintenance_;
|
||||
}
|
||||
|
||||
void ModifyMaintenancePropertyRequest::setActionOnMaintenance(const std::string& actionOnMaintenance)
|
||||
{
|
||||
actionOnMaintenance_ = actionOnMaintenance;
|
||||
setCoreParameter("ActionOnMaintenance", actionOnMaintenance);
|
||||
}
|
||||
|
||||
std::string ModifyMaintenancePropertyRequest::getResourceOwnerAccount()const
|
||||
{
|
||||
return resourceOwnerAccount_;
|
||||
}
|
||||
|
||||
void ModifyMaintenancePropertyRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
|
||||
{
|
||||
resourceOwnerAccount_ = resourceOwnerAccount;
|
||||
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
|
||||
}
|
||||
|
||||
std::string ModifyMaintenancePropertyRequest::getOwnerAccount()const
|
||||
{
|
||||
return ownerAccount_;
|
||||
}
|
||||
|
||||
void ModifyMaintenancePropertyRequest::setOwnerAccount(const std::string& ownerAccount)
|
||||
{
|
||||
ownerAccount_ = ownerAccount;
|
||||
setCoreParameter("OwnerAccount", ownerAccount);
|
||||
}
|
||||
|
||||
std::string ModifyMaintenancePropertyRequest::getEndTime()const
|
||||
{
|
||||
return endTime_;
|
||||
}
|
||||
|
||||
void ModifyMaintenancePropertyRequest::setEndTime(const std::string& endTime)
|
||||
{
|
||||
endTime_ = endTime;
|
||||
setCoreParameter("EndTime", endTime);
|
||||
}
|
||||
|
||||
long ModifyMaintenancePropertyRequest::getOwnerId()const
|
||||
{
|
||||
return ownerId_;
|
||||
}
|
||||
|
||||
void ModifyMaintenancePropertyRequest::setOwnerId(long ownerId)
|
||||
{
|
||||
ownerId_ = ownerId;
|
||||
setCoreParameter("OwnerId", std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::vector<std::string> ModifyMaintenancePropertyRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void ModifyMaintenancePropertyRequest::setInstanceId(const std::vector<std::string>& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
for(int dep1 = 0; dep1!= instanceId.size(); dep1++) {
|
||||
setCoreParameter("InstanceId."+ std::to_string(dep1), instanceId.at(dep1));
|
||||
}
|
||||
}
|
||||
|
||||
44
ecs/src/model/ModifyMaintenancePropertyResult.cc
Normal file
44
ecs/src/model/ModifyMaintenancePropertyResult.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/ModifyMaintenancePropertyResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ecs;
|
||||
using namespace AlibabaCloud::Ecs::Model;
|
||||
|
||||
ModifyMaintenancePropertyResult::ModifyMaintenancePropertyResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ModifyMaintenancePropertyResult::ModifyMaintenancePropertyResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ModifyMaintenancePropertyResult::~ModifyMaintenancePropertyResult()
|
||||
{}
|
||||
|
||||
void ModifyMaintenancePropertyResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
@@ -620,6 +620,9 @@ void RunInstancesRequest::setNetworkInterface(const std::vector<NetworkInterface
|
||||
setCoreParameter(networkInterfaceObjStr + ".PrimaryIpAddress", networkInterfaceObj.primaryIpAddress);
|
||||
setCoreParameter(networkInterfaceObjStr + ".VSwitchId", networkInterfaceObj.vSwitchId);
|
||||
setCoreParameter(networkInterfaceObjStr + ".SecurityGroupId", networkInterfaceObj.securityGroupId);
|
||||
for(int dep2 = 0; dep2!= networkInterfaceObj.securityGroupIds.size(); dep2++) {
|
||||
setCoreParameter(networkInterfaceObjStr + ".SecurityGroupIds."+ std::to_string(dep2), networkInterfaceObj.securityGroupIds.at(dep2));
|
||||
}
|
||||
setCoreParameter(networkInterfaceObjStr + ".NetworkInterfaceName", networkInterfaceObj.networkInterfaceName);
|
||||
setCoreParameter(networkInterfaceObjStr + ".Description", networkInterfaceObj.description);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user