Compare commits

...

6 Commits

Author SHA1 Message Date
wb-hx510875
fb8fdd0c2f improve tests 2020-01-21 16:18:54 +08:00
sdk-team
4c2ebf13d5 Release on full language support. 2020-01-20 17:21:10 +08:00
wb-hx510875
b4e95dcd5a improve tests 2020-01-19 18:49:37 +08:00
wb-hx510875
38dab66f9d supported body parameter. 2020-01-19 15:55:33 +08:00
sdk-team
b452038de4 Supported Add the history event signature function. 2020-01-17 15:29:33 +08:00
sdk-team
f23788b801 Fix the result value of DeleteSiteMonitors. 2020-01-16 21:20:41 +08:00
64 changed files with 3510 additions and 55 deletions

View File

@@ -1,3 +1,12 @@
2020-01-20 Version 1.36.247
- Release on full language support.
2020-01-17 Version 1.36.246
- Supported Add the history event signature function.
2020-01-16 Version 1.36.245
- Fix the result value of DeleteSiteMonitors.
2020-01-16 Version 1.36.244
- Generated 2015-01-01 for `R-kvstore`.
- Update DescribeAvailableResource.

View File

@@ -1 +1 @@
1.36.244
1.36.247

View File

@@ -32,13 +32,17 @@ namespace AlibabaCloud
class ALIBABACLOUD_CMS_EXPORT DeleteSiteMonitorsResult : public ServiceResult
{
public:
struct Data
{
int count;
};
DeleteSiteMonitorsResult();
explicit DeleteSiteMonitorsResult(const std::string &payload);
~DeleteSiteMonitorsResult();
std::string getMessage()const;
std::string getData()const;
Data getData()const;
std::string getCode()const;
std::string getSuccess()const;
@@ -46,7 +50,7 @@ namespace AlibabaCloud
void parse(const std::string &payload);
private:
std::string message_;
std::string data_;
Data data_;
std::string code_;
std::string success_;

View File

@@ -44,16 +44,18 @@ namespace AlibabaCloud
std::string key;
};
std::string groupName;
long dynamicTagGroupId;
std::vector<Resource::ContactGroup> contactGroups;
std::string dynamicTagRuleId;
long gmtModified;
std::string groupFounderTagValue;
long groupId;
std::string serviceId;
std::string type;
long gmtCreate;
std::string bindUrl;
long gmtModified;
std::string groupFounderTagKey;
std::vector<std::string> templateIds;
std::vector<Resource::Tag> tags;
long groupId;
std::string serviceId;
};

View File

@@ -39,14 +39,15 @@ void DeleteSiteMonitorsResult::parse(const std::string &payload)
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto dataNode = value["Data"];
if(!dataNode["count"].isNull())
data_.count = std::stoi(dataNode["count"].asString());
if(!value["Code"].isNull())
code_ = value["Code"].asString();
if(!value["Message"].isNull())
message_ = value["Message"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString();
if(!value["Data"].isNull())
data_ = value["Data"].asString();
}
@@ -55,7 +56,7 @@ std::string DeleteSiteMonitorsResult::getMessage()const
return message_;
}
std::string DeleteSiteMonitorsResult::getData()const
DeleteSiteMonitorsResult::Data DeleteSiteMonitorsResult::getData()const
{
return data_;
}

View File

@@ -57,8 +57,12 @@ void DescribeMonitorGroupsResult::parse(const std::string &payload)
resourcesObject.gmtCreate = std::stol(valueResourcesResource["GmtCreate"].asString());
if(!valueResourcesResource["BindUrl"].isNull())
resourcesObject.bindUrl = valueResourcesResource["BindUrl"].asString();
if(!valueResourcesResource["DynamicTagGroupId"].isNull())
resourcesObject.dynamicTagGroupId = std::stol(valueResourcesResource["DynamicTagGroupId"].asString());
if(!valueResourcesResource["DynamicTagRuleId"].isNull())
resourcesObject.dynamicTagRuleId = valueResourcesResource["DynamicTagRuleId"].asString();
if(!valueResourcesResource["GroupFounderTagKey"].isNull())
resourcesObject.groupFounderTagKey = valueResourcesResource["GroupFounderTagKey"].asString();
if(!valueResourcesResource["GroupFounderTagValue"].isNull())
resourcesObject.groupFounderTagValue = valueResourcesResource["GroupFounderTagValue"].asString();
auto allContactGroupsNode = allResourcesNode["ContactGroups"]["ContactGroup"];
for (auto allResourcesNodeContactGroupsContactGroup : allContactGroupsNode)
{

View File

@@ -30,12 +30,18 @@ public:
typedef std::string ParameterValueType;
typedef std::map<ParameterNameType, ParameterValueType> ParameterCollection;
ServiceRequest(const std::string &product, const std::string &version);
ServiceRequest(const ServiceRequest &other);
ServiceRequest(ServiceRequest &&other);
ServiceRequest &operator=(const ServiceRequest &other);
ServiceRequest &operator=(ServiceRequest &&other);
virtual ~ServiceRequest();
const char *content() const;
size_t contentSize() const;
bool hasContent() const;
ParameterCollection parameters() const;
ParameterCollection bodyParameters() const;
std::string product() const;
std::string resourcePath() const;
std::string version() const;
@@ -50,14 +56,9 @@ public:
ParameterValueType getHeader(const ParameterNameType &name);
void removeHeader(const ParameterNameType &name);
ParameterCollection headers() const;
void setBodyParameter(const ParameterNameType &name, const ParameterValueType &value);
protected:
ServiceRequest(const std::string &product, const std::string &version);
ServiceRequest(const ServiceRequest &other);
ServiceRequest(ServiceRequest &&other);
ServiceRequest &operator=(const ServiceRequest &other);
ServiceRequest &operator=(ServiceRequest &&other);
void addParameter(const ParameterNameType &name,
const ParameterValueType &value);
ParameterValueType parameter(const ParameterNameType &name) const;
@@ -81,6 +82,7 @@ private:
char *content_;
size_t contentSize_;
ParameterCollection params_;
ParameterCollection body_params_;
ParameterCollection headers_;
std::string product_;
std::string resourcePath_;

View File

@@ -63,28 +63,33 @@ HttpRequest RpcServiceClient::buildHttpRequest(const std::string & endpoint,
const Credentials credentials = credentialsProvider_->getCredentials();
Url url;
if (msg.scheme().empty()) {
if (msg.scheme().empty())
{
url.setScheme("https");
} else {
}
else
{
url.setScheme(msg.scheme());
}
url.setHost(endpoint);
url.setPath(msg.resourcePath());
std::map<std::string, std::string> signParams;
auto params = msg.parameters();
std::map <std::string, std::string> queryParams;
for (const auto &p : params) {
for (const auto &p : params)
{
if (!p.second.empty())
queryParams[p.first] = p.second;
signParams[p.first] = p.second;
}
queryParams["AccessKeyId"] = credentials.accessKeyId();
queryParams["Format"] = "JSON";
queryParams["RegionId"] = configuration().regionId();
queryParams["SecurityToken"] = credentials.sessionToken();
queryParams["SignatureMethod"] = signer_->name();
queryParams["SignatureNonce"] = GenerateUuid();
queryParams["SignatureVersion"] = signer_->version();
signParams["AccessKeyId"] = credentials.accessKeyId();
signParams["Format"] = "JSON";
signParams["RegionId"] = configuration().regionId();
signParams["SecurityToken"] = credentials.sessionToken();
signParams["SignatureMethod"] = signer_->name();
signParams["SignatureNonce"] = GenerateUuid();
signParams["SignatureVersion"] = signer_->version();
std::time_t t = std::time(nullptr);
std::stringstream ss;
#if defined(__GNUG__) && __GNUC__ < 5
@@ -94,28 +99,42 @@ HttpRequest RpcServiceClient::buildHttpRequest(const std::string & endpoint,
#else
ss << std::put_time(std::gmtime(&t), "%FT%TZ");
#endif
queryParams["Timestamp"] = ss.str();
queryParams["Version"] = msg.version();
signParams["Timestamp"] = ss.str();
signParams["Version"] = msg.version();
std::map<std::string, std::string> query;
for (const auto &p : signParams)
{
query[p.first] = p.second;
}
auto body_params = msg.bodyParameters();
for (const auto &p : body_params)
{
signParams[p.first] = p.second;
}
std::stringstream plaintext;
plaintext << HttpMethodToString(method)
<< "&"
<< UrlEncode(url.path())
<< "&"
<< UrlEncode(canonicalizedQuery(queryParams));
queryParams["Signature"] = signer_->generate(plaintext.str(),
credentials.accessKeySecret() + "&");
<< "&"
<< UrlEncode(url.path())
<< "&"
<< UrlEncode(canonicalizedQuery(signParams));
query["Signature"] = signer_->generate(plaintext.str(),
credentials.accessKeySecret() + "&");
std::stringstream queryString;
for (const auto &p : queryParams)
for (const auto &p : query)
queryString << "&" << p.first << "=" << UrlEncode(p.second);
url.setQuery(queryString.str().substr(1));
HttpRequest request(url);
if (msg.connectTimeout() != kInvalidTimeout) {
if (msg.connectTimeout() != kInvalidTimeout)
{
request.setConnectTimeout(msg.connectTimeout());
} else {
}
else
{
request.setConnectTimeout(configuration().connectTimeout());
}
@@ -127,16 +146,26 @@ HttpRequest RpcServiceClient::buildHttpRequest(const std::string & endpoint,
}
}
if (msg.readTimeout() != kInvalidTimeout) {
if (msg.readTimeout() != kInvalidTimeout)
{
request.setReadTimeout(msg.readTimeout());
} else {
}
else
{
request.setReadTimeout(configuration().readTimeout());
}
request.setMethod(method);
request.setHeader("Host", url.host());
request.setHeader("x-sdk-client",
std::string("CPP/").append(ALIBABACLOUD_VERSION_STR));
std::string("CPP/").append(ALIBABACLOUD_VERSION_STR));
std::stringstream tmp;
for (const auto &p : body_params)
tmp << "&" << p.first << "=" << UrlEncode(p.second);
if(tmp.str().length() > 0){
std::string body = tmp.str().substr(1);
request.setBody(body.c_str(), body.length());
}
return request;
}

View File

@@ -137,6 +137,12 @@ ServiceRequest::ParameterCollection ServiceRequest::parameters() const
return params_;
}
ServiceRequest::ParameterCollection ServiceRequest::bodyParameters() const
{
return body_params_;
}
void ServiceRequest::removeParameter(const ParameterNameType &name)
{
params_.erase(name);
@@ -153,6 +159,11 @@ void ServiceRequest::setCoreParameter(const ParameterNameType &name, const Param
setParameter(name, value);
}
void ServiceRequest::setBodyParameter(const ParameterNameType &name, const ParameterValueType &value)
{
body_params_[name] = value;
}
void ServiceRequest::setParameters(const ParameterCollection &params)
{
params_ = params;
@@ -162,7 +173,7 @@ void ServiceRequest::setJsonParameters(const ParameterNameType &name, const Para
{
params_ = params;
params_ = params;
setCoreParameter(name, AlibabaCloud::MapToJson(params));
setParameter(name, AlibabaCloud::MapToJson(params));
}
std::string ServiceRequest::version() const

View File

@@ -235,11 +235,13 @@ std::string AlibabaCloud::GetEnv(const std::string env)
std::string AlibabaCloud::MapToJson(const std::map<std::string, std::string> &maps)
{
Json::Value jsonObject;
Json::FastWriter writer;
for (std::map<std::string, std::string>::const_iterator iter = maps.begin(); iter != maps.end(); ++iter)
{
jsonObject[iter->first] = iter->second;
}
return jsonObject.toStyledString();
std::string unformat_str = writer.write(jsonObject);
return unformat_str.substr(0, unformat_str.length() - 1);
}
std::map<std::string, std::string> AlibabaCloud::JsonToMap(const std::string &json)

View File

@@ -0,0 +1,86 @@
#
# 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.
#
set(public_header_dir ${CMAKE_CURRENT_SOURCE_DIR}/../include)
set(hiknoengine_public_header
include/alibabacloud/hiknoengine/HiknoengineClient.h
include/alibabacloud/hiknoengine/HiknoengineExport.h )
set(hiknoengine_public_header_model
include/alibabacloud/hiknoengine/model/TranslateTextRequest.h
include/alibabacloud/hiknoengine/model/TranslateTextResult.h )
set(hiknoengine_src
src/HiknoengineClient.cc
src/model/TranslateTextRequest.cc
src/model/TranslateTextResult.cc )
add_library(hiknoengine ${LIB_TYPE}
${hiknoengine_public_header}
${hiknoengine_public_header_model}
${hiknoengine_src})
set_target_properties(hiknoengine
PROPERTIES
LINKER_LANGUAGE CXX
ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
OUTPUT_NAME ${TARGET_OUTPUT_NAME_PREFIX}hiknoengine
)
if(${LIB_TYPE} STREQUAL "SHARED")
set_target_properties(hiknoengine
PROPERTIES
DEFINE_SYMBOL ALIBABACLOUD_HIKNOENGINE_LIBRARY)
endif()
target_include_directories(hiknoengine
PRIVATE include
${CMAKE_SOURCE_DIR}/core/include
)
target_link_libraries(hiknoengine
core)
if(CMAKE_HOST_WIN32)
ExternalProject_Get_Property(jsoncpp INSTALL_DIR)
set(jsoncpp_install_dir ${INSTALL_DIR})
add_dependencies(hiknoengine
jsoncpp)
target_include_directories(hiknoengine
PRIVATE ${jsoncpp_install_dir}/include)
target_link_libraries(hiknoengine
${jsoncpp_install_dir}/lib/jsoncpp.lib)
set_target_properties(hiknoengine
PROPERTIES
COMPILE_OPTIONS "/bigobj")
else()
target_include_directories(hiknoengine
PRIVATE /usr/include/jsoncpp)
target_link_libraries(hiknoengine
jsoncpp)
endif()
install(FILES ${hiknoengine_public_header}
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/hiknoengine)
install(FILES ${hiknoengine_public_header_model}
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/hiknoengine/model)
install(TARGETS hiknoengine
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
)

View File

@@ -0,0 +1,54 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_HIKNOENGINE_HIKNOENGINECLIENT_H_
#define ALIBABACLOUD_HIKNOENGINE_HIKNOENGINECLIENT_H_
#include <future>
#include <alibabacloud/core/AsyncCallerContext.h>
#include <alibabacloud/core/EndpointProvider.h>
#include <alibabacloud/core/RpcServiceClient.h>
#include "HiknoengineExport.h"
#include "model/TranslateTextRequest.h"
#include "model/TranslateTextResult.h"
namespace AlibabaCloud
{
namespace Hiknoengine
{
class ALIBABACLOUD_HIKNOENGINE_EXPORT HiknoengineClient : public RpcServiceClient
{
public:
typedef Outcome<Error, Model::TranslateTextResult> TranslateTextOutcome;
typedef std::future<TranslateTextOutcome> TranslateTextOutcomeCallable;
typedef std::function<void(const HiknoengineClient*, const Model::TranslateTextRequest&, const TranslateTextOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> TranslateTextAsyncHandler;
HiknoengineClient(const Credentials &credentials, const ClientConfiguration &configuration);
HiknoengineClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider, const ClientConfiguration &configuration);
HiknoengineClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration);
~HiknoengineClient();
TranslateTextOutcome translateText(const Model::TranslateTextRequest &request)const;
void translateTextAsync(const Model::TranslateTextRequest& request, const TranslateTextAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
TranslateTextOutcomeCallable translateTextCallable(const Model::TranslateTextRequest& request) const;
private:
std::shared_ptr<EndpointProvider> endpointProvider_;
};
}
}
#endif // !ALIBABACLOUD_HIKNOENGINE_HIKNOENGINECLIENT_H_

View File

@@ -0,0 +1,32 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_HIKNOENGINE_HIKNOENGINEEXPORT_H_
#define ALIBABACLOUD_HIKNOENGINE_HIKNOENGINEEXPORT_H_
#include <alibabacloud/core/Global.h>
#if defined(ALIBABACLOUD_SHARED)
# if defined(ALIBABACLOUD_HIKNOENGINE_LIBRARY)
# define ALIBABACLOUD_HIKNOENGINE_EXPORT ALIBABACLOUD_DECL_EXPORT
# else
# define ALIBABACLOUD_HIKNOENGINE_EXPORT ALIBABACLOUD_DECL_IMPORT
# endif
#else
# define ALIBABACLOUD_HIKNOENGINE_EXPORT
#endif
#endif // !ALIBABACLOUD_HIKNOENGINE_HIKNOENGINEEXPORT_H_

View File

@@ -0,0 +1,54 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_HIKNOENGINE_MODEL_TRANSLATETEXTREQUEST_H_
#define ALIBABACLOUD_HIKNOENGINE_MODEL_TRANSLATETEXTREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/hiknoengine/HiknoengineExport.h>
namespace AlibabaCloud
{
namespace Hiknoengine
{
namespace Model
{
class ALIBABACLOUD_HIKNOENGINE_EXPORT TranslateTextRequest : public RpcServiceRequest
{
public:
TranslateTextRequest();
~TranslateTextRequest();
std::string getFromLang()const;
void setFromLang(const std::string& fromLang);
std::string getToLang()const;
void setToLang(const std::string& toLang);
std::string getText()const;
void setText(const std::string& text);
private:
std::string fromLang_;
std::string toLang_;
std::string text_;
};
}
}
}
#endif // !ALIBABACLOUD_HIKNOENGINE_MODEL_TRANSLATETEXTREQUEST_H_

View File

@@ -0,0 +1,59 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_HIKNOENGINE_MODEL_TRANSLATETEXTRESULT_H_
#define ALIBABACLOUD_HIKNOENGINE_MODEL_TRANSLATETEXTRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/hiknoengine/HiknoengineExport.h>
namespace AlibabaCloud
{
namespace Hiknoengine
{
namespace Model
{
class ALIBABACLOUD_HIKNOENGINE_EXPORT TranslateTextResult : public ServiceResult
{
public:
struct Data
{
std::string text;
};
TranslateTextResult();
explicit TranslateTextResult(const std::string &payload);
~TranslateTextResult();
std::string getMessage()const;
Data getData()const;
std::string getCode()const;
protected:
void parse(const std::string &payload);
private:
std::string message_;
Data data_;
std::string code_;
};
}
}
}
#endif // !ALIBABACLOUD_HIKNOENGINE_MODEL_TRANSLATETEXTRESULT_H_

View File

@@ -0,0 +1,89 @@
/*
* 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/hiknoengine/HiknoengineClient.h>
#include <alibabacloud/core/SimpleCredentialsProvider.h>
using namespace AlibabaCloud;
using namespace AlibabaCloud::Location;
using namespace AlibabaCloud::Hiknoengine;
using namespace AlibabaCloud::Hiknoengine::Model;
namespace
{
const std::string SERVICE_NAME = "hiknoengine";
}
HiknoengineClient::HiknoengineClient(const Credentials &credentials, const ClientConfiguration &configuration) :
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(credentials), configuration)
{
auto locationClient = std::make_shared<LocationClient>(credentials, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "hiknoengine");
}
HiknoengineClient::HiknoengineClient(const std::shared_ptr<CredentialsProvider>& credentialsProvider, const ClientConfiguration & configuration) :
RpcServiceClient(SERVICE_NAME, credentialsProvider, configuration)
{
auto locationClient = std::make_shared<LocationClient>(credentialsProvider, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "hiknoengine");
}
HiknoengineClient::HiknoengineClient(const std::string & accessKeyId, const std::string & accessKeySecret, const ClientConfiguration & configuration) :
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(accessKeyId, accessKeySecret), configuration)
{
auto locationClient = std::make_shared<LocationClient>(accessKeyId, accessKeySecret, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "hiknoengine");
}
HiknoengineClient::~HiknoengineClient()
{}
HiknoengineClient::TranslateTextOutcome HiknoengineClient::translateText(const TranslateTextRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return TranslateTextOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return TranslateTextOutcome(TranslateTextResult(outcome.result()));
else
return TranslateTextOutcome(outcome.error());
}
void HiknoengineClient::translateTextAsync(const TranslateTextRequest& request, const TranslateTextAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, translateText(request), context);
};
asyncExecute(new Runnable(fn));
}
HiknoengineClient::TranslateTextOutcomeCallable HiknoengineClient::translateTextCallable(const TranslateTextRequest &request) const
{
auto task = std::make_shared<std::packaged_task<TranslateTextOutcome()>>(
[this, request]()
{
return this->translateText(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}

View File

@@ -0,0 +1,62 @@
/*
* 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/hiknoengine/model/TranslateTextRequest.h>
using AlibabaCloud::Hiknoengine::Model::TranslateTextRequest;
TranslateTextRequest::TranslateTextRequest() :
RpcServiceRequest("hiknoengine", "2019-06-25", "TranslateText")
{
setMethod(HttpRequest::Method::Post);
}
TranslateTextRequest::~TranslateTextRequest()
{}
std::string TranslateTextRequest::getFromLang()const
{
return fromLang_;
}
void TranslateTextRequest::setFromLang(const std::string& fromLang)
{
fromLang_ = fromLang;
setCoreParameter("FromLang", fromLang);
}
std::string TranslateTextRequest::getToLang()const
{
return toLang_;
}
void TranslateTextRequest::setToLang(const std::string& toLang)
{
toLang_ = toLang;
setCoreParameter("ToLang", toLang);
}
std::string TranslateTextRequest::getText()const
{
return text_;
}
void TranslateTextRequest::setText(const std::string& text)
{
text_ = text;
setCoreParameter("Text", text);
}

View File

@@ -0,0 +1,66 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/hiknoengine/model/TranslateTextResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Hiknoengine;
using namespace AlibabaCloud::Hiknoengine::Model;
TranslateTextResult::TranslateTextResult() :
ServiceResult()
{}
TranslateTextResult::TranslateTextResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
TranslateTextResult::~TranslateTextResult()
{}
void TranslateTextResult::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["Text"].isNull())
data_.text = dataNode["Text"].asString();
if(!value["Code"].isNull())
code_ = value["Code"].asString();
if(!value["Message"].isNull())
message_ = value["Message"].asString();
}
std::string TranslateTextResult::getMessage()const
{
return message_;
}
TranslateTextResult::Data TranslateTextResult::getData()const
{
return data_;
}
std::string TranslateTextResult::getCode()const
{
return code_;
}

View File

@@ -163,6 +163,8 @@ set(rds_public_header_model
include/alibabacloud/rds/model/DescribeDBInstancesByPerformanceResult.h
include/alibabacloud/rds/model/DescribeDBInstancesForCloneRequest.h
include/alibabacloud/rds/model/DescribeDBInstancesForCloneResult.h
include/alibabacloud/rds/model/DescribeDBInstancesOverviewRequest.h
include/alibabacloud/rds/model/DescribeDBInstancesOverviewResult.h
include/alibabacloud/rds/model/DescribeDBProxyRequest.h
include/alibabacloud/rds/model/DescribeDBProxyResult.h
include/alibabacloud/rds/model/DescribeDBProxyEndpointRequest.h
@@ -203,6 +205,8 @@ set(rds_public_header_model
include/alibabacloud/rds/model/DescribeMigrateTasksForSQLServerResult.h
include/alibabacloud/rds/model/DescribeModifyParameterLogRequest.h
include/alibabacloud/rds/model/DescribeModifyParameterLogResult.h
include/alibabacloud/rds/model/DescribeNextEventForSignRequest.h
include/alibabacloud/rds/model/DescribeNextEventForSignResult.h
include/alibabacloud/rds/model/DescribeOssDownloadsRequest.h
include/alibabacloud/rds/model/DescribeOssDownloadsResult.h
include/alibabacloud/rds/model/DescribeOssDownloadsForSQLServerRequest.h
@@ -225,6 +229,10 @@ set(rds_public_header_model
include/alibabacloud/rds/model/DescribeRenewalPriceResult.h
include/alibabacloud/rds/model/DescribeResourceUsageRequest.h
include/alibabacloud/rds/model/DescribeResourceUsageResult.h
include/alibabacloud/rds/model/DescribeSQLCollectorPolicyRequest.h
include/alibabacloud/rds/model/DescribeSQLCollectorPolicyResult.h
include/alibabacloud/rds/model/DescribeSQLCollectorRetentionRequest.h
include/alibabacloud/rds/model/DescribeSQLCollectorRetentionResult.h
include/alibabacloud/rds/model/DescribeSQLLogFilesRequest.h
include/alibabacloud/rds/model/DescribeSQLLogFilesResult.h
include/alibabacloud/rds/model/DescribeSQLLogRecordsRequest.h
@@ -237,6 +245,8 @@ set(rds_public_header_model
include/alibabacloud/rds/model/DescribeSQLReportsResult.h
include/alibabacloud/rds/model/DescribeSecurityGroupConfigurationRequest.h
include/alibabacloud/rds/model/DescribeSecurityGroupConfigurationResult.h
include/alibabacloud/rds/model/DescribeSignedEventActionsRequest.h
include/alibabacloud/rds/model/DescribeSignedEventActionsResult.h
include/alibabacloud/rds/model/DescribeSlowLogRecordsRequest.h
include/alibabacloud/rds/model/DescribeSlowLogRecordsResult.h
include/alibabacloud/rds/model/DescribeSlowLogsRequest.h
@@ -269,6 +279,8 @@ set(rds_public_header_model
include/alibabacloud/rds/model/ModifyAccountDescriptionResult.h
include/alibabacloud/rds/model/ModifyActionEventPolicyRequest.h
include/alibabacloud/rds/model/ModifyActionEventPolicyResult.h
include/alibabacloud/rds/model/ModifyActionEventVerifyPolicyRequest.h
include/alibabacloud/rds/model/ModifyActionEventVerifyPolicyResult.h
include/alibabacloud/rds/model/ModifyBackupPolicyRequest.h
include/alibabacloud/rds/model/ModifyBackupPolicyResult.h
include/alibabacloud/rds/model/ModifyCollationTimeZoneRequest.h
@@ -335,6 +347,8 @@ set(rds_public_header_model
include/alibabacloud/rds/model/ModifyResourceGroupResult.h
include/alibabacloud/rds/model/ModifySQLCollectorPolicyRequest.h
include/alibabacloud/rds/model/ModifySQLCollectorPolicyResult.h
include/alibabacloud/rds/model/ModifySQLCollectorRetentionRequest.h
include/alibabacloud/rds/model/ModifySQLCollectorRetentionResult.h
include/alibabacloud/rds/model/ModifySecurityGroupConfigurationRequest.h
include/alibabacloud/rds/model/ModifySecurityGroupConfigurationResult.h
include/alibabacloud/rds/model/ModifySecurityIpsRequest.h
@@ -375,6 +389,8 @@ set(rds_public_header_model
include/alibabacloud/rds/model/RevokeAccountPrivilegeResult.h
include/alibabacloud/rds/model/RevokeOperatorPermissionRequest.h
include/alibabacloud/rds/model/RevokeOperatorPermissionResult.h
include/alibabacloud/rds/model/SignEventActionRequest.h
include/alibabacloud/rds/model/SignEventActionResult.h
include/alibabacloud/rds/model/SwitchDBInstanceHARequest.h
include/alibabacloud/rds/model/SwitchDBInstanceHAResult.h
include/alibabacloud/rds/model/SwitchDBInstanceNetTypeRequest.h
@@ -536,6 +552,8 @@ set(rds_src
src/model/DescribeDBInstancesByPerformanceResult.cc
src/model/DescribeDBInstancesForCloneRequest.cc
src/model/DescribeDBInstancesForCloneResult.cc
src/model/DescribeDBInstancesOverviewRequest.cc
src/model/DescribeDBInstancesOverviewResult.cc
src/model/DescribeDBProxyRequest.cc
src/model/DescribeDBProxyResult.cc
src/model/DescribeDBProxyEndpointRequest.cc
@@ -576,6 +594,8 @@ set(rds_src
src/model/DescribeMigrateTasksForSQLServerResult.cc
src/model/DescribeModifyParameterLogRequest.cc
src/model/DescribeModifyParameterLogResult.cc
src/model/DescribeNextEventForSignRequest.cc
src/model/DescribeNextEventForSignResult.cc
src/model/DescribeOssDownloadsRequest.cc
src/model/DescribeOssDownloadsResult.cc
src/model/DescribeOssDownloadsForSQLServerRequest.cc
@@ -598,6 +618,10 @@ set(rds_src
src/model/DescribeRenewalPriceResult.cc
src/model/DescribeResourceUsageRequest.cc
src/model/DescribeResourceUsageResult.cc
src/model/DescribeSQLCollectorPolicyRequest.cc
src/model/DescribeSQLCollectorPolicyResult.cc
src/model/DescribeSQLCollectorRetentionRequest.cc
src/model/DescribeSQLCollectorRetentionResult.cc
src/model/DescribeSQLLogFilesRequest.cc
src/model/DescribeSQLLogFilesResult.cc
src/model/DescribeSQLLogRecordsRequest.cc
@@ -610,6 +634,8 @@ set(rds_src
src/model/DescribeSQLReportsResult.cc
src/model/DescribeSecurityGroupConfigurationRequest.cc
src/model/DescribeSecurityGroupConfigurationResult.cc
src/model/DescribeSignedEventActionsRequest.cc
src/model/DescribeSignedEventActionsResult.cc
src/model/DescribeSlowLogRecordsRequest.cc
src/model/DescribeSlowLogRecordsResult.cc
src/model/DescribeSlowLogsRequest.cc
@@ -642,6 +668,8 @@ set(rds_src
src/model/ModifyAccountDescriptionResult.cc
src/model/ModifyActionEventPolicyRequest.cc
src/model/ModifyActionEventPolicyResult.cc
src/model/ModifyActionEventVerifyPolicyRequest.cc
src/model/ModifyActionEventVerifyPolicyResult.cc
src/model/ModifyBackupPolicyRequest.cc
src/model/ModifyBackupPolicyResult.cc
src/model/ModifyCollationTimeZoneRequest.cc
@@ -708,6 +736,8 @@ set(rds_src
src/model/ModifyResourceGroupResult.cc
src/model/ModifySQLCollectorPolicyRequest.cc
src/model/ModifySQLCollectorPolicyResult.cc
src/model/ModifySQLCollectorRetentionRequest.cc
src/model/ModifySQLCollectorRetentionResult.cc
src/model/ModifySecurityGroupConfigurationRequest.cc
src/model/ModifySecurityGroupConfigurationResult.cc
src/model/ModifySecurityIpsRequest.cc
@@ -748,6 +778,8 @@ set(rds_src
src/model/RevokeAccountPrivilegeResult.cc
src/model/RevokeOperatorPermissionRequest.cc
src/model/RevokeOperatorPermissionResult.cc
src/model/SignEventActionRequest.cc
src/model/SignEventActionResult.cc
src/model/SwitchDBInstanceHARequest.cc
src/model/SwitchDBInstanceHAResult.cc
src/model/SwitchDBInstanceNetTypeRequest.cc

View File

@@ -164,6 +164,8 @@
#include "model/DescribeDBInstancesByPerformanceResult.h"
#include "model/DescribeDBInstancesForCloneRequest.h"
#include "model/DescribeDBInstancesForCloneResult.h"
#include "model/DescribeDBInstancesOverviewRequest.h"
#include "model/DescribeDBInstancesOverviewResult.h"
#include "model/DescribeDBProxyRequest.h"
#include "model/DescribeDBProxyResult.h"
#include "model/DescribeDBProxyEndpointRequest.h"
@@ -204,6 +206,8 @@
#include "model/DescribeMigrateTasksForSQLServerResult.h"
#include "model/DescribeModifyParameterLogRequest.h"
#include "model/DescribeModifyParameterLogResult.h"
#include "model/DescribeNextEventForSignRequest.h"
#include "model/DescribeNextEventForSignResult.h"
#include "model/DescribeOssDownloadsRequest.h"
#include "model/DescribeOssDownloadsResult.h"
#include "model/DescribeOssDownloadsForSQLServerRequest.h"
@@ -226,6 +230,10 @@
#include "model/DescribeRenewalPriceResult.h"
#include "model/DescribeResourceUsageRequest.h"
#include "model/DescribeResourceUsageResult.h"
#include "model/DescribeSQLCollectorPolicyRequest.h"
#include "model/DescribeSQLCollectorPolicyResult.h"
#include "model/DescribeSQLCollectorRetentionRequest.h"
#include "model/DescribeSQLCollectorRetentionResult.h"
#include "model/DescribeSQLLogFilesRequest.h"
#include "model/DescribeSQLLogFilesResult.h"
#include "model/DescribeSQLLogRecordsRequest.h"
@@ -238,6 +246,8 @@
#include "model/DescribeSQLReportsResult.h"
#include "model/DescribeSecurityGroupConfigurationRequest.h"
#include "model/DescribeSecurityGroupConfigurationResult.h"
#include "model/DescribeSignedEventActionsRequest.h"
#include "model/DescribeSignedEventActionsResult.h"
#include "model/DescribeSlowLogRecordsRequest.h"
#include "model/DescribeSlowLogRecordsResult.h"
#include "model/DescribeSlowLogsRequest.h"
@@ -270,6 +280,8 @@
#include "model/ModifyAccountDescriptionResult.h"
#include "model/ModifyActionEventPolicyRequest.h"
#include "model/ModifyActionEventPolicyResult.h"
#include "model/ModifyActionEventVerifyPolicyRequest.h"
#include "model/ModifyActionEventVerifyPolicyResult.h"
#include "model/ModifyBackupPolicyRequest.h"
#include "model/ModifyBackupPolicyResult.h"
#include "model/ModifyCollationTimeZoneRequest.h"
@@ -336,6 +348,8 @@
#include "model/ModifyResourceGroupResult.h"
#include "model/ModifySQLCollectorPolicyRequest.h"
#include "model/ModifySQLCollectorPolicyResult.h"
#include "model/ModifySQLCollectorRetentionRequest.h"
#include "model/ModifySQLCollectorRetentionResult.h"
#include "model/ModifySecurityGroupConfigurationRequest.h"
#include "model/ModifySecurityGroupConfigurationResult.h"
#include "model/ModifySecurityIpsRequest.h"
@@ -376,6 +390,8 @@
#include "model/RevokeAccountPrivilegeResult.h"
#include "model/RevokeOperatorPermissionRequest.h"
#include "model/RevokeOperatorPermissionResult.h"
#include "model/SignEventActionRequest.h"
#include "model/SignEventActionResult.h"
#include "model/SwitchDBInstanceHARequest.h"
#include "model/SwitchDBInstanceHAResult.h"
#include "model/SwitchDBInstanceNetTypeRequest.h"
@@ -614,6 +630,9 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::DescribeDBInstancesForCloneResult> DescribeDBInstancesForCloneOutcome;
typedef std::future<DescribeDBInstancesForCloneOutcome> DescribeDBInstancesForCloneOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeDBInstancesForCloneRequest&, const DescribeDBInstancesForCloneOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeDBInstancesForCloneAsyncHandler;
typedef Outcome<Error, Model::DescribeDBInstancesOverviewResult> DescribeDBInstancesOverviewOutcome;
typedef std::future<DescribeDBInstancesOverviewOutcome> DescribeDBInstancesOverviewOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeDBInstancesOverviewRequest&, const DescribeDBInstancesOverviewOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeDBInstancesOverviewAsyncHandler;
typedef Outcome<Error, Model::DescribeDBProxyResult> DescribeDBProxyOutcome;
typedef std::future<DescribeDBProxyOutcome> DescribeDBProxyOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeDBProxyRequest&, const DescribeDBProxyOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeDBProxyAsyncHandler;
@@ -674,6 +693,9 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::DescribeModifyParameterLogResult> DescribeModifyParameterLogOutcome;
typedef std::future<DescribeModifyParameterLogOutcome> DescribeModifyParameterLogOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeModifyParameterLogRequest&, const DescribeModifyParameterLogOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeModifyParameterLogAsyncHandler;
typedef Outcome<Error, Model::DescribeNextEventForSignResult> DescribeNextEventForSignOutcome;
typedef std::future<DescribeNextEventForSignOutcome> DescribeNextEventForSignOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeNextEventForSignRequest&, const DescribeNextEventForSignOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeNextEventForSignAsyncHandler;
typedef Outcome<Error, Model::DescribeOssDownloadsResult> DescribeOssDownloadsOutcome;
typedef std::future<DescribeOssDownloadsOutcome> DescribeOssDownloadsOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeOssDownloadsRequest&, const DescribeOssDownloadsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeOssDownloadsAsyncHandler;
@@ -707,6 +729,12 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::DescribeResourceUsageResult> DescribeResourceUsageOutcome;
typedef std::future<DescribeResourceUsageOutcome> DescribeResourceUsageOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeResourceUsageRequest&, const DescribeResourceUsageOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeResourceUsageAsyncHandler;
typedef Outcome<Error, Model::DescribeSQLCollectorPolicyResult> DescribeSQLCollectorPolicyOutcome;
typedef std::future<DescribeSQLCollectorPolicyOutcome> DescribeSQLCollectorPolicyOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeSQLCollectorPolicyRequest&, const DescribeSQLCollectorPolicyOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeSQLCollectorPolicyAsyncHandler;
typedef Outcome<Error, Model::DescribeSQLCollectorRetentionResult> DescribeSQLCollectorRetentionOutcome;
typedef std::future<DescribeSQLCollectorRetentionOutcome> DescribeSQLCollectorRetentionOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeSQLCollectorRetentionRequest&, const DescribeSQLCollectorRetentionOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeSQLCollectorRetentionAsyncHandler;
typedef Outcome<Error, Model::DescribeSQLLogFilesResult> DescribeSQLLogFilesOutcome;
typedef std::future<DescribeSQLLogFilesOutcome> DescribeSQLLogFilesOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeSQLLogFilesRequest&, const DescribeSQLLogFilesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeSQLLogFilesAsyncHandler;
@@ -725,6 +753,9 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::DescribeSecurityGroupConfigurationResult> DescribeSecurityGroupConfigurationOutcome;
typedef std::future<DescribeSecurityGroupConfigurationOutcome> DescribeSecurityGroupConfigurationOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeSecurityGroupConfigurationRequest&, const DescribeSecurityGroupConfigurationOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeSecurityGroupConfigurationAsyncHandler;
typedef Outcome<Error, Model::DescribeSignedEventActionsResult> DescribeSignedEventActionsOutcome;
typedef std::future<DescribeSignedEventActionsOutcome> DescribeSignedEventActionsOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeSignedEventActionsRequest&, const DescribeSignedEventActionsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeSignedEventActionsAsyncHandler;
typedef Outcome<Error, Model::DescribeSlowLogRecordsResult> DescribeSlowLogRecordsOutcome;
typedef std::future<DescribeSlowLogRecordsOutcome> DescribeSlowLogRecordsOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::DescribeSlowLogRecordsRequest&, const DescribeSlowLogRecordsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeSlowLogRecordsAsyncHandler;
@@ -773,6 +804,9 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::ModifyActionEventPolicyResult> ModifyActionEventPolicyOutcome;
typedef std::future<ModifyActionEventPolicyOutcome> ModifyActionEventPolicyOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::ModifyActionEventPolicyRequest&, const ModifyActionEventPolicyOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ModifyActionEventPolicyAsyncHandler;
typedef Outcome<Error, Model::ModifyActionEventVerifyPolicyResult> ModifyActionEventVerifyPolicyOutcome;
typedef std::future<ModifyActionEventVerifyPolicyOutcome> ModifyActionEventVerifyPolicyOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::ModifyActionEventVerifyPolicyRequest&, const ModifyActionEventVerifyPolicyOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ModifyActionEventVerifyPolicyAsyncHandler;
typedef Outcome<Error, Model::ModifyBackupPolicyResult> ModifyBackupPolicyOutcome;
typedef std::future<ModifyBackupPolicyOutcome> ModifyBackupPolicyOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::ModifyBackupPolicyRequest&, const ModifyBackupPolicyOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ModifyBackupPolicyAsyncHandler;
@@ -872,6 +906,9 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::ModifySQLCollectorPolicyResult> ModifySQLCollectorPolicyOutcome;
typedef std::future<ModifySQLCollectorPolicyOutcome> ModifySQLCollectorPolicyOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::ModifySQLCollectorPolicyRequest&, const ModifySQLCollectorPolicyOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ModifySQLCollectorPolicyAsyncHandler;
typedef Outcome<Error, Model::ModifySQLCollectorRetentionResult> ModifySQLCollectorRetentionOutcome;
typedef std::future<ModifySQLCollectorRetentionOutcome> ModifySQLCollectorRetentionOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::ModifySQLCollectorRetentionRequest&, const ModifySQLCollectorRetentionOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ModifySQLCollectorRetentionAsyncHandler;
typedef Outcome<Error, Model::ModifySecurityGroupConfigurationResult> ModifySecurityGroupConfigurationOutcome;
typedef std::future<ModifySecurityGroupConfigurationOutcome> ModifySecurityGroupConfigurationOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::ModifySecurityGroupConfigurationRequest&, const ModifySecurityGroupConfigurationOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ModifySecurityGroupConfigurationAsyncHandler;
@@ -932,6 +969,9 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::RevokeOperatorPermissionResult> RevokeOperatorPermissionOutcome;
typedef std::future<RevokeOperatorPermissionOutcome> RevokeOperatorPermissionOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::RevokeOperatorPermissionRequest&, const RevokeOperatorPermissionOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RevokeOperatorPermissionAsyncHandler;
typedef Outcome<Error, Model::SignEventActionResult> SignEventActionOutcome;
typedef std::future<SignEventActionOutcome> SignEventActionOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::SignEventActionRequest&, const SignEventActionOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> SignEventActionAsyncHandler;
typedef Outcome<Error, Model::SwitchDBInstanceHAResult> SwitchDBInstanceHAOutcome;
typedef std::future<SwitchDBInstanceHAOutcome> SwitchDBInstanceHAOutcomeCallable;
typedef std::function<void(const RdsClient*, const Model::SwitchDBInstanceHARequest&, const SwitchDBInstanceHAOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> SwitchDBInstanceHAAsyncHandler;
@@ -1174,6 +1214,9 @@ namespace AlibabaCloud
DescribeDBInstancesForCloneOutcome describeDBInstancesForClone(const Model::DescribeDBInstancesForCloneRequest &request)const;
void describeDBInstancesForCloneAsync(const Model::DescribeDBInstancesForCloneRequest& request, const DescribeDBInstancesForCloneAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeDBInstancesForCloneOutcomeCallable describeDBInstancesForCloneCallable(const Model::DescribeDBInstancesForCloneRequest& request) const;
DescribeDBInstancesOverviewOutcome describeDBInstancesOverview(const Model::DescribeDBInstancesOverviewRequest &request)const;
void describeDBInstancesOverviewAsync(const Model::DescribeDBInstancesOverviewRequest& request, const DescribeDBInstancesOverviewAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeDBInstancesOverviewOutcomeCallable describeDBInstancesOverviewCallable(const Model::DescribeDBInstancesOverviewRequest& request) const;
DescribeDBProxyOutcome describeDBProxy(const Model::DescribeDBProxyRequest &request)const;
void describeDBProxyAsync(const Model::DescribeDBProxyRequest& request, const DescribeDBProxyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeDBProxyOutcomeCallable describeDBProxyCallable(const Model::DescribeDBProxyRequest& request) const;
@@ -1234,6 +1277,9 @@ namespace AlibabaCloud
DescribeModifyParameterLogOutcome describeModifyParameterLog(const Model::DescribeModifyParameterLogRequest &request)const;
void describeModifyParameterLogAsync(const Model::DescribeModifyParameterLogRequest& request, const DescribeModifyParameterLogAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeModifyParameterLogOutcomeCallable describeModifyParameterLogCallable(const Model::DescribeModifyParameterLogRequest& request) const;
DescribeNextEventForSignOutcome describeNextEventForSign(const Model::DescribeNextEventForSignRequest &request)const;
void describeNextEventForSignAsync(const Model::DescribeNextEventForSignRequest& request, const DescribeNextEventForSignAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeNextEventForSignOutcomeCallable describeNextEventForSignCallable(const Model::DescribeNextEventForSignRequest& request) const;
DescribeOssDownloadsOutcome describeOssDownloads(const Model::DescribeOssDownloadsRequest &request)const;
void describeOssDownloadsAsync(const Model::DescribeOssDownloadsRequest& request, const DescribeOssDownloadsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeOssDownloadsOutcomeCallable describeOssDownloadsCallable(const Model::DescribeOssDownloadsRequest& request) const;
@@ -1267,6 +1313,12 @@ namespace AlibabaCloud
DescribeResourceUsageOutcome describeResourceUsage(const Model::DescribeResourceUsageRequest &request)const;
void describeResourceUsageAsync(const Model::DescribeResourceUsageRequest& request, const DescribeResourceUsageAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeResourceUsageOutcomeCallable describeResourceUsageCallable(const Model::DescribeResourceUsageRequest& request) const;
DescribeSQLCollectorPolicyOutcome describeSQLCollectorPolicy(const Model::DescribeSQLCollectorPolicyRequest &request)const;
void describeSQLCollectorPolicyAsync(const Model::DescribeSQLCollectorPolicyRequest& request, const DescribeSQLCollectorPolicyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeSQLCollectorPolicyOutcomeCallable describeSQLCollectorPolicyCallable(const Model::DescribeSQLCollectorPolicyRequest& request) const;
DescribeSQLCollectorRetentionOutcome describeSQLCollectorRetention(const Model::DescribeSQLCollectorRetentionRequest &request)const;
void describeSQLCollectorRetentionAsync(const Model::DescribeSQLCollectorRetentionRequest& request, const DescribeSQLCollectorRetentionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeSQLCollectorRetentionOutcomeCallable describeSQLCollectorRetentionCallable(const Model::DescribeSQLCollectorRetentionRequest& request) const;
DescribeSQLLogFilesOutcome describeSQLLogFiles(const Model::DescribeSQLLogFilesRequest &request)const;
void describeSQLLogFilesAsync(const Model::DescribeSQLLogFilesRequest& request, const DescribeSQLLogFilesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeSQLLogFilesOutcomeCallable describeSQLLogFilesCallable(const Model::DescribeSQLLogFilesRequest& request) const;
@@ -1285,6 +1337,9 @@ namespace AlibabaCloud
DescribeSecurityGroupConfigurationOutcome describeSecurityGroupConfiguration(const Model::DescribeSecurityGroupConfigurationRequest &request)const;
void describeSecurityGroupConfigurationAsync(const Model::DescribeSecurityGroupConfigurationRequest& request, const DescribeSecurityGroupConfigurationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeSecurityGroupConfigurationOutcomeCallable describeSecurityGroupConfigurationCallable(const Model::DescribeSecurityGroupConfigurationRequest& request) const;
DescribeSignedEventActionsOutcome describeSignedEventActions(const Model::DescribeSignedEventActionsRequest &request)const;
void describeSignedEventActionsAsync(const Model::DescribeSignedEventActionsRequest& request, const DescribeSignedEventActionsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeSignedEventActionsOutcomeCallable describeSignedEventActionsCallable(const Model::DescribeSignedEventActionsRequest& request) const;
DescribeSlowLogRecordsOutcome describeSlowLogRecords(const Model::DescribeSlowLogRecordsRequest &request)const;
void describeSlowLogRecordsAsync(const Model::DescribeSlowLogRecordsRequest& request, const DescribeSlowLogRecordsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeSlowLogRecordsOutcomeCallable describeSlowLogRecordsCallable(const Model::DescribeSlowLogRecordsRequest& request) const;
@@ -1333,6 +1388,9 @@ namespace AlibabaCloud
ModifyActionEventPolicyOutcome modifyActionEventPolicy(const Model::ModifyActionEventPolicyRequest &request)const;
void modifyActionEventPolicyAsync(const Model::ModifyActionEventPolicyRequest& request, const ModifyActionEventPolicyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ModifyActionEventPolicyOutcomeCallable modifyActionEventPolicyCallable(const Model::ModifyActionEventPolicyRequest& request) const;
ModifyActionEventVerifyPolicyOutcome modifyActionEventVerifyPolicy(const Model::ModifyActionEventVerifyPolicyRequest &request)const;
void modifyActionEventVerifyPolicyAsync(const Model::ModifyActionEventVerifyPolicyRequest& request, const ModifyActionEventVerifyPolicyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ModifyActionEventVerifyPolicyOutcomeCallable modifyActionEventVerifyPolicyCallable(const Model::ModifyActionEventVerifyPolicyRequest& request) const;
ModifyBackupPolicyOutcome modifyBackupPolicy(const Model::ModifyBackupPolicyRequest &request)const;
void modifyBackupPolicyAsync(const Model::ModifyBackupPolicyRequest& request, const ModifyBackupPolicyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ModifyBackupPolicyOutcomeCallable modifyBackupPolicyCallable(const Model::ModifyBackupPolicyRequest& request) const;
@@ -1432,6 +1490,9 @@ namespace AlibabaCloud
ModifySQLCollectorPolicyOutcome modifySQLCollectorPolicy(const Model::ModifySQLCollectorPolicyRequest &request)const;
void modifySQLCollectorPolicyAsync(const Model::ModifySQLCollectorPolicyRequest& request, const ModifySQLCollectorPolicyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ModifySQLCollectorPolicyOutcomeCallable modifySQLCollectorPolicyCallable(const Model::ModifySQLCollectorPolicyRequest& request) const;
ModifySQLCollectorRetentionOutcome modifySQLCollectorRetention(const Model::ModifySQLCollectorRetentionRequest &request)const;
void modifySQLCollectorRetentionAsync(const Model::ModifySQLCollectorRetentionRequest& request, const ModifySQLCollectorRetentionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ModifySQLCollectorRetentionOutcomeCallable modifySQLCollectorRetentionCallable(const Model::ModifySQLCollectorRetentionRequest& request) const;
ModifySecurityGroupConfigurationOutcome modifySecurityGroupConfiguration(const Model::ModifySecurityGroupConfigurationRequest &request)const;
void modifySecurityGroupConfigurationAsync(const Model::ModifySecurityGroupConfigurationRequest& request, const ModifySecurityGroupConfigurationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ModifySecurityGroupConfigurationOutcomeCallable modifySecurityGroupConfigurationCallable(const Model::ModifySecurityGroupConfigurationRequest& request) const;
@@ -1492,6 +1553,9 @@ namespace AlibabaCloud
RevokeOperatorPermissionOutcome revokeOperatorPermission(const Model::RevokeOperatorPermissionRequest &request)const;
void revokeOperatorPermissionAsync(const Model::RevokeOperatorPermissionRequest& request, const RevokeOperatorPermissionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
RevokeOperatorPermissionOutcomeCallable revokeOperatorPermissionCallable(const Model::RevokeOperatorPermissionRequest& request) const;
SignEventActionOutcome signEventAction(const Model::SignEventActionRequest &request)const;
void signEventActionAsync(const Model::SignEventActionRequest& request, const SignEventActionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
SignEventActionOutcomeCallable signEventActionCallable(const Model::SignEventActionRequest& request) const;
SwitchDBInstanceHAOutcome switchDBInstanceHA(const Model::SwitchDBInstanceHARequest &request)const;
void switchDBInstanceHAAsync(const Model::SwitchDBInstanceHARequest& request, const SwitchDBInstanceHAAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
SwitchDBInstanceHAOutcomeCallable switchDBInstanceHACallable(const Model::SwitchDBInstanceHARequest& request) const;

View File

@@ -53,6 +53,8 @@ namespace AlibabaCloud
void setEndTime(const std::string& endTime);
long getOwnerId()const;
void setOwnerId(long ownerId);
bool getUseNullWhenMissingPoint()const;
void setUseNullWhenMissingPoint(bool useNullWhenMissingPoint);
private:
long resourceOwnerId_;
@@ -64,6 +66,7 @@ namespace AlibabaCloud
std::string ownerAccount_;
std::string endTime_;
long ownerId_;
bool useNullWhenMissingPoint_;
};
}

View File

@@ -57,6 +57,8 @@ namespace AlibabaCloud
void setEngine(const std::string& engine);
std::string getRegionId()const;
void setRegionId(const std::string& regionId);
std::string getCurrentInstanceId()const;
void setCurrentInstanceId(const std::string& currentInstanceId);
int getPageSize()const;
void setPageSize(int pageSize);
std::string getDBInstanceStatus()const;
@@ -98,6 +100,7 @@ namespace AlibabaCloud
std::string expired_;
std::string engine_;
std::string regionId_;
std::string currentInstanceId_;
int pageSize_;
std::string dBInstanceStatus_;
std::string dBInstanceId_;

View File

@@ -0,0 +1,78 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_DESCRIBEDBINSTANCESOVERVIEWREQUEST_H_
#define ALIBABACLOUD_RDS_MODEL_DESCRIBEDBINSTANCESOVERVIEWREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT DescribeDBInstancesOverviewRequest : public RpcServiceRequest
{
public:
DescribeDBInstancesOverviewRequest();
~DescribeDBInstancesOverviewRequest();
long getResourceOwnerId()const;
void setResourceOwnerId(long resourceOwnerId);
std::string getClientToken()const;
void setClientToken(const std::string& clientToken);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getExpired()const;
void setExpired(const std::string& expired);
std::string getEngine()const;
void setEngine(const std::string& engine);
std::string getRegionId()const;
void setRegionId(const std::string& regionId);
std::string getDBInstanceId()const;
void setDBInstanceId(const std::string& dBInstanceId);
std::string getProxyId()const;
void setProxyId(const std::string& proxyId);
std::string getResourceOwnerAccount()const;
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getZoneId()const;
void setZoneId(const std::string& zoneId);
private:
long resourceOwnerId_;
std::string clientToken_;
std::string accessKeyId_;
std::string expired_;
std::string engine_;
std::string regionId_;
std::string dBInstanceId_;
std::string proxyId_;
std::string resourceOwnerAccount_;
long ownerId_;
std::string zoneId_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_DESCRIBEDBINSTANCESOVERVIEWREQUEST_H_

View File

@@ -0,0 +1,76 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_DESCRIBEDBINSTANCESOVERVIEWRESULT_H_
#define ALIBABACLOUD_RDS_MODEL_DESCRIBEDBINSTANCESOVERVIEWRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT DescribeDBInstancesOverviewResult : public ServiceResult
{
public:
struct RegionModel
{
struct TypeModel
{
struct InstanceModel
{
std::string createdTime;
std::string zoneId;
std::string dBInstanceStatus;
std::string dBInstanceId;
std::string region;
std::string payType;
std::string lockMode;
std::string expireTime;
std::string engine;
};
std::vector<TypeModel::InstanceModel> instanceModels;
int count;
std::string instanceDateType;
};
int totalCount;
std::string region;
std::vector<RegionModel::TypeModel> typeModels;
std::string engineCount;
};
DescribeDBInstancesOverviewResult();
explicit DescribeDBInstancesOverviewResult(const std::string &payload);
~DescribeDBInstancesOverviewResult();
std::vector<RegionModel> getRegions()const;
protected:
void parse(const std::string &payload);
private:
std::vector<RegionModel> regions_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_DESCRIBEDBINSTANCESOVERVIEWRESULT_H_

View File

@@ -0,0 +1,60 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_DESCRIBENEXTEVENTFORSIGNREQUEST_H_
#define ALIBABACLOUD_RDS_MODEL_DESCRIBENEXTEVENTFORSIGNREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT DescribeNextEventForSignRequest : public RpcServiceRequest
{
public:
DescribeNextEventForSignRequest();
~DescribeNextEventForSignRequest();
long getResourceOwnerId()const;
void setResourceOwnerId(long resourceOwnerId);
std::string getResourceOwnerAccount()const;
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getRegionId()const;
void setRegionId(const std::string& regionId);
private:
long resourceOwnerId_;
std::string resourceOwnerAccount_;
long ownerId_;
std::string accessKeyId_;
std::string regionId_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_DESCRIBENEXTEVENTFORSIGNREQUEST_H_

View File

@@ -0,0 +1,56 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_DESCRIBENEXTEVENTFORSIGNRESULT_H_
#define ALIBABACLOUD_RDS_MODEL_DESCRIBENEXTEVENTFORSIGNRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT DescribeNextEventForSignResult : public ServiceResult
{
public:
struct EventItemsItem
{
int eventId;
std::string eventContent;
};
DescribeNextEventForSignResult();
explicit DescribeNextEventForSignResult(const std::string &payload);
~DescribeNextEventForSignResult();
std::vector<EventItemsItem> getEventItems()const;
protected:
void parse(const std::string &payload);
private:
std::vector<EventItemsItem> eventItems_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_DESCRIBENEXTEVENTFORSIGNRESULT_H_

View File

@@ -0,0 +1,66 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORPOLICYREQUEST_H_
#define ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORPOLICYREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT DescribeSQLCollectorPolicyRequest : public RpcServiceRequest
{
public:
DescribeSQLCollectorPolicyRequest();
~DescribeSQLCollectorPolicyRequest();
long getResourceOwnerId()const;
void setResourceOwnerId(long resourceOwnerId);
std::string getResourceOwnerAccount()const;
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
std::string getClientToken()const;
void setClientToken(const std::string& clientToken);
std::string getOwnerAccount()const;
void setOwnerAccount(const std::string& ownerAccount);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getDBInstanceId()const;
void setDBInstanceId(const std::string& dBInstanceId);
private:
long resourceOwnerId_;
std::string resourceOwnerAccount_;
std::string clientToken_;
std::string ownerAccount_;
long ownerId_;
std::string accessKeyId_;
std::string dBInstanceId_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORPOLICYREQUEST_H_

View File

@@ -0,0 +1,53 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORPOLICYRESULT_H_
#define ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORPOLICYRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT DescribeSQLCollectorPolicyResult : public ServiceResult
{
public:
DescribeSQLCollectorPolicyResult();
explicit DescribeSQLCollectorPolicyResult(const std::string &payload);
~DescribeSQLCollectorPolicyResult();
int getStoragePeriod()const;
std::string getSQLCollectorStatus()const;
protected:
void parse(const std::string &payload);
private:
int storagePeriod_;
std::string sQLCollectorStatus_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORPOLICYRESULT_H_

View File

@@ -0,0 +1,66 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORRETENTIONREQUEST_H_
#define ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORRETENTIONREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT DescribeSQLCollectorRetentionRequest : public RpcServiceRequest
{
public:
DescribeSQLCollectorRetentionRequest();
~DescribeSQLCollectorRetentionRequest();
long getResourceOwnerId()const;
void setResourceOwnerId(long resourceOwnerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getDBInstanceId()const;
void setDBInstanceId(const std::string& dBInstanceId);
std::string getResourceOwnerAccount()const;
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
std::string getOwnerAccount()const;
void setOwnerAccount(const std::string& ownerAccount);
long getOwnerId()const;
void setOwnerId(long ownerId);
private:
long resourceOwnerId_;
std::string accessKeyId_;
std::string securityToken_;
std::string dBInstanceId_;
std::string resourceOwnerAccount_;
std::string ownerAccount_;
long ownerId_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORRETENTIONREQUEST_H_

View File

@@ -0,0 +1,55 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORRETENTIONRESULT_H_
#define ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORRETENTIONRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT DescribeSQLCollectorRetentionResult : public ServiceResult
{
public:
DescribeSQLCollectorRetentionResult();
explicit DescribeSQLCollectorRetentionResult(const std::string &payload);
~DescribeSQLCollectorRetentionResult();
std::string getConfigValue()const;
int getDBInstanceID()const;
std::string getDBInstanceName()const;
protected:
void parse(const std::string &payload);
private:
std::string configValue_;
int dBInstanceID_;
std::string dBInstanceName_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_DESCRIBESQLCOLLECTORRETENTIONRESULT_H_

View File

@@ -0,0 +1,66 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_DESCRIBESIGNEDEVENTACTIONSREQUEST_H_
#define ALIBABACLOUD_RDS_MODEL_DESCRIBESIGNEDEVENTACTIONSREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT DescribeSignedEventActionsRequest : public RpcServiceRequest
{
public:
DescribeSignedEventActionsRequest();
~DescribeSignedEventActionsRequest();
long getResourceOwnerId()const;
void setResourceOwnerId(long resourceOwnerId);
int getBeginEventId()const;
void setBeginEventId(int beginEventId);
std::string getResourceOwnerAccount()const;
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getRegionId()const;
void setRegionId(const std::string& regionId);
int getPageSize()const;
void setPageSize(int pageSize);
private:
long resourceOwnerId_;
int beginEventId_;
std::string resourceOwnerAccount_;
long ownerId_;
std::string accessKeyId_;
std::string regionId_;
int pageSize_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_DESCRIBESIGNEDEVENTACTIONSREQUEST_H_

View File

@@ -0,0 +1,66 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_DESCRIBESIGNEDEVENTACTIONSRESULT_H_
#define ALIBABACLOUD_RDS_MODEL_DESCRIBESIGNEDEVENTACTIONSRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT DescribeSignedEventActionsResult : public ServiceResult
{
public:
struct EventItemsItem
{
int eventId;
std::string eventContent;
std::string eventSig;
std::string eventRcpt;
};
DescribeSignedEventActionsResult();
explicit DescribeSignedEventActionsResult(const std::string &payload);
~DescribeSignedEventActionsResult();
std::vector<EventItemsItem> getEventItems()const;
int getPageRecordCount()const;
bool getToEnd()const;
bool getFromBegin()const;
int getNextPageEventId()const;
protected:
void parse(const std::string &payload);
private:
std::vector<EventItemsItem> eventItems_;
int pageRecordCount_;
bool toEnd_;
bool fromBegin_;
int nextPageEventId_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_DESCRIBESIGNEDEVENTACTIONSRESULT_H_

View File

@@ -0,0 +1,63 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_MODIFYACTIONEVENTVERIFYPOLICYREQUEST_H_
#define ALIBABACLOUD_RDS_MODEL_MODIFYACTIONEVENTVERIFYPOLICYREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT ModifyActionEventVerifyPolicyRequest : public RpcServiceRequest
{
public:
ModifyActionEventVerifyPolicyRequest();
~ModifyActionEventVerifyPolicyRequest();
long getResourceOwnerId()const;
void setResourceOwnerId(long resourceOwnerId);
std::string getResourceOwnerAccount()const;
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getRegionId()const;
void setRegionId(const std::string& regionId);
std::string getUserPublicKey()const;
void setUserPublicKey(const std::string& userPublicKey);
private:
long resourceOwnerId_;
std::string resourceOwnerAccount_;
long ownerId_;
std::string accessKeyId_;
std::string regionId_;
std::string userPublicKey_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_MODIFYACTIONEVENTVERIFYPOLICYREQUEST_H_

View File

@@ -0,0 +1,53 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_MODIFYACTIONEVENTVERIFYPOLICYRESULT_H_
#define ALIBABACLOUD_RDS_MODEL_MODIFYACTIONEVENTVERIFYPOLICYRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT ModifyActionEventVerifyPolicyResult : public ServiceResult
{
public:
ModifyActionEventVerifyPolicyResult();
explicit ModifyActionEventVerifyPolicyResult(const std::string &payload);
~ModifyActionEventVerifyPolicyResult();
std::string getRegionId()const;
std::string getServerPublicKey()const;
protected:
void parse(const std::string &payload);
private:
std::string regionId_;
std::string serverPublicKey_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_MODIFYACTIONEVENTVERIFYPOLICYRESULT_H_

View File

@@ -51,6 +51,8 @@ namespace AlibabaCloud
void setDBInstanceId(const std::string& dBInstanceId);
std::string getDBInstanceStorageType()const;
void setDBInstanceStorageType(const std::string& dBInstanceStorageType);
std::string getSourceBiz()const;
void setSourceBiz(const std::string& sourceBiz);
std::string getDirection()const;
void setDirection(const std::string& direction);
std::string getResourceOwnerAccount()const;
@@ -73,6 +75,7 @@ namespace AlibabaCloud
std::string effectiveTime_;
std::string dBInstanceId_;
std::string dBInstanceStorageType_;
std::string sourceBiz_;
std::string direction_;
std::string resourceOwnerAccount_;
std::string ownerAccount_;

View File

@@ -0,0 +1,69 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_MODIFYSQLCOLLECTORRETENTIONREQUEST_H_
#define ALIBABACLOUD_RDS_MODEL_MODIFYSQLCOLLECTORRETENTIONREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT ModifySQLCollectorRetentionRequest : public RpcServiceRequest
{
public:
ModifySQLCollectorRetentionRequest();
~ModifySQLCollectorRetentionRequest();
long getResourceOwnerId()const;
void setResourceOwnerId(long resourceOwnerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getDBInstanceId()const;
void setDBInstanceId(const std::string& dBInstanceId);
std::string getResourceOwnerAccount()const;
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
std::string getOwnerAccount()const;
void setOwnerAccount(const std::string& ownerAccount);
std::string getConfigValue()const;
void setConfigValue(const std::string& configValue);
long getOwnerId()const;
void setOwnerId(long ownerId);
private:
long resourceOwnerId_;
std::string accessKeyId_;
std::string securityToken_;
std::string dBInstanceId_;
std::string resourceOwnerAccount_;
std::string ownerAccount_;
std::string configValue_;
long ownerId_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_MODIFYSQLCOLLECTORRETENTIONREQUEST_H_

View File

@@ -0,0 +1,55 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_MODIFYSQLCOLLECTORRETENTIONRESULT_H_
#define ALIBABACLOUD_RDS_MODEL_MODIFYSQLCOLLECTORRETENTIONRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT ModifySQLCollectorRetentionResult : public ServiceResult
{
public:
ModifySQLCollectorRetentionResult();
explicit ModifySQLCollectorRetentionResult(const std::string &payload);
~ModifySQLCollectorRetentionResult();
int getTaskId()const;
int getDBInstanceID()const;
std::string getDBInstanceName()const;
protected:
void parse(const std::string &payload);
private:
int taskId_;
int dBInstanceID_;
std::string dBInstanceName_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_MODIFYSQLCOLLECTORRETENTIONRESULT_H_

View File

@@ -0,0 +1,66 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_SIGNEVENTACTIONREQUEST_H_
#define ALIBABACLOUD_RDS_MODEL_SIGNEVENTACTIONREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT SignEventActionRequest : public RpcServiceRequest
{
public:
SignEventActionRequest();
~SignEventActionRequest();
int getEventId()const;
void setEventId(int eventId);
long getResourceOwnerId()const;
void setResourceOwnerId(long resourceOwnerId);
std::string getEventSig()const;
void setEventSig(const std::string& eventSig);
std::string getResourceOwnerAccount()const;
void setResourceOwnerAccount(const std::string& resourceOwnerAccount);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getRegionId()const;
void setRegionId(const std::string& regionId);
private:
int eventId_;
long resourceOwnerId_;
std::string eventSig_;
std::string resourceOwnerAccount_;
long ownerId_;
std::string accessKeyId_;
std::string regionId_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_SIGNEVENTACTIONREQUEST_H_

View File

@@ -0,0 +1,53 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_RDS_MODEL_SIGNEVENTACTIONRESULT_H_
#define ALIBABACLOUD_RDS_MODEL_SIGNEVENTACTIONRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/rds/RdsExport.h>
namespace AlibabaCloud
{
namespace Rds
{
namespace Model
{
class ALIBABACLOUD_RDS_EXPORT SignEventActionResult : public ServiceResult
{
public:
SignEventActionResult();
explicit SignEventActionResult(const std::string &payload);
~SignEventActionResult();
std::string getEventId()const;
std::string getEventRcpt()const;
protected:
void parse(const std::string &payload);
private:
std::string eventId_;
std::string eventRcpt_;
};
}
}
}
#endif // !ALIBABACLOUD_RDS_MODEL_SIGNEVENTACTIONRESULT_H_

View File

@@ -2607,6 +2607,42 @@ RdsClient::DescribeDBInstancesForCloneOutcomeCallable RdsClient::describeDBInsta
return task->get_future();
}
RdsClient::DescribeDBInstancesOverviewOutcome RdsClient::describeDBInstancesOverview(const DescribeDBInstancesOverviewRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeDBInstancesOverviewOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeDBInstancesOverviewOutcome(DescribeDBInstancesOverviewResult(outcome.result()));
else
return DescribeDBInstancesOverviewOutcome(outcome.error());
}
void RdsClient::describeDBInstancesOverviewAsync(const DescribeDBInstancesOverviewRequest& request, const DescribeDBInstancesOverviewAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeDBInstancesOverview(request), context);
};
asyncExecute(new Runnable(fn));
}
RdsClient::DescribeDBInstancesOverviewOutcomeCallable RdsClient::describeDBInstancesOverviewCallable(const DescribeDBInstancesOverviewRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeDBInstancesOverviewOutcome()>>(
[this, request]()
{
return this->describeDBInstancesOverview(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
RdsClient::DescribeDBProxyOutcome RdsClient::describeDBProxy(const DescribeDBProxyRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -3327,6 +3363,42 @@ RdsClient::DescribeModifyParameterLogOutcomeCallable RdsClient::describeModifyPa
return task->get_future();
}
RdsClient::DescribeNextEventForSignOutcome RdsClient::describeNextEventForSign(const DescribeNextEventForSignRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeNextEventForSignOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeNextEventForSignOutcome(DescribeNextEventForSignResult(outcome.result()));
else
return DescribeNextEventForSignOutcome(outcome.error());
}
void RdsClient::describeNextEventForSignAsync(const DescribeNextEventForSignRequest& request, const DescribeNextEventForSignAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeNextEventForSign(request), context);
};
asyncExecute(new Runnable(fn));
}
RdsClient::DescribeNextEventForSignOutcomeCallable RdsClient::describeNextEventForSignCallable(const DescribeNextEventForSignRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeNextEventForSignOutcome()>>(
[this, request]()
{
return this->describeNextEventForSign(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
RdsClient::DescribeOssDownloadsOutcome RdsClient::describeOssDownloads(const DescribeOssDownloadsRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -3723,6 +3795,78 @@ RdsClient::DescribeResourceUsageOutcomeCallable RdsClient::describeResourceUsage
return task->get_future();
}
RdsClient::DescribeSQLCollectorPolicyOutcome RdsClient::describeSQLCollectorPolicy(const DescribeSQLCollectorPolicyRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeSQLCollectorPolicyOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeSQLCollectorPolicyOutcome(DescribeSQLCollectorPolicyResult(outcome.result()));
else
return DescribeSQLCollectorPolicyOutcome(outcome.error());
}
void RdsClient::describeSQLCollectorPolicyAsync(const DescribeSQLCollectorPolicyRequest& request, const DescribeSQLCollectorPolicyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeSQLCollectorPolicy(request), context);
};
asyncExecute(new Runnable(fn));
}
RdsClient::DescribeSQLCollectorPolicyOutcomeCallable RdsClient::describeSQLCollectorPolicyCallable(const DescribeSQLCollectorPolicyRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeSQLCollectorPolicyOutcome()>>(
[this, request]()
{
return this->describeSQLCollectorPolicy(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
RdsClient::DescribeSQLCollectorRetentionOutcome RdsClient::describeSQLCollectorRetention(const DescribeSQLCollectorRetentionRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeSQLCollectorRetentionOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeSQLCollectorRetentionOutcome(DescribeSQLCollectorRetentionResult(outcome.result()));
else
return DescribeSQLCollectorRetentionOutcome(outcome.error());
}
void RdsClient::describeSQLCollectorRetentionAsync(const DescribeSQLCollectorRetentionRequest& request, const DescribeSQLCollectorRetentionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeSQLCollectorRetention(request), context);
};
asyncExecute(new Runnable(fn));
}
RdsClient::DescribeSQLCollectorRetentionOutcomeCallable RdsClient::describeSQLCollectorRetentionCallable(const DescribeSQLCollectorRetentionRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeSQLCollectorRetentionOutcome()>>(
[this, request]()
{
return this->describeSQLCollectorRetention(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
RdsClient::DescribeSQLLogFilesOutcome RdsClient::describeSQLLogFiles(const DescribeSQLLogFilesRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -3939,6 +4083,42 @@ RdsClient::DescribeSecurityGroupConfigurationOutcomeCallable RdsClient::describe
return task->get_future();
}
RdsClient::DescribeSignedEventActionsOutcome RdsClient::describeSignedEventActions(const DescribeSignedEventActionsRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeSignedEventActionsOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeSignedEventActionsOutcome(DescribeSignedEventActionsResult(outcome.result()));
else
return DescribeSignedEventActionsOutcome(outcome.error());
}
void RdsClient::describeSignedEventActionsAsync(const DescribeSignedEventActionsRequest& request, const DescribeSignedEventActionsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeSignedEventActions(request), context);
};
asyncExecute(new Runnable(fn));
}
RdsClient::DescribeSignedEventActionsOutcomeCallable RdsClient::describeSignedEventActionsCallable(const DescribeSignedEventActionsRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeSignedEventActionsOutcome()>>(
[this, request]()
{
return this->describeSignedEventActions(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
RdsClient::DescribeSlowLogRecordsOutcome RdsClient::describeSlowLogRecords(const DescribeSlowLogRecordsRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -4515,6 +4695,42 @@ RdsClient::ModifyActionEventPolicyOutcomeCallable RdsClient::modifyActionEventPo
return task->get_future();
}
RdsClient::ModifyActionEventVerifyPolicyOutcome RdsClient::modifyActionEventVerifyPolicy(const ModifyActionEventVerifyPolicyRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ModifyActionEventVerifyPolicyOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ModifyActionEventVerifyPolicyOutcome(ModifyActionEventVerifyPolicyResult(outcome.result()));
else
return ModifyActionEventVerifyPolicyOutcome(outcome.error());
}
void RdsClient::modifyActionEventVerifyPolicyAsync(const ModifyActionEventVerifyPolicyRequest& request, const ModifyActionEventVerifyPolicyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, modifyActionEventVerifyPolicy(request), context);
};
asyncExecute(new Runnable(fn));
}
RdsClient::ModifyActionEventVerifyPolicyOutcomeCallable RdsClient::modifyActionEventVerifyPolicyCallable(const ModifyActionEventVerifyPolicyRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ModifyActionEventVerifyPolicyOutcome()>>(
[this, request]()
{
return this->modifyActionEventVerifyPolicy(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
RdsClient::ModifyBackupPolicyOutcome RdsClient::modifyBackupPolicy(const ModifyBackupPolicyRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -5703,6 +5919,42 @@ RdsClient::ModifySQLCollectorPolicyOutcomeCallable RdsClient::modifySQLCollector
return task->get_future();
}
RdsClient::ModifySQLCollectorRetentionOutcome RdsClient::modifySQLCollectorRetention(const ModifySQLCollectorRetentionRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ModifySQLCollectorRetentionOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ModifySQLCollectorRetentionOutcome(ModifySQLCollectorRetentionResult(outcome.result()));
else
return ModifySQLCollectorRetentionOutcome(outcome.error());
}
void RdsClient::modifySQLCollectorRetentionAsync(const ModifySQLCollectorRetentionRequest& request, const ModifySQLCollectorRetentionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, modifySQLCollectorRetention(request), context);
};
asyncExecute(new Runnable(fn));
}
RdsClient::ModifySQLCollectorRetentionOutcomeCallable RdsClient::modifySQLCollectorRetentionCallable(const ModifySQLCollectorRetentionRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ModifySQLCollectorRetentionOutcome()>>(
[this, request]()
{
return this->modifySQLCollectorRetention(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
RdsClient::ModifySecurityGroupConfigurationOutcome RdsClient::modifySecurityGroupConfiguration(const ModifySecurityGroupConfigurationRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -6423,6 +6675,42 @@ RdsClient::RevokeOperatorPermissionOutcomeCallable RdsClient::revokeOperatorPerm
return task->get_future();
}
RdsClient::SignEventActionOutcome RdsClient::signEventAction(const SignEventActionRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return SignEventActionOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return SignEventActionOutcome(SignEventActionResult(outcome.result()));
else
return SignEventActionOutcome(outcome.error());
}
void RdsClient::signEventActionAsync(const SignEventActionRequest& request, const SignEventActionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, signEventAction(request), context);
};
asyncExecute(new Runnable(fn));
}
RdsClient::SignEventActionOutcomeCallable RdsClient::signEventActionCallable(const SignEventActionRequest &request) const
{
auto task = std::make_shared<std::packaged_task<SignEventActionOutcome()>>(
[this, request]()
{
return this->signEventAction(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
RdsClient::SwitchDBInstanceHAOutcome RdsClient::switchDBInstanceHA(const SwitchDBInstanceHARequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();

View File

@@ -126,3 +126,14 @@ void DescribeDBInstancePerformanceRequest::setOwnerId(long ownerId)
setCoreParameter("OwnerId", std::to_string(ownerId));
}
bool DescribeDBInstancePerformanceRequest::getUseNullWhenMissingPoint()const
{
return useNullWhenMissingPoint_;
}
void DescribeDBInstancePerformanceRequest::setUseNullWhenMissingPoint(bool useNullWhenMissingPoint)
{
useNullWhenMissingPoint_ = useNullWhenMissingPoint;
setCoreParameter("UseNullWhenMissingPoint", useNullWhenMissingPoint ? "true" : "false");
}

View File

@@ -148,6 +148,17 @@ void DescribeDBInstancesForCloneRequest::setRegionId(const std::string& regionId
setCoreParameter("RegionId", regionId);
}
std::string DescribeDBInstancesForCloneRequest::getCurrentInstanceId()const
{
return currentInstanceId_;
}
void DescribeDBInstancesForCloneRequest::setCurrentInstanceId(const std::string& currentInstanceId)
{
currentInstanceId_ = currentInstanceId;
setCoreParameter("CurrentInstanceId", currentInstanceId);
}
int DescribeDBInstancesForCloneRequest::getPageSize()const
{
return pageSize_;

View File

@@ -0,0 +1,150 @@
/*
* 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/rds/model/DescribeDBInstancesOverviewRequest.h>
using AlibabaCloud::Rds::Model::DescribeDBInstancesOverviewRequest;
DescribeDBInstancesOverviewRequest::DescribeDBInstancesOverviewRequest() :
RpcServiceRequest("rds", "2014-08-15", "DescribeDBInstancesOverview")
{
setMethod(HttpRequest::Method::Post);
}
DescribeDBInstancesOverviewRequest::~DescribeDBInstancesOverviewRequest()
{}
long DescribeDBInstancesOverviewRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeDBInstancesOverviewRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DescribeDBInstancesOverviewRequest::getClientToken()const
{
return clientToken_;
}
void DescribeDBInstancesOverviewRequest::setClientToken(const std::string& clientToken)
{
clientToken_ = clientToken;
setCoreParameter("ClientToken", clientToken);
}
std::string DescribeDBInstancesOverviewRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeDBInstancesOverviewRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setCoreParameter("AccessKeyId", accessKeyId);
}
std::string DescribeDBInstancesOverviewRequest::getExpired()const
{
return expired_;
}
void DescribeDBInstancesOverviewRequest::setExpired(const std::string& expired)
{
expired_ = expired;
setCoreParameter("Expired", expired);
}
std::string DescribeDBInstancesOverviewRequest::getEngine()const
{
return engine_;
}
void DescribeDBInstancesOverviewRequest::setEngine(const std::string& engine)
{
engine_ = engine;
setCoreParameter("Engine", engine);
}
std::string DescribeDBInstancesOverviewRequest::getRegionId()const
{
return regionId_;
}
void DescribeDBInstancesOverviewRequest::setRegionId(const std::string& regionId)
{
regionId_ = regionId;
setCoreParameter("RegionId", regionId);
}
std::string DescribeDBInstancesOverviewRequest::getDBInstanceId()const
{
return dBInstanceId_;
}
void DescribeDBInstancesOverviewRequest::setDBInstanceId(const std::string& dBInstanceId)
{
dBInstanceId_ = dBInstanceId;
setCoreParameter("DBInstanceId", dBInstanceId);
}
std::string DescribeDBInstancesOverviewRequest::getProxyId()const
{
return proxyId_;
}
void DescribeDBInstancesOverviewRequest::setProxyId(const std::string& proxyId)
{
proxyId_ = proxyId;
setCoreParameter("ProxyId", proxyId);
}
std::string DescribeDBInstancesOverviewRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeDBInstancesOverviewRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
long DescribeDBInstancesOverviewRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeDBInstancesOverviewRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setCoreParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeDBInstancesOverviewRequest::getZoneId()const
{
return zoneId_;
}
void DescribeDBInstancesOverviewRequest::setZoneId(const std::string& zoneId)
{
zoneId_ = zoneId;
setCoreParameter("ZoneId", zoneId);
}

View 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/rds/model/DescribeDBInstancesOverviewResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Rds;
using namespace AlibabaCloud::Rds::Model;
DescribeDBInstancesOverviewResult::DescribeDBInstancesOverviewResult() :
ServiceResult()
{}
DescribeDBInstancesOverviewResult::DescribeDBInstancesOverviewResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeDBInstancesOverviewResult::~DescribeDBInstancesOverviewResult()
{}
void DescribeDBInstancesOverviewResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allRegionsNode = value["Regions"]["RegionModel"];
for (auto valueRegionsRegionModel : allRegionsNode)
{
RegionModel regionsObject;
if(!valueRegionsRegionModel["Region"].isNull())
regionsObject.region = valueRegionsRegionModel["Region"].asString();
if(!valueRegionsRegionModel["EngineCount"].isNull())
regionsObject.engineCount = valueRegionsRegionModel["EngineCount"].asString();
if(!valueRegionsRegionModel["TotalCount"].isNull())
regionsObject.totalCount = std::stoi(valueRegionsRegionModel["TotalCount"].asString());
auto allTypeModelsNode = allRegionsNode["TypeModels"]["TypeModel"];
for (auto allRegionsNodeTypeModelsTypeModel : allTypeModelsNode)
{
RegionModel::TypeModel typeModelsObject;
if(!allRegionsNodeTypeModelsTypeModel["InstanceDateType"].isNull())
typeModelsObject.instanceDateType = allRegionsNodeTypeModelsTypeModel["InstanceDateType"].asString();
if(!allRegionsNodeTypeModelsTypeModel["Count"].isNull())
typeModelsObject.count = std::stoi(allRegionsNodeTypeModelsTypeModel["Count"].asString());
auto allInstanceModelsNode = allTypeModelsNode["InstanceModels"]["InstanceModel"];
for (auto allTypeModelsNodeInstanceModelsInstanceModel : allInstanceModelsNode)
{
RegionModel::TypeModel::InstanceModel instanceModelsObject;
if(!allTypeModelsNodeInstanceModelsInstanceModel["DBInstanceId"].isNull())
instanceModelsObject.dBInstanceId = allTypeModelsNodeInstanceModelsInstanceModel["DBInstanceId"].asString();
if(!allTypeModelsNodeInstanceModelsInstanceModel["Region"].isNull())
instanceModelsObject.region = allTypeModelsNodeInstanceModelsInstanceModel["Region"].asString();
if(!allTypeModelsNodeInstanceModelsInstanceModel["ZoneId"].isNull())
instanceModelsObject.zoneId = allTypeModelsNodeInstanceModelsInstanceModel["ZoneId"].asString();
if(!allTypeModelsNodeInstanceModelsInstanceModel["Engine"].isNull())
instanceModelsObject.engine = allTypeModelsNodeInstanceModelsInstanceModel["Engine"].asString();
if(!allTypeModelsNodeInstanceModelsInstanceModel["PayType"].isNull())
instanceModelsObject.payType = allTypeModelsNodeInstanceModelsInstanceModel["PayType"].asString();
if(!allTypeModelsNodeInstanceModelsInstanceModel["CreatedTime"].isNull())
instanceModelsObject.createdTime = allTypeModelsNodeInstanceModelsInstanceModel["CreatedTime"].asString();
if(!allTypeModelsNodeInstanceModelsInstanceModel["ExpireTime"].isNull())
instanceModelsObject.expireTime = allTypeModelsNodeInstanceModelsInstanceModel["ExpireTime"].asString();
if(!allTypeModelsNodeInstanceModelsInstanceModel["LockMode"].isNull())
instanceModelsObject.lockMode = allTypeModelsNodeInstanceModelsInstanceModel["LockMode"].asString();
if(!allTypeModelsNodeInstanceModelsInstanceModel["DBInstanceStatus"].isNull())
instanceModelsObject.dBInstanceStatus = allTypeModelsNodeInstanceModelsInstanceModel["DBInstanceStatus"].asString();
typeModelsObject.instanceModels.push_back(instanceModelsObject);
}
regionsObject.typeModels.push_back(typeModelsObject);
}
regions_.push_back(regionsObject);
}
}
std::vector<DescribeDBInstancesOverviewResult::RegionModel> DescribeDBInstancesOverviewResult::getRegions()const
{
return regions_;
}

View 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/rds/model/DescribeNextEventForSignRequest.h>
using AlibabaCloud::Rds::Model::DescribeNextEventForSignRequest;
DescribeNextEventForSignRequest::DescribeNextEventForSignRequest() :
RpcServiceRequest("rds", "2014-08-15", "DescribeNextEventForSign")
{
setMethod(HttpRequest::Method::Post);
}
DescribeNextEventForSignRequest::~DescribeNextEventForSignRequest()
{}
long DescribeNextEventForSignRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeNextEventForSignRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DescribeNextEventForSignRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeNextEventForSignRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
long DescribeNextEventForSignRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeNextEventForSignRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setCoreParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeNextEventForSignRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeNextEventForSignRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setCoreParameter("AccessKeyId", accessKeyId);
}
std::string DescribeNextEventForSignRequest::getRegionId()const
{
return regionId_;
}
void DescribeNextEventForSignRequest::setRegionId(const std::string& regionId)
{
regionId_ = regionId;
setCoreParameter("RegionId", regionId);
}

View File

@@ -0,0 +1,59 @@
/*
* 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/rds/model/DescribeNextEventForSignResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Rds;
using namespace AlibabaCloud::Rds::Model;
DescribeNextEventForSignResult::DescribeNextEventForSignResult() :
ServiceResult()
{}
DescribeNextEventForSignResult::DescribeNextEventForSignResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeNextEventForSignResult::~DescribeNextEventForSignResult()
{}
void DescribeNextEventForSignResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allEventItemsNode = value["EventItems"]["EventItemsItem"];
for (auto valueEventItemsEventItemsItem : allEventItemsNode)
{
EventItemsItem eventItemsObject;
if(!valueEventItemsEventItemsItem["EventId"].isNull())
eventItemsObject.eventId = std::stoi(valueEventItemsEventItemsItem["EventId"].asString());
if(!valueEventItemsEventItemsItem["EventContent"].isNull())
eventItemsObject.eventContent = valueEventItemsEventItemsItem["EventContent"].asString();
eventItems_.push_back(eventItemsObject);
}
}
std::vector<DescribeNextEventForSignResult::EventItemsItem> DescribeNextEventForSignResult::getEventItems()const
{
return eventItems_;
}

View File

@@ -0,0 +1,106 @@
/*
* 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/rds/model/DescribeSQLCollectorPolicyRequest.h>
using AlibabaCloud::Rds::Model::DescribeSQLCollectorPolicyRequest;
DescribeSQLCollectorPolicyRequest::DescribeSQLCollectorPolicyRequest() :
RpcServiceRequest("rds", "2014-08-15", "DescribeSQLCollectorPolicy")
{
setMethod(HttpRequest::Method::Post);
}
DescribeSQLCollectorPolicyRequest::~DescribeSQLCollectorPolicyRequest()
{}
long DescribeSQLCollectorPolicyRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeSQLCollectorPolicyRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DescribeSQLCollectorPolicyRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeSQLCollectorPolicyRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
std::string DescribeSQLCollectorPolicyRequest::getClientToken()const
{
return clientToken_;
}
void DescribeSQLCollectorPolicyRequest::setClientToken(const std::string& clientToken)
{
clientToken_ = clientToken;
setCoreParameter("ClientToken", clientToken);
}
std::string DescribeSQLCollectorPolicyRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void DescribeSQLCollectorPolicyRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setCoreParameter("OwnerAccount", ownerAccount);
}
long DescribeSQLCollectorPolicyRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeSQLCollectorPolicyRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setCoreParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeSQLCollectorPolicyRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeSQLCollectorPolicyRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setCoreParameter("AccessKeyId", accessKeyId);
}
std::string DescribeSQLCollectorPolicyRequest::getDBInstanceId()const
{
return dBInstanceId_;
}
void DescribeSQLCollectorPolicyRequest::setDBInstanceId(const std::string& dBInstanceId)
{
dBInstanceId_ = dBInstanceId;
setCoreParameter("DBInstanceId", dBInstanceId);
}

View File

@@ -0,0 +1,58 @@
/*
* 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/rds/model/DescribeSQLCollectorPolicyResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Rds;
using namespace AlibabaCloud::Rds::Model;
DescribeSQLCollectorPolicyResult::DescribeSQLCollectorPolicyResult() :
ServiceResult()
{}
DescribeSQLCollectorPolicyResult::DescribeSQLCollectorPolicyResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeSQLCollectorPolicyResult::~DescribeSQLCollectorPolicyResult()
{}
void DescribeSQLCollectorPolicyResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["SQLCollectorStatus"].isNull())
sQLCollectorStatus_ = value["SQLCollectorStatus"].asString();
if(!value["StoragePeriod"].isNull())
storagePeriod_ = std::stoi(value["StoragePeriod"].asString());
}
int DescribeSQLCollectorPolicyResult::getStoragePeriod()const
{
return storagePeriod_;
}
std::string DescribeSQLCollectorPolicyResult::getSQLCollectorStatus()const
{
return sQLCollectorStatus_;
}

View File

@@ -0,0 +1,106 @@
/*
* 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/rds/model/DescribeSQLCollectorRetentionRequest.h>
using AlibabaCloud::Rds::Model::DescribeSQLCollectorRetentionRequest;
DescribeSQLCollectorRetentionRequest::DescribeSQLCollectorRetentionRequest() :
RpcServiceRequest("rds", "2014-08-15", "DescribeSQLCollectorRetention")
{
setMethod(HttpRequest::Method::Post);
}
DescribeSQLCollectorRetentionRequest::~DescribeSQLCollectorRetentionRequest()
{}
long DescribeSQLCollectorRetentionRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeSQLCollectorRetentionRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DescribeSQLCollectorRetentionRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeSQLCollectorRetentionRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setCoreParameter("AccessKeyId", accessKeyId);
}
std::string DescribeSQLCollectorRetentionRequest::getSecurityToken()const
{
return securityToken_;
}
void DescribeSQLCollectorRetentionRequest::setSecurityToken(const std::string& securityToken)
{
securityToken_ = securityToken;
setCoreParameter("SecurityToken", securityToken);
}
std::string DescribeSQLCollectorRetentionRequest::getDBInstanceId()const
{
return dBInstanceId_;
}
void DescribeSQLCollectorRetentionRequest::setDBInstanceId(const std::string& dBInstanceId)
{
dBInstanceId_ = dBInstanceId;
setCoreParameter("DBInstanceId", dBInstanceId);
}
std::string DescribeSQLCollectorRetentionRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeSQLCollectorRetentionRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
std::string DescribeSQLCollectorRetentionRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void DescribeSQLCollectorRetentionRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setCoreParameter("OwnerAccount", ownerAccount);
}
long DescribeSQLCollectorRetentionRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeSQLCollectorRetentionRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setCoreParameter("OwnerId", std::to_string(ownerId));
}

View 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/rds/model/DescribeSQLCollectorRetentionResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Rds;
using namespace AlibabaCloud::Rds::Model;
DescribeSQLCollectorRetentionResult::DescribeSQLCollectorRetentionResult() :
ServiceResult()
{}
DescribeSQLCollectorRetentionResult::DescribeSQLCollectorRetentionResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeSQLCollectorRetentionResult::~DescribeSQLCollectorRetentionResult()
{}
void DescribeSQLCollectorRetentionResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["DBInstanceID"].isNull())
dBInstanceID_ = std::stoi(value["DBInstanceID"].asString());
if(!value["DBInstanceName"].isNull())
dBInstanceName_ = value["DBInstanceName"].asString();
if(!value["ConfigValue"].isNull())
configValue_ = value["ConfigValue"].asString();
}
std::string DescribeSQLCollectorRetentionResult::getConfigValue()const
{
return configValue_;
}
int DescribeSQLCollectorRetentionResult::getDBInstanceID()const
{
return dBInstanceID_;
}
std::string DescribeSQLCollectorRetentionResult::getDBInstanceName()const
{
return dBInstanceName_;
}

View File

@@ -0,0 +1,106 @@
/*
* 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/rds/model/DescribeSignedEventActionsRequest.h>
using AlibabaCloud::Rds::Model::DescribeSignedEventActionsRequest;
DescribeSignedEventActionsRequest::DescribeSignedEventActionsRequest() :
RpcServiceRequest("rds", "2014-08-15", "DescribeSignedEventActions")
{
setMethod(HttpRequest::Method::Post);
}
DescribeSignedEventActionsRequest::~DescribeSignedEventActionsRequest()
{}
long DescribeSignedEventActionsRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeSignedEventActionsRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
int DescribeSignedEventActionsRequest::getBeginEventId()const
{
return beginEventId_;
}
void DescribeSignedEventActionsRequest::setBeginEventId(int beginEventId)
{
beginEventId_ = beginEventId;
setCoreParameter("BeginEventId", std::to_string(beginEventId));
}
std::string DescribeSignedEventActionsRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeSignedEventActionsRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
long DescribeSignedEventActionsRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeSignedEventActionsRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setCoreParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeSignedEventActionsRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeSignedEventActionsRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setCoreParameter("AccessKeyId", accessKeyId);
}
std::string DescribeSignedEventActionsRequest::getRegionId()const
{
return regionId_;
}
void DescribeSignedEventActionsRequest::setRegionId(const std::string& regionId)
{
regionId_ = regionId;
setCoreParameter("RegionId", regionId);
}
int DescribeSignedEventActionsRequest::getPageSize()const
{
return pageSize_;
}
void DescribeSignedEventActionsRequest::setPageSize(int pageSize)
{
pageSize_ = pageSize;
setCoreParameter("PageSize", std::to_string(pageSize));
}

View File

@@ -0,0 +1,91 @@
/*
* 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/rds/model/DescribeSignedEventActionsResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Rds;
using namespace AlibabaCloud::Rds::Model;
DescribeSignedEventActionsResult::DescribeSignedEventActionsResult() :
ServiceResult()
{}
DescribeSignedEventActionsResult::DescribeSignedEventActionsResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeSignedEventActionsResult::~DescribeSignedEventActionsResult()
{}
void DescribeSignedEventActionsResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allEventItemsNode = value["EventItems"]["EventItemsItem"];
for (auto valueEventItemsEventItemsItem : allEventItemsNode)
{
EventItemsItem eventItemsObject;
if(!valueEventItemsEventItemsItem["EventId"].isNull())
eventItemsObject.eventId = std::stoi(valueEventItemsEventItemsItem["EventId"].asString());
if(!valueEventItemsEventItemsItem["EventContent"].isNull())
eventItemsObject.eventContent = valueEventItemsEventItemsItem["EventContent"].asString();
if(!valueEventItemsEventItemsItem["EventSig"].isNull())
eventItemsObject.eventSig = valueEventItemsEventItemsItem["EventSig"].asString();
if(!valueEventItemsEventItemsItem["EventRcpt"].isNull())
eventItemsObject.eventRcpt = valueEventItemsEventItemsItem["EventRcpt"].asString();
eventItems_.push_back(eventItemsObject);
}
if(!value["NextPageEventId"].isNull())
nextPageEventId_ = std::stoi(value["NextPageEventId"].asString());
if(!value["PageRecordCount"].isNull())
pageRecordCount_ = std::stoi(value["PageRecordCount"].asString());
if(!value["FromBegin"].isNull())
fromBegin_ = value["FromBegin"].asString() == "true";
if(!value["ToEnd"].isNull())
toEnd_ = value["ToEnd"].asString() == "true";
}
std::vector<DescribeSignedEventActionsResult::EventItemsItem> DescribeSignedEventActionsResult::getEventItems()const
{
return eventItems_;
}
int DescribeSignedEventActionsResult::getPageRecordCount()const
{
return pageRecordCount_;
}
bool DescribeSignedEventActionsResult::getToEnd()const
{
return toEnd_;
}
bool DescribeSignedEventActionsResult::getFromBegin()const
{
return fromBegin_;
}
int DescribeSignedEventActionsResult::getNextPageEventId()const
{
return nextPageEventId_;
}

View 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/rds/model/ModifyActionEventVerifyPolicyRequest.h>
using AlibabaCloud::Rds::Model::ModifyActionEventVerifyPolicyRequest;
ModifyActionEventVerifyPolicyRequest::ModifyActionEventVerifyPolicyRequest() :
RpcServiceRequest("rds", "2014-08-15", "ModifyActionEventVerifyPolicy")
{
setMethod(HttpRequest::Method::Post);
}
ModifyActionEventVerifyPolicyRequest::~ModifyActionEventVerifyPolicyRequest()
{}
long ModifyActionEventVerifyPolicyRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void ModifyActionEventVerifyPolicyRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string ModifyActionEventVerifyPolicyRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void ModifyActionEventVerifyPolicyRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
long ModifyActionEventVerifyPolicyRequest::getOwnerId()const
{
return ownerId_;
}
void ModifyActionEventVerifyPolicyRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setCoreParameter("OwnerId", std::to_string(ownerId));
}
std::string ModifyActionEventVerifyPolicyRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void ModifyActionEventVerifyPolicyRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setCoreParameter("AccessKeyId", accessKeyId);
}
std::string ModifyActionEventVerifyPolicyRequest::getRegionId()const
{
return regionId_;
}
void ModifyActionEventVerifyPolicyRequest::setRegionId(const std::string& regionId)
{
regionId_ = regionId;
setCoreParameter("RegionId", regionId);
}
std::string ModifyActionEventVerifyPolicyRequest::getUserPublicKey()const
{
return userPublicKey_;
}
void ModifyActionEventVerifyPolicyRequest::setUserPublicKey(const std::string& userPublicKey)
{
userPublicKey_ = userPublicKey;
setCoreParameter("UserPublicKey", userPublicKey);
}

View File

@@ -0,0 +1,58 @@
/*
* 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/rds/model/ModifyActionEventVerifyPolicyResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Rds;
using namespace AlibabaCloud::Rds::Model;
ModifyActionEventVerifyPolicyResult::ModifyActionEventVerifyPolicyResult() :
ServiceResult()
{}
ModifyActionEventVerifyPolicyResult::ModifyActionEventVerifyPolicyResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ModifyActionEventVerifyPolicyResult::~ModifyActionEventVerifyPolicyResult()
{}
void ModifyActionEventVerifyPolicyResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["RegionId"].isNull())
regionId_ = value["RegionId"].asString();
if(!value["ServerPublicKey"].isNull())
serverPublicKey_ = value["ServerPublicKey"].asString();
}
std::string ModifyActionEventVerifyPolicyResult::getRegionId()const
{
return regionId_;
}
std::string ModifyActionEventVerifyPolicyResult::getServerPublicKey()const
{
return serverPublicKey_;
}

View File

@@ -115,6 +115,17 @@ void ModifyDBInstanceSpecRequest::setDBInstanceStorageType(const std::string& dB
setCoreParameter("DBInstanceStorageType", dBInstanceStorageType);
}
std::string ModifyDBInstanceSpecRequest::getSourceBiz()const
{
return sourceBiz_;
}
void ModifyDBInstanceSpecRequest::setSourceBiz(const std::string& sourceBiz)
{
sourceBiz_ = sourceBiz;
setCoreParameter("SourceBiz", sourceBiz);
}
std::string ModifyDBInstanceSpecRequest::getDirection()const
{
return direction_;

View File

@@ -0,0 +1,117 @@
/*
* 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/rds/model/ModifySQLCollectorRetentionRequest.h>
using AlibabaCloud::Rds::Model::ModifySQLCollectorRetentionRequest;
ModifySQLCollectorRetentionRequest::ModifySQLCollectorRetentionRequest() :
RpcServiceRequest("rds", "2014-08-15", "ModifySQLCollectorRetention")
{
setMethod(HttpRequest::Method::Post);
}
ModifySQLCollectorRetentionRequest::~ModifySQLCollectorRetentionRequest()
{}
long ModifySQLCollectorRetentionRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void ModifySQLCollectorRetentionRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string ModifySQLCollectorRetentionRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void ModifySQLCollectorRetentionRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setCoreParameter("AccessKeyId", accessKeyId);
}
std::string ModifySQLCollectorRetentionRequest::getSecurityToken()const
{
return securityToken_;
}
void ModifySQLCollectorRetentionRequest::setSecurityToken(const std::string& securityToken)
{
securityToken_ = securityToken;
setCoreParameter("SecurityToken", securityToken);
}
std::string ModifySQLCollectorRetentionRequest::getDBInstanceId()const
{
return dBInstanceId_;
}
void ModifySQLCollectorRetentionRequest::setDBInstanceId(const std::string& dBInstanceId)
{
dBInstanceId_ = dBInstanceId;
setCoreParameter("DBInstanceId", dBInstanceId);
}
std::string ModifySQLCollectorRetentionRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void ModifySQLCollectorRetentionRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
std::string ModifySQLCollectorRetentionRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void ModifySQLCollectorRetentionRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setCoreParameter("OwnerAccount", ownerAccount);
}
std::string ModifySQLCollectorRetentionRequest::getConfigValue()const
{
return configValue_;
}
void ModifySQLCollectorRetentionRequest::setConfigValue(const std::string& configValue)
{
configValue_ = configValue;
setCoreParameter("ConfigValue", configValue);
}
long ModifySQLCollectorRetentionRequest::getOwnerId()const
{
return ownerId_;
}
void ModifySQLCollectorRetentionRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setCoreParameter("OwnerId", std::to_string(ownerId));
}

View 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/rds/model/ModifySQLCollectorRetentionResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Rds;
using namespace AlibabaCloud::Rds::Model;
ModifySQLCollectorRetentionResult::ModifySQLCollectorRetentionResult() :
ServiceResult()
{}
ModifySQLCollectorRetentionResult::ModifySQLCollectorRetentionResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ModifySQLCollectorRetentionResult::~ModifySQLCollectorRetentionResult()
{}
void ModifySQLCollectorRetentionResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["DBInstanceID"].isNull())
dBInstanceID_ = std::stoi(value["DBInstanceID"].asString());
if(!value["DBInstanceName"].isNull())
dBInstanceName_ = value["DBInstanceName"].asString();
if(!value["TaskId"].isNull())
taskId_ = std::stoi(value["TaskId"].asString());
}
int ModifySQLCollectorRetentionResult::getTaskId()const
{
return taskId_;
}
int ModifySQLCollectorRetentionResult::getDBInstanceID()const
{
return dBInstanceID_;
}
std::string ModifySQLCollectorRetentionResult::getDBInstanceName()const
{
return dBInstanceName_;
}

View File

@@ -0,0 +1,106 @@
/*
* 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/rds/model/SignEventActionRequest.h>
using AlibabaCloud::Rds::Model::SignEventActionRequest;
SignEventActionRequest::SignEventActionRequest() :
RpcServiceRequest("rds", "2014-08-15", "SignEventAction")
{
setMethod(HttpRequest::Method::Post);
}
SignEventActionRequest::~SignEventActionRequest()
{}
int SignEventActionRequest::getEventId()const
{
return eventId_;
}
void SignEventActionRequest::setEventId(int eventId)
{
eventId_ = eventId;
setCoreParameter("EventId", std::to_string(eventId));
}
long SignEventActionRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void SignEventActionRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setCoreParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string SignEventActionRequest::getEventSig()const
{
return eventSig_;
}
void SignEventActionRequest::setEventSig(const std::string& eventSig)
{
eventSig_ = eventSig;
setCoreParameter("EventSig", eventSig);
}
std::string SignEventActionRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void SignEventActionRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setCoreParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
long SignEventActionRequest::getOwnerId()const
{
return ownerId_;
}
void SignEventActionRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setCoreParameter("OwnerId", std::to_string(ownerId));
}
std::string SignEventActionRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void SignEventActionRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setCoreParameter("AccessKeyId", accessKeyId);
}
std::string SignEventActionRequest::getRegionId()const
{
return regionId_;
}
void SignEventActionRequest::setRegionId(const std::string& regionId)
{
regionId_ = regionId;
setCoreParameter("RegionId", regionId);
}

View File

@@ -0,0 +1,58 @@
/*
* 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/rds/model/SignEventActionResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Rds;
using namespace AlibabaCloud::Rds::Model;
SignEventActionResult::SignEventActionResult() :
ServiceResult()
{}
SignEventActionResult::SignEventActionResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
SignEventActionResult::~SignEventActionResult()
{}
void SignEventActionResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["EventId"].isNull())
eventId_ = value["EventId"].asString();
if(!value["EventRcpt"].isNull())
eventRcpt_ = value["EventRcpt"].asString();
}
std::string SignEventActionResult::getEventId()const
{
return eventId_;
}
std::string SignEventActionResult::getEventRcpt()const
{
return eventRcpt_;
}

View File

@@ -155,7 +155,7 @@ namespace {
EXPECT_TRUE(nbr == 0);
client->asyncExecute(rf);
usleep(10000);
EXPECT_TRUE(nbr == 1);
EXPECT_EQ(nbr, 1);
ShutdownSdk();
}

View File

@@ -95,5 +95,4 @@ TEST(RoaServiceClient, basic) {
req.setParameter("Content-Type", "test-content-type");
http_req = client.buildHttpRequest("cn-shanghai", req, HttpRequest::Method::Get);
EXPECT_TRUE(http_req.url().toString() == "http://cn-shanghai/?Accept=tets-accept&Content-Type=test-content-type&a=b");
}

View File

@@ -17,22 +17,25 @@ namespace {
{}
explicit TestServiceRequest(const ServiceRequest &other):
ServiceRequest(other)
{}
{
}
explicit TestServiceRequest(ServiceRequest &&other):
ServiceRequest(other)
{}
{
}
using ServiceRequest::addParameter;
using ServiceRequest::removeParameter;
using ServiceRequest::coreParameter;
using ServiceRequest::parameter;
using ServiceRequest::removeParameter;
using ServiceRequest::setBodyParameter;
using ServiceRequest::setContent;
using ServiceRequest::setCoreParameter;
using ServiceRequest::setParameter;
using ServiceRequest::setParameters;
using ServiceRequest::setResourcePath;
using ServiceRequest::setProduct;
using ServiceRequest::setResourcePath;
using ServiceRequest::setVersion;
using ServiceRequest::setCoreParameter;
using ServiceRequest::coreParameter;
};
TEST(ServiceRequest, basic) {
@@ -63,6 +66,8 @@ namespace {
EXPECT_TRUE(sr1.parameter("ka") == "va");
EXPECT_TRUE(sr1.coreParameter("ka") == "va");
sr1.setBodyParameter("name", "value");
sr1.setContent("123456", 6);
EXPECT_TRUE(sr1.contentSize() == 6);
EXPECT_TRUE(sr1.hasContent() == true);
@@ -90,6 +95,9 @@ namespace {
EXPECT_TRUE(pc.at("km") == "vm");
EXPECT_TRUE(pc.at("kn") == "vn");
ServiceRequest::ParameterCollection bp = sr1.bodyParameters();
EXPECT_EQ(bp.at("name"), "value");
EXPECT_TRUE(sr1.connectTimeout() == kInvalidTimeout);
EXPECT_TRUE(sr1.readTimeout() == kInvalidTimeout);
sr1.setConnectTimeout(1234);
@@ -97,4 +105,21 @@ namespace {
EXPECT_TRUE(sr1.connectTimeout() == 1234);
EXPECT_TRUE(sr1.readTimeout() == 22233);
}
TEST(ServiceRequest, other){
ServiceRequest one("one", "1.0");
EXPECT_EQ("one", one.product());
ServiceRequest two("two", "1.0");
EXPECT_EQ("two", two.product());
ServiceRequest three = one;
EXPECT_EQ("one", three.product());
ServiceRequest four(two);
EXPECT_EQ("two" , four.product());
ServiceRequest &&five(move(two));
EXPECT_EQ("two" , five.product());
}
}

View File

@@ -61,6 +61,23 @@ namespace {
EXPECT_TRUE(decoded == url);
}
TEST(UtilsTest, MapToJson){
std::map<std::string, std::string> maps;
maps.insert(std::make_pair("foo", "bar"));
std::string jsonStr = MapToJson(maps);
EXPECT_EQ(jsonStr, "{\"foo\":\"bar\"}");
}
TEST(UtilsTest, JsonToMap){
std::map<std::string, std::string> targetMaps;
targetMaps.insert(std::make_pair("foo", "bar"));
targetMaps.insert(std::make_pair("int", "1"));
targetMaps.insert(std::make_pair("array","foo,bar"));
std::string jsonStr = "{\"foo\":\"bar\",\"int\":1,\"array\":[\"foo\",\"bar\"]}";
std::map<std::string, std::string> maps = JsonToMap(jsonStr);
EXPECT_EQ(targetMaps, maps);
}
TEST(Utils, GetEnv) {
const std::string var1 = GetEnv("PATH");
EXPECT_FALSE(var1.empty());

View File

@@ -131,9 +131,11 @@ TEST(LocationClient, callable)
configuration.setConnectTimeout(100000);
configuration.setReadTimeout(100000);
Model::DescribeEndpointsRequest req;
req.setMethod(HttpRequest::Method::Get);
req.setId("cn-hangzhou");
req.setServiceCode("ecs");
req.setType("openAPI");
req.setBodyParameter("foo", "var");
LocationClient client(key, secret, configuration);
LocationClient::DescribeEndpointsOutcomeCallable cb = client.describeEndpointsCallable(req);