Generated 2017-11-10 for Ens.
This commit is contained in:
@@ -411,6 +411,42 @@ EnsClient::AttachEnsInstancesOutcomeCallable EnsClient::attachEnsInstancesCallab
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::AttachInstanceSDGOutcome EnsClient::attachInstanceSDG(const AttachInstanceSDGRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return AttachInstanceSDGOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return AttachInstanceSDGOutcome(AttachInstanceSDGResult(outcome.result()));
|
||||
else
|
||||
return AttachInstanceSDGOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EnsClient::attachInstanceSDGAsync(const AttachInstanceSDGRequest& request, const AttachInstanceSDGAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, attachInstanceSDG(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EnsClient::AttachInstanceSDGOutcomeCallable EnsClient::attachInstanceSDGCallable(const AttachInstanceSDGRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<AttachInstanceSDGOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->attachInstanceSDG(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::AttachNetworkInterfaceOutcome EnsClient::attachNetworkInterface(const AttachNetworkInterfaceRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -1059,6 +1095,42 @@ EnsClient::CreateForwardEntryOutcomeCallable EnsClient::createForwardEntryCallab
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::CreateHaVipOutcome EnsClient::createHaVip(const CreateHaVipRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return CreateHaVipOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return CreateHaVipOutcome(CreateHaVipResult(outcome.result()));
|
||||
else
|
||||
return CreateHaVipOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EnsClient::createHaVipAsync(const CreateHaVipRequest& request, const CreateHaVipAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, createHaVip(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EnsClient::CreateHaVipOutcomeCallable EnsClient::createHaVipCallable(const CreateHaVipRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<CreateHaVipOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->createHaVip(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::CreateImageOutcome EnsClient::createImage(const CreateImageRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -1563,6 +1635,42 @@ EnsClient::CreateNetworkAclEntryOutcomeCallable EnsClient::createNetworkAclEntry
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::CreateNetworkInterfaceOutcome EnsClient::createNetworkInterface(const CreateNetworkInterfaceRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return CreateNetworkInterfaceOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return CreateNetworkInterfaceOutcome(CreateNetworkInterfaceResult(outcome.result()));
|
||||
else
|
||||
return CreateNetworkInterfaceOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EnsClient::createNetworkInterfaceAsync(const CreateNetworkInterfaceRequest& request, const CreateNetworkInterfaceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, createNetworkInterface(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EnsClient::CreateNetworkInterfaceOutcomeCallable EnsClient::createNetworkInterfaceCallable(const CreateNetworkInterfaceRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<CreateNetworkInterfaceOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->createNetworkInterface(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::CreateSDGOutcome EnsClient::createSDG(const CreateSDGRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -2211,6 +2319,42 @@ EnsClient::DeleteForwardEntryOutcomeCallable EnsClient::deleteForwardEntryCallab
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::DeleteHaVipsOutcome EnsClient::deleteHaVips(const DeleteHaVipsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DeleteHaVipsOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DeleteHaVipsOutcome(DeleteHaVipsResult(outcome.result()));
|
||||
else
|
||||
return DeleteHaVipsOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EnsClient::deleteHaVipsAsync(const DeleteHaVipsRequest& request, const DeleteHaVipsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, deleteHaVips(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EnsClient::DeleteHaVipsOutcomeCallable EnsClient::deleteHaVipsCallable(const DeleteHaVipsRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DeleteHaVipsOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->deleteHaVips(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::DeleteImageOutcome EnsClient::deleteImage(const DeleteImageRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -2499,6 +2643,42 @@ EnsClient::DeleteNetworkAclEntryOutcomeCallable EnsClient::deleteNetworkAclEntry
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::DeleteNetworkInterfacesOutcome EnsClient::deleteNetworkInterfaces(const DeleteNetworkInterfacesRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DeleteNetworkInterfacesOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DeleteNetworkInterfacesOutcome(DeleteNetworkInterfacesResult(outcome.result()));
|
||||
else
|
||||
return DeleteNetworkInterfacesOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EnsClient::deleteNetworkInterfacesAsync(const DeleteNetworkInterfacesRequest& request, const DeleteNetworkInterfacesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, deleteNetworkInterfaces(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EnsClient::DeleteNetworkInterfacesOutcomeCallable EnsClient::deleteNetworkInterfacesCallable(const DeleteNetworkInterfacesRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DeleteNetworkInterfacesOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->deleteNetworkInterfaces(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::DeleteObjectOutcome EnsClient::deleteObject(const DeleteObjectRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -3975,6 +4155,42 @@ EnsClient::DescribeEnsRouteEntryListOutcomeCallable EnsClient::describeEnsRouteE
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::DescribeEnsRouteTablesOutcome EnsClient::describeEnsRouteTables(const DescribeEnsRouteTablesRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeEnsRouteTablesOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeEnsRouteTablesOutcome(DescribeEnsRouteTablesResult(outcome.result()));
|
||||
else
|
||||
return DescribeEnsRouteTablesOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EnsClient::describeEnsRouteTablesAsync(const DescribeEnsRouteTablesRequest& request, const DescribeEnsRouteTablesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeEnsRouteTables(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EnsClient::DescribeEnsRouteTablesOutcomeCallable EnsClient::describeEnsRouteTablesCallable(const DescribeEnsRouteTablesRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeEnsRouteTablesOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeEnsRouteTables(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::DescribeEnsSaleControlOutcome EnsClient::describeEnsSaleControl(const DescribeEnsSaleControlRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -4659,6 +4875,42 @@ EnsClient::DescribeInstanceMonitorDataOutcomeCallable EnsClient::describeInstanc
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::DescribeInstanceSDGStatusOutcome EnsClient::describeInstanceSDGStatus(const DescribeInstanceSDGStatusRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeInstanceSDGStatusOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeInstanceSDGStatusOutcome(DescribeInstanceSDGStatusResult(outcome.result()));
|
||||
else
|
||||
return DescribeInstanceSDGStatusOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EnsClient::describeInstanceSDGStatusAsync(const DescribeInstanceSDGStatusRequest& request, const DescribeInstanceSDGStatusAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeInstanceSDGStatus(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EnsClient::DescribeInstanceSDGStatusOutcomeCallable EnsClient::describeInstanceSDGStatusCallable(const DescribeInstanceSDGStatusRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeInstanceSDGStatusOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeInstanceSDGStatus(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::DescribeInstanceSpecOutcome EnsClient::describeInstanceSpec(const DescribeInstanceSpecRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -6315,6 +6567,42 @@ EnsClient::DetachDiskOutcomeCallable EnsClient::detachDiskCallable(const DetachD
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::DetachInstanceSDGOutcome EnsClient::detachInstanceSDG(const DetachInstanceSDGRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DetachInstanceSDGOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DetachInstanceSDGOutcome(DetachInstanceSDGResult(outcome.result()));
|
||||
else
|
||||
return DetachInstanceSDGOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EnsClient::detachInstanceSDGAsync(const DetachInstanceSDGRequest& request, const DetachInstanceSDGAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, detachInstanceSDG(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EnsClient::DetachInstanceSDGOutcomeCallable EnsClient::detachInstanceSDGCallable(const DetachInstanceSDGRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DetachInstanceSDGOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->detachInstanceSDG(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::DetachNetworkInterfaceOutcome EnsClient::detachNetworkInterface(const DetachNetworkInterfaceRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -7683,6 +7971,42 @@ EnsClient::ModifyVSwitchAttributeOutcomeCallable EnsClient::modifyVSwitchAttribu
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::MountInstanceSDGOutcome EnsClient::mountInstanceSDG(const MountInstanceSDGRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return MountInstanceSDGOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return MountInstanceSDGOutcome(MountInstanceSDGResult(outcome.result()));
|
||||
else
|
||||
return MountInstanceSDGOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EnsClient::mountInstanceSDGAsync(const MountInstanceSDGRequest& request, const MountInstanceSDGAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, mountInstanceSDG(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EnsClient::MountInstanceSDGOutcomeCallable EnsClient::mountInstanceSDGCallable(const MountInstanceSDGRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<MountInstanceSDGOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->mountInstanceSDG(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::PreloadRegionSDGOutcome EnsClient::preloadRegionSDG(const PreloadRegionSDGRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -9879,6 +10203,42 @@ EnsClient::UnloadRegionSDGOutcomeCallable EnsClient::unloadRegionSDGCallable(con
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::UnmountInstanceSDGOutcome EnsClient::unmountInstanceSDG(const UnmountInstanceSDGRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return UnmountInstanceSDGOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return UnmountInstanceSDGOutcome(UnmountInstanceSDGResult(outcome.result()));
|
||||
else
|
||||
return UnmountInstanceSDGOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void EnsClient::unmountInstanceSDGAsync(const UnmountInstanceSDGRequest& request, const UnmountInstanceSDGAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, unmountInstanceSDG(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
EnsClient::UnmountInstanceSDGOutcomeCallable EnsClient::unmountInstanceSDGCallable(const UnmountInstanceSDGRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<UnmountInstanceSDGOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->unmountInstanceSDG(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
EnsClient::UntagResourcesOutcome EnsClient::untagResources(const UntagResourcesRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
|
||||
47
ens/src/model/AttachInstanceSDGRequest.cc
Normal file
47
ens/src/model/AttachInstanceSDGRequest.cc
Normal file
@@ -0,0 +1,47 @@
|
||||
/*
|
||||
* 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/ens/model/AttachInstanceSDGRequest.h>
|
||||
|
||||
using AlibabaCloud::Ens::Model::AttachInstanceSDGRequest;
|
||||
|
||||
AttachInstanceSDGRequest::AttachInstanceSDGRequest()
|
||||
: RpcServiceRequest("ens", "2017-11-10", "AttachInstanceSDG") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
AttachInstanceSDGRequest::~AttachInstanceSDGRequest() {}
|
||||
|
||||
std::string AttachInstanceSDGRequest::getSDGId() const {
|
||||
return sDGId_;
|
||||
}
|
||||
|
||||
void AttachInstanceSDGRequest::setSDGId(const std::string &sDGId) {
|
||||
sDGId_ = sDGId;
|
||||
setParameter(std::string("SDGId"), sDGId);
|
||||
}
|
||||
|
||||
std::vector<AttachInstanceSDGRequest::std::string> AttachInstanceSDGRequest::getInstanceIds() const {
|
||||
return instanceIds_;
|
||||
}
|
||||
|
||||
void AttachInstanceSDGRequest::setInstanceIds(const std::vector<AttachInstanceSDGRequest::std::string> &instanceIds) {
|
||||
instanceIds_ = instanceIds;
|
||||
for(int dep1 = 0; dep1 != instanceIds.size(); dep1++) {
|
||||
setParameter(std::string("InstanceIds") + "." + std::to_string(dep1 + 1), instanceIds[dep1]);
|
||||
}
|
||||
}
|
||||
|
||||
69
ens/src/model/AttachInstanceSDGResult.cc
Normal file
69
ens/src/model/AttachInstanceSDGResult.cc
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.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ens/model/AttachInstanceSDGResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ens;
|
||||
using namespace AlibabaCloud::Ens::Model;
|
||||
|
||||
AttachInstanceSDGResult::AttachInstanceSDGResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
AttachInstanceSDGResult::AttachInstanceSDGResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
AttachInstanceSDGResult::~AttachInstanceSDGResult()
|
||||
{}
|
||||
|
||||
void AttachInstanceSDGResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
if(!dataNode["Message"].isNull())
|
||||
data_.message = dataNode["Message"].asString();
|
||||
if(!dataNode["Success"].isNull())
|
||||
data_.success = dataNode["Success"].asString() == "true";
|
||||
auto resultNode = dataNode["Result"];
|
||||
if(!resultNode["FailedCount"].isNull())
|
||||
data_.result.failedCount = std::stol(resultNode["FailedCount"].asString());
|
||||
if(!resultNode["SuccessCount"].isNull())
|
||||
data_.result.successCount = std::stol(resultNode["SuccessCount"].asString());
|
||||
auto allFailedItemsNode = resultNode["FailedItems"]["FailedItemsItem"];
|
||||
for (auto resultNodeFailedItemsFailedItemsItem : allFailedItemsNode)
|
||||
{
|
||||
Data::Result::FailedItemsItem failedItemsItemObject;
|
||||
if(!resultNodeFailedItemsFailedItemsItem["ErrMessage"].isNull())
|
||||
failedItemsItemObject.errMessage = resultNodeFailedItemsFailedItemsItem["ErrMessage"].asString();
|
||||
if(!resultNodeFailedItemsFailedItemsItem["InstanceId"].isNull())
|
||||
failedItemsItemObject.instanceId = resultNodeFailedItemsFailedItemsItem["InstanceId"].asString();
|
||||
data_.result.failedItems.push_back(failedItemsItemObject);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
AttachInstanceSDGResult::Data AttachInstanceSDGResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
@@ -133,6 +133,15 @@ void CreateARMServerInstancesRequest::setAmount(int amount) {
|
||||
setParameter(std::string("Amount"), std::to_string(amount));
|
||||
}
|
||||
|
||||
std::string CreateARMServerInstancesRequest::getEnvironmentVar() const {
|
||||
return environmentVar_;
|
||||
}
|
||||
|
||||
void CreateARMServerInstancesRequest::setEnvironmentVar(const std::string &environmentVar) {
|
||||
environmentVar_ = environmentVar;
|
||||
setParameter(std::string("EnvironmentVar"), environmentVar);
|
||||
}
|
||||
|
||||
std::string CreateARMServerInstancesRequest::get_NameSpace() const {
|
||||
return _nameSpace_;
|
||||
}
|
||||
|
||||
72
ens/src/model/CreateHaVipRequest.cc
Normal file
72
ens/src/model/CreateHaVipRequest.cc
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.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ens/model/CreateHaVipRequest.h>
|
||||
|
||||
using AlibabaCloud::Ens::Model::CreateHaVipRequest;
|
||||
|
||||
CreateHaVipRequest::CreateHaVipRequest()
|
||||
: RpcServiceRequest("ens", "2017-11-10", "CreateHaVip") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
CreateHaVipRequest::~CreateHaVipRequest() {}
|
||||
|
||||
std::string CreateHaVipRequest::getIpAddress() const {
|
||||
return ipAddress_;
|
||||
}
|
||||
|
||||
void CreateHaVipRequest::setIpAddress(const std::string &ipAddress) {
|
||||
ipAddress_ = ipAddress;
|
||||
setParameter(std::string("IpAddress"), ipAddress);
|
||||
}
|
||||
|
||||
std::string CreateHaVipRequest::getDescription() const {
|
||||
return description_;
|
||||
}
|
||||
|
||||
void CreateHaVipRequest::setDescription(const std::string &description) {
|
||||
description_ = description;
|
||||
setParameter(std::string("Description"), description);
|
||||
}
|
||||
|
||||
int CreateHaVipRequest::getAmount() const {
|
||||
return amount_;
|
||||
}
|
||||
|
||||
void CreateHaVipRequest::setAmount(int amount) {
|
||||
amount_ = amount;
|
||||
setParameter(std::string("Amount"), std::to_string(amount));
|
||||
}
|
||||
|
||||
std::string CreateHaVipRequest::getVSwitchId() const {
|
||||
return vSwitchId_;
|
||||
}
|
||||
|
||||
void CreateHaVipRequest::setVSwitchId(const std::string &vSwitchId) {
|
||||
vSwitchId_ = vSwitchId;
|
||||
setParameter(std::string("VSwitchId"), vSwitchId);
|
||||
}
|
||||
|
||||
std::string CreateHaVipRequest::getName() const {
|
||||
return name_;
|
||||
}
|
||||
|
||||
void CreateHaVipRequest::setName(const std::string &name) {
|
||||
name_ = name;
|
||||
setParameter(std::string("Name"), name);
|
||||
}
|
||||
|
||||
52
ens/src/model/CreateHaVipResult.cc
Normal file
52
ens/src/model/CreateHaVipResult.cc
Normal file
@@ -0,0 +1,52 @@
|
||||
/*
|
||||
* 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/ens/model/CreateHaVipResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ens;
|
||||
using namespace AlibabaCloud::Ens::Model;
|
||||
|
||||
CreateHaVipResult::CreateHaVipResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
CreateHaVipResult::CreateHaVipResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
CreateHaVipResult::~CreateHaVipResult()
|
||||
{}
|
||||
|
||||
void CreateHaVipResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allHaVipIds = value["HaVipIds"]["HaVipIds"];
|
||||
for (const auto &item : allHaVipIds)
|
||||
haVipIds_.push_back(item.asString());
|
||||
|
||||
}
|
||||
|
||||
std::vector<std::string> CreateHaVipResult::getHaVipIds()const
|
||||
{
|
||||
return haVipIds_;
|
||||
}
|
||||
|
||||
65
ens/src/model/CreateNetworkInterfaceRequest.cc
Normal file
65
ens/src/model/CreateNetworkInterfaceRequest.cc
Normal file
@@ -0,0 +1,65 @@
|
||||
/*
|
||||
* 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/ens/model/CreateNetworkInterfaceRequest.h>
|
||||
|
||||
using AlibabaCloud::Ens::Model::CreateNetworkInterfaceRequest;
|
||||
|
||||
CreateNetworkInterfaceRequest::CreateNetworkInterfaceRequest()
|
||||
: RpcServiceRequest("ens", "2017-11-10", "CreateNetworkInterface") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
CreateNetworkInterfaceRequest::~CreateNetworkInterfaceRequest() {}
|
||||
|
||||
std::string CreateNetworkInterfaceRequest::getDescription() const {
|
||||
return description_;
|
||||
}
|
||||
|
||||
void CreateNetworkInterfaceRequest::setDescription(const std::string &description) {
|
||||
description_ = description;
|
||||
setParameter(std::string("Description"), description);
|
||||
}
|
||||
|
||||
std::vector<CreateNetworkInterfaceRequest::std::string> CreateNetworkInterfaceRequest::getSecurityGroupIds() const {
|
||||
return securityGroupIds_;
|
||||
}
|
||||
|
||||
void CreateNetworkInterfaceRequest::setSecurityGroupIds(const std::vector<CreateNetworkInterfaceRequest::std::string> &securityGroupIds) {
|
||||
securityGroupIds_ = securityGroupIds;
|
||||
for(int dep1 = 0; dep1 != securityGroupIds.size(); dep1++) {
|
||||
setParameter(std::string("SecurityGroupIds") + "." + std::to_string(dep1 + 1), securityGroupIds[dep1]);
|
||||
}
|
||||
}
|
||||
|
||||
std::string CreateNetworkInterfaceRequest::getVSwitchId() const {
|
||||
return vSwitchId_;
|
||||
}
|
||||
|
||||
void CreateNetworkInterfaceRequest::setVSwitchId(const std::string &vSwitchId) {
|
||||
vSwitchId_ = vSwitchId;
|
||||
setParameter(std::string("VSwitchId"), vSwitchId);
|
||||
}
|
||||
|
||||
std::string CreateNetworkInterfaceRequest::getName() const {
|
||||
return name_;
|
||||
}
|
||||
|
||||
void CreateNetworkInterfaceRequest::setName(const std::string &name) {
|
||||
name_ = name;
|
||||
setParameter(std::string("Name"), name);
|
||||
}
|
||||
|
||||
52
ens/src/model/CreateNetworkInterfaceResult.cc
Normal file
52
ens/src/model/CreateNetworkInterfaceResult.cc
Normal file
@@ -0,0 +1,52 @@
|
||||
/*
|
||||
* 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/ens/model/CreateNetworkInterfaceResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ens;
|
||||
using namespace AlibabaCloud::Ens::Model;
|
||||
|
||||
CreateNetworkInterfaceResult::CreateNetworkInterfaceResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
CreateNetworkInterfaceResult::CreateNetworkInterfaceResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
CreateNetworkInterfaceResult::~CreateNetworkInterfaceResult()
|
||||
{}
|
||||
|
||||
void CreateNetworkInterfaceResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allNetworkInterfaceIds = value["NetworkInterfaceIds"]["NetworkInterfaceIds"];
|
||||
for (const auto &item : allNetworkInterfaceIds)
|
||||
networkInterfaceIds_.push_back(item.asString());
|
||||
|
||||
}
|
||||
|
||||
std::vector<std::string> CreateNetworkInterfaceResult::getNetworkInterfaceIds()const
|
||||
{
|
||||
return networkInterfaceIds_;
|
||||
}
|
||||
|
||||
38
ens/src/model/DeleteHaVipsRequest.cc
Normal file
38
ens/src/model/DeleteHaVipsRequest.cc
Normal file
@@ -0,0 +1,38 @@
|
||||
/*
|
||||
* 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/ens/model/DeleteHaVipsRequest.h>
|
||||
|
||||
using AlibabaCloud::Ens::Model::DeleteHaVipsRequest;
|
||||
|
||||
DeleteHaVipsRequest::DeleteHaVipsRequest()
|
||||
: RpcServiceRequest("ens", "2017-11-10", "DeleteHaVips") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DeleteHaVipsRequest::~DeleteHaVipsRequest() {}
|
||||
|
||||
std::vector<DeleteHaVipsRequest::std::string> DeleteHaVipsRequest::getHaVipIds() const {
|
||||
return haVipIds_;
|
||||
}
|
||||
|
||||
void DeleteHaVipsRequest::setHaVipIds(const std::vector<DeleteHaVipsRequest::std::string> &haVipIds) {
|
||||
haVipIds_ = haVipIds;
|
||||
for(int dep1 = 0; dep1 != haVipIds.size(); dep1++) {
|
||||
setParameter(std::string("HaVipIds") + "." + std::to_string(dep1 + 1), haVipIds[dep1]);
|
||||
}
|
||||
}
|
||||
|
||||
44
ens/src/model/DeleteHaVipsResult.cc
Normal file
44
ens/src/model/DeleteHaVipsResult.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/ens/model/DeleteHaVipsResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ens;
|
||||
using namespace AlibabaCloud::Ens::Model;
|
||||
|
||||
DeleteHaVipsResult::DeleteHaVipsResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DeleteHaVipsResult::DeleteHaVipsResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DeleteHaVipsResult::~DeleteHaVipsResult()
|
||||
{}
|
||||
|
||||
void DeleteHaVipsResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
38
ens/src/model/DeleteNetworkInterfacesRequest.cc
Normal file
38
ens/src/model/DeleteNetworkInterfacesRequest.cc
Normal file
@@ -0,0 +1,38 @@
|
||||
/*
|
||||
* 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/ens/model/DeleteNetworkInterfacesRequest.h>
|
||||
|
||||
using AlibabaCloud::Ens::Model::DeleteNetworkInterfacesRequest;
|
||||
|
||||
DeleteNetworkInterfacesRequest::DeleteNetworkInterfacesRequest()
|
||||
: RpcServiceRequest("ens", "2017-11-10", "DeleteNetworkInterfaces") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DeleteNetworkInterfacesRequest::~DeleteNetworkInterfacesRequest() {}
|
||||
|
||||
std::vector<DeleteNetworkInterfacesRequest::std::string> DeleteNetworkInterfacesRequest::getNetworkInterfaceIds() const {
|
||||
return networkInterfaceIds_;
|
||||
}
|
||||
|
||||
void DeleteNetworkInterfacesRequest::setNetworkInterfaceIds(const std::vector<DeleteNetworkInterfacesRequest::std::string> &networkInterfaceIds) {
|
||||
networkInterfaceIds_ = networkInterfaceIds;
|
||||
for(int dep1 = 0; dep1 != networkInterfaceIds.size(); dep1++) {
|
||||
setParameter(std::string("NetworkInterfaceIds") + "." + std::to_string(dep1 + 1), networkInterfaceIds[dep1]);
|
||||
}
|
||||
}
|
||||
|
||||
44
ens/src/model/DeleteNetworkInterfacesResult.cc
Normal file
44
ens/src/model/DeleteNetworkInterfacesResult.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/ens/model/DeleteNetworkInterfacesResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ens;
|
||||
using namespace AlibabaCloud::Ens::Model;
|
||||
|
||||
DeleteNetworkInterfacesResult::DeleteNetworkInterfacesResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DeleteNetworkInterfacesResult::DeleteNetworkInterfacesResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DeleteNetworkInterfacesResult::~DeleteNetworkInterfacesResult()
|
||||
{}
|
||||
|
||||
void DeleteNetworkInterfacesResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
@@ -59,6 +59,8 @@ void DescribeDisksResult::parse(const std::string &payload)
|
||||
disksObject.instanceId = valueDisksDisksItem["InstanceId"].asString();
|
||||
if(!valueDisksDisksItem["InstanceName"].isNull())
|
||||
disksObject.instanceName = valueDisksDisksItem["InstanceName"].asString();
|
||||
if(!valueDisksDisksItem["Description"].isNull())
|
||||
disksObject.description = valueDisksDisksItem["Description"].asString();
|
||||
if(!valueDisksDisksItem["Size"].isNull())
|
||||
disksObject.size = std::stoi(valueDisksDisksItem["Size"].asString());
|
||||
if(!valueDisksDisksItem["Status"].isNull())
|
||||
@@ -75,6 +77,8 @@ void DescribeDisksResult::parse(const std::string &payload)
|
||||
disksObject.encrypted = valueDisksDisksItem["Encrypted"].asString() == "true";
|
||||
if(!valueDisksDisksItem["EncryptedKeyId"].isNull())
|
||||
disksObject.encryptedKeyId = valueDisksDisksItem["EncryptedKeyId"].asString();
|
||||
if(!valueDisksDisksItem["DeleteWithInstance"].isNull())
|
||||
disksObject.deleteWithInstance = valueDisksDisksItem["DeleteWithInstance"].asString() == "true";
|
||||
disks_.push_back(disksObject);
|
||||
}
|
||||
if(!value["Code"].isNull())
|
||||
|
||||
72
ens/src/model/DescribeEnsRouteTablesRequest.cc
Normal file
72
ens/src/model/DescribeEnsRouteTablesRequest.cc
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.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ens/model/DescribeEnsRouteTablesRequest.h>
|
||||
|
||||
using AlibabaCloud::Ens::Model::DescribeEnsRouteTablesRequest;
|
||||
|
||||
DescribeEnsRouteTablesRequest::DescribeEnsRouteTablesRequest()
|
||||
: RpcServiceRequest("ens", "2017-11-10", "DescribeEnsRouteTables") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DescribeEnsRouteTablesRequest::~DescribeEnsRouteTablesRequest() {}
|
||||
|
||||
int DescribeEnsRouteTablesRequest::getPageNumber() const {
|
||||
return pageNumber_;
|
||||
}
|
||||
|
||||
void DescribeEnsRouteTablesRequest::setPageNumber(int pageNumber) {
|
||||
pageNumber_ = pageNumber;
|
||||
setParameter(std::string("PageNumber"), std::to_string(pageNumber));
|
||||
}
|
||||
|
||||
int DescribeEnsRouteTablesRequest::getPageSize() const {
|
||||
return pageSize_;
|
||||
}
|
||||
|
||||
void DescribeEnsRouteTablesRequest::setPageSize(int pageSize) {
|
||||
pageSize_ = pageSize;
|
||||
setParameter(std::string("PageSize"), std::to_string(pageSize));
|
||||
}
|
||||
|
||||
std::string DescribeEnsRouteTablesRequest::getEnsRegionId() const {
|
||||
return ensRegionId_;
|
||||
}
|
||||
|
||||
void DescribeEnsRouteTablesRequest::setEnsRegionId(const std::string &ensRegionId) {
|
||||
ensRegionId_ = ensRegionId;
|
||||
setParameter(std::string("EnsRegionId"), ensRegionId);
|
||||
}
|
||||
|
||||
std::string DescribeEnsRouteTablesRequest::getRouteTableId() const {
|
||||
return routeTableId_;
|
||||
}
|
||||
|
||||
void DescribeEnsRouteTablesRequest::setRouteTableId(const std::string &routeTableId) {
|
||||
routeTableId_ = routeTableId;
|
||||
setParameter(std::string("RouteTableId"), routeTableId);
|
||||
}
|
||||
|
||||
std::string DescribeEnsRouteTablesRequest::getNetworkId() const {
|
||||
return networkId_;
|
||||
}
|
||||
|
||||
void DescribeEnsRouteTablesRequest::setNetworkId(const std::string &networkId) {
|
||||
networkId_ = networkId;
|
||||
setParameter(std::string("NetworkId"), networkId);
|
||||
}
|
||||
|
||||
95
ens/src/model/DescribeEnsRouteTablesResult.cc
Normal file
95
ens/src/model/DescribeEnsRouteTablesResult.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/ens/model/DescribeEnsRouteTablesResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ens;
|
||||
using namespace AlibabaCloud::Ens::Model;
|
||||
|
||||
DescribeEnsRouteTablesResult::DescribeEnsRouteTablesResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DescribeEnsRouteTablesResult::DescribeEnsRouteTablesResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DescribeEnsRouteTablesResult::~DescribeEnsRouteTablesResult()
|
||||
{}
|
||||
|
||||
void DescribeEnsRouteTablesResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allRouteTablesNode = value["RouteTables"]["RouteTable"];
|
||||
for (auto valueRouteTablesRouteTable : allRouteTablesNode)
|
||||
{
|
||||
RouteTable routeTablesObject;
|
||||
if(!valueRouteTablesRouteTable["CreationTime"].isNull())
|
||||
routeTablesObject.creationTime = valueRouteTablesRouteTable["CreationTime"].asString();
|
||||
if(!valueRouteTablesRouteTable["Status"].isNull())
|
||||
routeTablesObject.status = valueRouteTablesRouteTable["Status"].asString();
|
||||
if(!valueRouteTablesRouteTable["RouteTableId"].isNull())
|
||||
routeTablesObject.routeTableId = valueRouteTablesRouteTable["RouteTableId"].asString();
|
||||
if(!valueRouteTablesRouteTable["NetworkId"].isNull())
|
||||
routeTablesObject.networkId = valueRouteTablesRouteTable["NetworkId"].asString();
|
||||
if(!valueRouteTablesRouteTable["EnsRegionId"].isNull())
|
||||
routeTablesObject.ensRegionId = valueRouteTablesRouteTable["EnsRegionId"].asString();
|
||||
if(!valueRouteTablesRouteTable["Type"].isNull())
|
||||
routeTablesObject.type = valueRouteTablesRouteTable["Type"].asString();
|
||||
if(!valueRouteTablesRouteTable["RouteTableName"].isNull())
|
||||
routeTablesObject.routeTableName = valueRouteTablesRouteTable["RouteTableName"].asString();
|
||||
if(!valueRouteTablesRouteTable["NetworkName"].isNull())
|
||||
routeTablesObject.networkName = valueRouteTablesRouteTable["NetworkName"].asString();
|
||||
auto allVSwitchIds = value["VSwitchIds"]["VSwitch"];
|
||||
for (auto value : allVSwitchIds)
|
||||
routeTablesObject.vSwitchIds.push_back(value.asString());
|
||||
routeTables_.push_back(routeTablesObject);
|
||||
}
|
||||
if(!value["PageNumber"].isNull())
|
||||
pageNumber_ = std::stoi(value["PageNumber"].asString());
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = std::stoi(value["TotalCount"].asString());
|
||||
if(!value["PageSize"].isNull())
|
||||
pageSize_ = std::stoi(value["PageSize"].asString());
|
||||
|
||||
}
|
||||
|
||||
int DescribeEnsRouteTablesResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
int DescribeEnsRouteTablesResult::getPageSize()const
|
||||
{
|
||||
return pageSize_;
|
||||
}
|
||||
|
||||
int DescribeEnsRouteTablesResult::getPageNumber()const
|
||||
{
|
||||
return pageNumber_;
|
||||
}
|
||||
|
||||
std::vector<DescribeEnsRouteTablesResult::RouteTable> DescribeEnsRouteTablesResult::getRouteTables()const
|
||||
{
|
||||
return routeTables_;
|
||||
}
|
||||
|
||||
74
ens/src/model/DescribeInstanceSDGStatusRequest.cc
Normal file
74
ens/src/model/DescribeInstanceSDGStatusRequest.cc
Normal file
@@ -0,0 +1,74 @@
|
||||
/*
|
||||
* 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/ens/model/DescribeInstanceSDGStatusRequest.h>
|
||||
|
||||
using AlibabaCloud::Ens::Model::DescribeInstanceSDGStatusRequest;
|
||||
|
||||
DescribeInstanceSDGStatusRequest::DescribeInstanceSDGStatusRequest()
|
||||
: RpcServiceRequest("ens", "2017-11-10", "DescribeInstanceSDGStatus") {
|
||||
setMethod(HttpRequest::Method::Get);
|
||||
}
|
||||
|
||||
DescribeInstanceSDGStatusRequest::~DescribeInstanceSDGStatusRequest() {}
|
||||
|
||||
int DescribeInstanceSDGStatusRequest::getPageNumber() const {
|
||||
return pageNumber_;
|
||||
}
|
||||
|
||||
void DescribeInstanceSDGStatusRequest::setPageNumber(int pageNumber) {
|
||||
pageNumber_ = pageNumber;
|
||||
setParameter(std::string("PageNumber"), std::to_string(pageNumber));
|
||||
}
|
||||
|
||||
int DescribeInstanceSDGStatusRequest::getPageSize() const {
|
||||
return pageSize_;
|
||||
}
|
||||
|
||||
void DescribeInstanceSDGStatusRequest::setPageSize(int pageSize) {
|
||||
pageSize_ = pageSize;
|
||||
setParameter(std::string("PageSize"), std::to_string(pageSize));
|
||||
}
|
||||
|
||||
std::vector<DescribeInstanceSDGStatusRequest::std::string> DescribeInstanceSDGStatusRequest::getSDGIds() const {
|
||||
return sDGIds_;
|
||||
}
|
||||
|
||||
void DescribeInstanceSDGStatusRequest::setSDGIds(const std::vector<DescribeInstanceSDGStatusRequest::std::string> &sDGIds) {
|
||||
sDGIds_ = sDGIds;
|
||||
for(int dep1 = 0; dep1 != sDGIds.size(); dep1++) {
|
||||
setParameter(std::string("SDGIds") + "." + std::to_string(dep1 + 1), sDGIds[dep1]);
|
||||
}
|
||||
}
|
||||
|
||||
std::string DescribeInstanceSDGStatusRequest::getInstanceId() const {
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void DescribeInstanceSDGStatusRequest::setInstanceId(const std::string &instanceId) {
|
||||
instanceId_ = instanceId;
|
||||
setParameter(std::string("InstanceId"), instanceId);
|
||||
}
|
||||
|
||||
std::string DescribeInstanceSDGStatusRequest::getStatus() const {
|
||||
return status_;
|
||||
}
|
||||
|
||||
void DescribeInstanceSDGStatusRequest::setStatus(const std::string &status) {
|
||||
status_ = status;
|
||||
setParameter(std::string("Status"), status);
|
||||
}
|
||||
|
||||
90
ens/src/model/DescribeInstanceSDGStatusResult.cc
Normal file
90
ens/src/model/DescribeInstanceSDGStatusResult.cc
Normal file
@@ -0,0 +1,90 @@
|
||||
/*
|
||||
* 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/ens/model/DescribeInstanceSDGStatusResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ens;
|
||||
using namespace AlibabaCloud::Ens::Model;
|
||||
|
||||
DescribeInstanceSDGStatusResult::DescribeInstanceSDGStatusResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DescribeInstanceSDGStatusResult::DescribeInstanceSDGStatusResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DescribeInstanceSDGStatusResult::~DescribeInstanceSDGStatusResult()
|
||||
{}
|
||||
|
||||
void DescribeInstanceSDGStatusResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allDeploymentStatusNode = value["DeploymentStatus"]["DeploymentStatusItem"];
|
||||
for (auto valueDeploymentStatusDeploymentStatusItem : allDeploymentStatusNode)
|
||||
{
|
||||
DeploymentStatusItem deploymentStatusObject;
|
||||
if(!valueDeploymentStatusDeploymentStatusItem["InstanceId"].isNull())
|
||||
deploymentStatusObject.instanceId = valueDeploymentStatusDeploymentStatusItem["InstanceId"].asString();
|
||||
if(!valueDeploymentStatusDeploymentStatusItem["SDGId"].isNull())
|
||||
deploymentStatusObject.sDGId = valueDeploymentStatusDeploymentStatusItem["SDGId"].asString();
|
||||
if(!valueDeploymentStatusDeploymentStatusItem["MountType"].isNull())
|
||||
deploymentStatusObject.mountType = valueDeploymentStatusDeploymentStatusItem["MountType"].asString();
|
||||
if(!valueDeploymentStatusDeploymentStatusItem["EnsRegionId"].isNull())
|
||||
deploymentStatusObject.ensRegionId = valueDeploymentStatusDeploymentStatusItem["EnsRegionId"].asString();
|
||||
if(!valueDeploymentStatusDeploymentStatusItem["Status"].isNull())
|
||||
deploymentStatusObject.status = valueDeploymentStatusDeploymentStatusItem["Status"].asString();
|
||||
if(!valueDeploymentStatusDeploymentStatusItem["Phase"].isNull())
|
||||
deploymentStatusObject.phase = valueDeploymentStatusDeploymentStatusItem["Phase"].asString();
|
||||
if(!valueDeploymentStatusDeploymentStatusItem["UpdateTime"].isNull())
|
||||
deploymentStatusObject.updateTime = valueDeploymentStatusDeploymentStatusItem["UpdateTime"].asString();
|
||||
deploymentStatus_.push_back(deploymentStatusObject);
|
||||
}
|
||||
if(!value["PageNumber"].isNull())
|
||||
pageNumber_ = std::stol(value["PageNumber"].asString());
|
||||
if(!value["PageSize"].isNull())
|
||||
pageSize_ = value["PageSize"].asString();
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = value["TotalCount"].asString();
|
||||
|
||||
}
|
||||
|
||||
std::string DescribeInstanceSDGStatusResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
std::string DescribeInstanceSDGStatusResult::getPageSize()const
|
||||
{
|
||||
return pageSize_;
|
||||
}
|
||||
|
||||
long DescribeInstanceSDGStatusResult::getPageNumber()const
|
||||
{
|
||||
return pageNumber_;
|
||||
}
|
||||
|
||||
std::vector<DescribeInstanceSDGStatusResult::DeploymentStatusItem> DescribeInstanceSDGStatusResult::getDeploymentStatus()const
|
||||
{
|
||||
return deploymentStatus_;
|
||||
}
|
||||
|
||||
@@ -51,6 +51,8 @@ void DescribeSDGDeploymentStatusResult::parse(const std::string &payload)
|
||||
deploymentStatusObject.regionId = valueDeploymentStatusDeploymentStatusItem["RegionId"].asString();
|
||||
if(!valueDeploymentStatusDeploymentStatusItem["Status"].isNull())
|
||||
deploymentStatusObject.status = valueDeploymentStatusDeploymentStatusItem["Status"].asString();
|
||||
if(!valueDeploymentStatusDeploymentStatusItem["Phase"].isNull())
|
||||
deploymentStatusObject.phase = valueDeploymentStatusDeploymentStatusItem["Phase"].asString();
|
||||
if(!valueDeploymentStatusDeploymentStatusItem["UpdateTime"].isNull())
|
||||
deploymentStatusObject.updateTime = valueDeploymentStatusDeploymentStatusItem["UpdateTime"].asString();
|
||||
deploymentStatus_.push_back(deploymentStatusObject);
|
||||
|
||||
@@ -25,6 +25,24 @@ DescribeSnapshotsRequest::DescribeSnapshotsRequest()
|
||||
|
||||
DescribeSnapshotsRequest::~DescribeSnapshotsRequest() {}
|
||||
|
||||
std::string DescribeSnapshotsRequest::getEnsRegionId() const {
|
||||
return ensRegionId_;
|
||||
}
|
||||
|
||||
void DescribeSnapshotsRequest::setEnsRegionId(const std::string &ensRegionId) {
|
||||
ensRegionId_ = ensRegionId;
|
||||
setParameter(std::string("EnsRegionId"), ensRegionId);
|
||||
}
|
||||
|
||||
std::string DescribeSnapshotsRequest::getInstanceId() const {
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void DescribeSnapshotsRequest::setInstanceId(const std::string &instanceId) {
|
||||
instanceId_ = instanceId;
|
||||
setParameter(std::string("InstanceId"), instanceId);
|
||||
}
|
||||
|
||||
std::string DescribeSnapshotsRequest::getSnapshotId() const {
|
||||
return snapshotId_;
|
||||
}
|
||||
@@ -34,6 +52,15 @@ void DescribeSnapshotsRequest::setSnapshotId(const std::string &snapshotId) {
|
||||
setParameter(std::string("SnapshotId"), snapshotId);
|
||||
}
|
||||
|
||||
std::string DescribeSnapshotsRequest::getSnapshotName() const {
|
||||
return snapshotName_;
|
||||
}
|
||||
|
||||
void DescribeSnapshotsRequest::setSnapshotName(const std::string &snapshotName) {
|
||||
snapshotName_ = snapshotName;
|
||||
setParameter(std::string("SnapshotName"), snapshotName);
|
||||
}
|
||||
|
||||
int DescribeSnapshotsRequest::getPageNumber() const {
|
||||
return pageNumber_;
|
||||
}
|
||||
@@ -43,15 +70,6 @@ void DescribeSnapshotsRequest::setPageNumber(int pageNumber) {
|
||||
setParameter(std::string("PageNumber"), std::to_string(pageNumber));
|
||||
}
|
||||
|
||||
std::string DescribeSnapshotsRequest::getEnsRegionId() const {
|
||||
return ensRegionId_;
|
||||
}
|
||||
|
||||
void DescribeSnapshotsRequest::setEnsRegionId(const std::string &ensRegionId) {
|
||||
ensRegionId_ = ensRegionId;
|
||||
setParameter(std::string("EnsRegionId"), ensRegionId);
|
||||
}
|
||||
|
||||
int DescribeSnapshotsRequest::getPageSize() const {
|
||||
return pageSize_;
|
||||
}
|
||||
@@ -70,12 +88,12 @@ void DescribeSnapshotsRequest::setDiskId(const std::string &diskId) {
|
||||
setParameter(std::string("DiskId"), diskId);
|
||||
}
|
||||
|
||||
std::string DescribeSnapshotsRequest::getInstanceId() const {
|
||||
return instanceId_;
|
||||
std::string DescribeSnapshotsRequest::getEnsRegionIds() const {
|
||||
return ensRegionIds_;
|
||||
}
|
||||
|
||||
void DescribeSnapshotsRequest::setInstanceId(const std::string &instanceId) {
|
||||
instanceId_ = instanceId;
|
||||
setParameter(std::string("InstanceId"), instanceId);
|
||||
void DescribeSnapshotsRequest::setEnsRegionIds(const std::string &ensRegionIds) {
|
||||
ensRegionIds_ = ensRegionIds;
|
||||
setParameter(std::string("EnsRegionIds"), ensRegionIds);
|
||||
}
|
||||
|
||||
|
||||
47
ens/src/model/DetachInstanceSDGRequest.cc
Normal file
47
ens/src/model/DetachInstanceSDGRequest.cc
Normal file
@@ -0,0 +1,47 @@
|
||||
/*
|
||||
* 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/ens/model/DetachInstanceSDGRequest.h>
|
||||
|
||||
using AlibabaCloud::Ens::Model::DetachInstanceSDGRequest;
|
||||
|
||||
DetachInstanceSDGRequest::DetachInstanceSDGRequest()
|
||||
: RpcServiceRequest("ens", "2017-11-10", "DetachInstanceSDG") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DetachInstanceSDGRequest::~DetachInstanceSDGRequest() {}
|
||||
|
||||
std::string DetachInstanceSDGRequest::getSDGId() const {
|
||||
return sDGId_;
|
||||
}
|
||||
|
||||
void DetachInstanceSDGRequest::setSDGId(const std::string &sDGId) {
|
||||
sDGId_ = sDGId;
|
||||
setParameter(std::string("SDGId"), sDGId);
|
||||
}
|
||||
|
||||
std::vector<DetachInstanceSDGRequest::std::string> DetachInstanceSDGRequest::getInstanceIds() const {
|
||||
return instanceIds_;
|
||||
}
|
||||
|
||||
void DetachInstanceSDGRequest::setInstanceIds(const std::vector<DetachInstanceSDGRequest::std::string> &instanceIds) {
|
||||
instanceIds_ = instanceIds;
|
||||
for(int dep1 = 0; dep1 != instanceIds.size(); dep1++) {
|
||||
setParameter(std::string("InstanceIds") + "." + std::to_string(dep1 + 1), instanceIds[dep1]);
|
||||
}
|
||||
}
|
||||
|
||||
69
ens/src/model/DetachInstanceSDGResult.cc
Normal file
69
ens/src/model/DetachInstanceSDGResult.cc
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.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ens/model/DetachInstanceSDGResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ens;
|
||||
using namespace AlibabaCloud::Ens::Model;
|
||||
|
||||
DetachInstanceSDGResult::DetachInstanceSDGResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DetachInstanceSDGResult::DetachInstanceSDGResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DetachInstanceSDGResult::~DetachInstanceSDGResult()
|
||||
{}
|
||||
|
||||
void DetachInstanceSDGResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
if(!dataNode["Message"].isNull())
|
||||
data_.message = dataNode["Message"].asString();
|
||||
if(!dataNode["Success"].isNull())
|
||||
data_.success = dataNode["Success"].asString() == "true";
|
||||
auto resultNode = dataNode["Result"];
|
||||
if(!resultNode["FailedCount"].isNull())
|
||||
data_.result.failedCount = std::stol(resultNode["FailedCount"].asString());
|
||||
if(!resultNode["SuccessCount"].isNull())
|
||||
data_.result.successCount = resultNode["SuccessCount"].asString();
|
||||
auto allFailedItemsNode = resultNode["FailedItems"]["FailedItem"];
|
||||
for (auto resultNodeFailedItemsFailedItem : allFailedItemsNode)
|
||||
{
|
||||
Data::Result::FailedItem failedItemObject;
|
||||
if(!resultNodeFailedItemsFailedItem["ErrMessage"].isNull())
|
||||
failedItemObject.errMessage = resultNodeFailedItemsFailedItem["ErrMessage"].asString();
|
||||
if(!resultNodeFailedItemsFailedItem["InstanceId"].isNull())
|
||||
failedItemObject.instanceId = resultNodeFailedItemsFailedItem["InstanceId"].asString();
|
||||
data_.result.failedItems.push_back(failedItemObject);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
DetachInstanceSDGResult::Data DetachInstanceSDGResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
47
ens/src/model/MountInstanceSDGRequest.cc
Normal file
47
ens/src/model/MountInstanceSDGRequest.cc
Normal file
@@ -0,0 +1,47 @@
|
||||
/*
|
||||
* 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/ens/model/MountInstanceSDGRequest.h>
|
||||
|
||||
using AlibabaCloud::Ens::Model::MountInstanceSDGRequest;
|
||||
|
||||
MountInstanceSDGRequest::MountInstanceSDGRequest()
|
||||
: RpcServiceRequest("ens", "2017-11-10", "MountInstanceSDG") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
MountInstanceSDGRequest::~MountInstanceSDGRequest() {}
|
||||
|
||||
std::string MountInstanceSDGRequest::getSDGId() const {
|
||||
return sDGId_;
|
||||
}
|
||||
|
||||
void MountInstanceSDGRequest::setSDGId(const std::string &sDGId) {
|
||||
sDGId_ = sDGId;
|
||||
setParameter(std::string("SDGId"), sDGId);
|
||||
}
|
||||
|
||||
std::vector<MountInstanceSDGRequest::std::string> MountInstanceSDGRequest::getInstanceIds() const {
|
||||
return instanceIds_;
|
||||
}
|
||||
|
||||
void MountInstanceSDGRequest::setInstanceIds(const std::vector<MountInstanceSDGRequest::std::string> &instanceIds) {
|
||||
instanceIds_ = instanceIds;
|
||||
for(int dep1 = 0; dep1 != instanceIds.size(); dep1++) {
|
||||
setParameter(std::string("InstanceIds") + "." + std::to_string(dep1 + 1), instanceIds[dep1]);
|
||||
}
|
||||
}
|
||||
|
||||
69
ens/src/model/MountInstanceSDGResult.cc
Normal file
69
ens/src/model/MountInstanceSDGResult.cc
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.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ens/model/MountInstanceSDGResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ens;
|
||||
using namespace AlibabaCloud::Ens::Model;
|
||||
|
||||
MountInstanceSDGResult::MountInstanceSDGResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
MountInstanceSDGResult::MountInstanceSDGResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
MountInstanceSDGResult::~MountInstanceSDGResult()
|
||||
{}
|
||||
|
||||
void MountInstanceSDGResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
if(!dataNode["Message"].isNull())
|
||||
data_.message = dataNode["Message"].asString();
|
||||
if(!dataNode["Success"].isNull())
|
||||
data_.success = dataNode["Success"].asString() == "true";
|
||||
auto resultNode = dataNode["Result"];
|
||||
if(!resultNode["FailedCount"].isNull())
|
||||
data_.result.failedCount = std::stol(resultNode["FailedCount"].asString());
|
||||
if(!resultNode["SuccessCount"].isNull())
|
||||
data_.result.successCount = std::stol(resultNode["SuccessCount"].asString());
|
||||
auto allFailedItemsNode = resultNode["FailedItems"]["FailedItem"];
|
||||
for (auto resultNodeFailedItemsFailedItem : allFailedItemsNode)
|
||||
{
|
||||
Data::Result::FailedItem failedItemObject;
|
||||
if(!resultNodeFailedItemsFailedItem["ErrMessage"].isNull())
|
||||
failedItemObject.errMessage = resultNodeFailedItemsFailedItem["ErrMessage"].asString();
|
||||
if(!resultNodeFailedItemsFailedItem["InstanceId"].isNull())
|
||||
failedItemObject.instanceId = resultNodeFailedItemsFailedItem["InstanceId"].asString();
|
||||
data_.result.failedItems.push_back(failedItemObject);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
MountInstanceSDGResult::Data MountInstanceSDGResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
47
ens/src/model/UnmountInstanceSDGRequest.cc
Normal file
47
ens/src/model/UnmountInstanceSDGRequest.cc
Normal file
@@ -0,0 +1,47 @@
|
||||
/*
|
||||
* 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/ens/model/UnmountInstanceSDGRequest.h>
|
||||
|
||||
using AlibabaCloud::Ens::Model::UnmountInstanceSDGRequest;
|
||||
|
||||
UnmountInstanceSDGRequest::UnmountInstanceSDGRequest()
|
||||
: RpcServiceRequest("ens", "2017-11-10", "UnmountInstanceSDG") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
UnmountInstanceSDGRequest::~UnmountInstanceSDGRequest() {}
|
||||
|
||||
std::string UnmountInstanceSDGRequest::getSDGId() const {
|
||||
return sDGId_;
|
||||
}
|
||||
|
||||
void UnmountInstanceSDGRequest::setSDGId(const std::string &sDGId) {
|
||||
sDGId_ = sDGId;
|
||||
setParameter(std::string("SDGId"), sDGId);
|
||||
}
|
||||
|
||||
std::vector<UnmountInstanceSDGRequest::std::string> UnmountInstanceSDGRequest::getInstanceIds() const {
|
||||
return instanceIds_;
|
||||
}
|
||||
|
||||
void UnmountInstanceSDGRequest::setInstanceIds(const std::vector<UnmountInstanceSDGRequest::std::string> &instanceIds) {
|
||||
instanceIds_ = instanceIds;
|
||||
for(int dep1 = 0; dep1 != instanceIds.size(); dep1++) {
|
||||
setParameter(std::string("InstanceIds") + "." + std::to_string(dep1 + 1), instanceIds[dep1]);
|
||||
}
|
||||
}
|
||||
|
||||
69
ens/src/model/UnmountInstanceSDGResult.cc
Normal file
69
ens/src/model/UnmountInstanceSDGResult.cc
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.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/ens/model/UnmountInstanceSDGResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ens;
|
||||
using namespace AlibabaCloud::Ens::Model;
|
||||
|
||||
UnmountInstanceSDGResult::UnmountInstanceSDGResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
UnmountInstanceSDGResult::UnmountInstanceSDGResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
UnmountInstanceSDGResult::~UnmountInstanceSDGResult()
|
||||
{}
|
||||
|
||||
void UnmountInstanceSDGResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
if(!dataNode["Message"].isNull())
|
||||
data_.message = dataNode["Message"].asString();
|
||||
if(!dataNode["Success"].isNull())
|
||||
data_.success = dataNode["Success"].asString() == "true";
|
||||
auto resultNode = dataNode["Result"];
|
||||
if(!resultNode["FailedCount"].isNull())
|
||||
data_.result.failedCount = std::stol(resultNode["FailedCount"].asString());
|
||||
if(!resultNode["SuccessCount"].isNull())
|
||||
data_.result.successCount = std::stol(resultNode["SuccessCount"].asString());
|
||||
auto allFailedItemsNode = resultNode["FailedItems"]["FailedItem"];
|
||||
for (auto resultNodeFailedItemsFailedItem : allFailedItemsNode)
|
||||
{
|
||||
Data::Result::FailedItem failedItemObject;
|
||||
if(!resultNodeFailedItemsFailedItem["ErrMessage"].isNull())
|
||||
failedItemObject.errMessage = resultNodeFailedItemsFailedItem["ErrMessage"].asString();
|
||||
if(!resultNodeFailedItemsFailedItem["InstanceId"].isNull())
|
||||
failedItemObject.instanceId = resultNodeFailedItemsFailedItem["InstanceId"].asString();
|
||||
data_.result.failedItems.push_back(failedItemObject);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
UnmountInstanceSDGResult::Data UnmountInstanceSDGResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user