diff --git a/CHANGELOG b/CHANGELOG index a3f6a9a5b..c8da2c1b4 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +2019-03-14 Version: 1.34.22 +1, Update Dependency + 2019-03-14 Version: 1.34.21 1, Update Dependency diff --git a/CMakeLists.txt b/CMakeLists.txt index 8c4a931f9..b9a4ca1e4 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -97,4 +97,5 @@ add_subdirectory(cbn) add_subdirectory(emr) add_subdirectory(ram) add_subdirectory(sts) -add_subdirectory(gpdb) \ No newline at end of file +add_subdirectory(gpdb) +add_subdirectory(sas-api) \ No newline at end of file diff --git a/VERSION b/VERSION index 4c1e3070b..d52b882d3 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.34.21 \ No newline at end of file +1.34.22 \ No newline at end of file diff --git a/sas-api/CMakeLists.txt b/sas-api/CMakeLists.txt new file mode 100644 index 000000000..604653df7 --- /dev/null +++ b/sas-api/CMakeLists.txt @@ -0,0 +1,130 @@ +# +# Copyright 2009-2017 Alibaba Cloud All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +set(public_header_dir ${CMAKE_CURRENT_SOURCE_DIR}/../include) + +set(sas-api_public_header + include/alibabacloud/sas-api/Sas-apiClient.h + include/alibabacloud/sas-api/Sas-apiExport.h ) + +set(sas-api_public_header_model + include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyWordRequest.h + include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyWordResult.h + include/alibabacloud/sas-api/model/DescribeThreatTypeLinesRequest.h + include/alibabacloud/sas-api/model/DescribeThreatTypeLinesResult.h + include/alibabacloud/sas-api/model/DescribeThreatDistributeRequest.h + include/alibabacloud/sas-api/model/DescribeThreatDistributeResult.h + include/alibabacloud/sas-api/model/GetPhoneProfileRequest.h + include/alibabacloud/sas-api/model/GetPhoneProfileResult.h + include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyRequest.h + include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyResult.h + include/alibabacloud/sas-api/model/GetInstanceCountRequest.h + include/alibabacloud/sas-api/model/GetInstanceCountResult.h + include/alibabacloud/sas-api/model/DescribePerDateDataRequest.h + include/alibabacloud/sas-api/model/DescribePerDateDataResult.h + include/alibabacloud/sas-api/model/GetAccountProfileRequest.h + include/alibabacloud/sas-api/model/GetAccountProfileResult.h + include/alibabacloud/sas-api/model/DescribeTotalAndRateLineRequest.h + include/alibabacloud/sas-api/model/DescribeTotalAndRateLineResult.h + include/alibabacloud/sas-api/model/GetIpProfileRequest.h + include/alibabacloud/sas-api/model/GetIpProfileResult.h + include/alibabacloud/sas-api/model/DescribeHitRateColumnRequest.h + include/alibabacloud/sas-api/model/DescribeHitRateColumnResult.h + include/alibabacloud/sas-api/model/DescribeHitRatePieRequest.h + include/alibabacloud/sas-api/model/DescribeHitRatePieResult.h ) + +set(sas-api_src + src/Sas-apiClient.cc + src/model/DescribeAccountProfileByKeyWordRequest.cc + src/model/DescribeAccountProfileByKeyWordResult.cc + src/model/DescribeThreatTypeLinesRequest.cc + src/model/DescribeThreatTypeLinesResult.cc + src/model/DescribeThreatDistributeRequest.cc + src/model/DescribeThreatDistributeResult.cc + src/model/GetPhoneProfileRequest.cc + src/model/GetPhoneProfileResult.cc + src/model/DescribeAccountProfileByKeyRequest.cc + src/model/DescribeAccountProfileByKeyResult.cc + src/model/GetInstanceCountRequest.cc + src/model/GetInstanceCountResult.cc + src/model/DescribePerDateDataRequest.cc + src/model/DescribePerDateDataResult.cc + src/model/GetAccountProfileRequest.cc + src/model/GetAccountProfileResult.cc + src/model/DescribeTotalAndRateLineRequest.cc + src/model/DescribeTotalAndRateLineResult.cc + src/model/GetIpProfileRequest.cc + src/model/GetIpProfileResult.cc + src/model/DescribeHitRateColumnRequest.cc + src/model/DescribeHitRateColumnResult.cc + src/model/DescribeHitRatePieRequest.cc + src/model/DescribeHitRatePieResult.cc ) + +add_library(sas-api ${LIB_TYPE} + ${sas-api_public_header} + ${sas-api_public_header_model} + ${sas-api_src}) + +set_target_properties(sas-api + 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}sas-api + ) + +if(${LIB_TYPE} STREQUAL "SHARED") + set_target_properties(sas-api + PROPERTIES + DEFINE_SYMBOL ALIBABACLOUD_SAS-API_LIBRARY) +endif() + +target_include_directories(sas-api + PRIVATE include + ${CMAKE_SOURCE_DIR}/core/include + ) +target_link_libraries(sas-api + core) + +if(CMAKE_HOST_WIN32) + ExternalProject_Get_Property(jsoncpp INSTALL_DIR) + set(jsoncpp_install_dir ${INSTALL_DIR}) + add_dependencies(sas-api + jsoncpp) + target_include_directories(sas-api + PRIVATE ${jsoncpp_install_dir}/include) + target_link_libraries(sas-api + ${jsoncpp_install_dir}/lib/jsoncpp.lib) + set_target_properties(sas-api + PROPERTIES + COMPILE_OPTIONS "/bigobj") +else() + target_include_directories(sas-api + PRIVATE /usr/include/jsoncpp) + target_link_libraries(sas-api + jsoncpp) +endif() + +install(FILES ${sas-api_public_header} + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/sas-api) +install(FILES ${sas-api_public_header_model} + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/sas-api/model) +install(TARGETS sas-api + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + ) \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/Sas-apiClient.h b/sas-api/include/alibabacloud/sas-api/Sas-apiClient.h new file mode 100644 index 000000000..085c92b2e --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/Sas-apiClient.h @@ -0,0 +1,142 @@ +/* + * 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_SAS-API_SAS-APICLIENT_H_ +#define ALIBABACLOUD_SAS-API_SAS-APICLIENT_H_ + +#include +#include +#include +#include +#include "Sas-apiExport.h" +#include "model/DescribeAccountProfileByKeyWordRequest.h" +#include "model/DescribeAccountProfileByKeyWordResult.h" +#include "model/DescribeThreatTypeLinesRequest.h" +#include "model/DescribeThreatTypeLinesResult.h" +#include "model/DescribeThreatDistributeRequest.h" +#include "model/DescribeThreatDistributeResult.h" +#include "model/GetPhoneProfileRequest.h" +#include "model/GetPhoneProfileResult.h" +#include "model/DescribeAccountProfileByKeyRequest.h" +#include "model/DescribeAccountProfileByKeyResult.h" +#include "model/GetInstanceCountRequest.h" +#include "model/GetInstanceCountResult.h" +#include "model/DescribePerDateDataRequest.h" +#include "model/DescribePerDateDataResult.h" +#include "model/GetAccountProfileRequest.h" +#include "model/GetAccountProfileResult.h" +#include "model/DescribeTotalAndRateLineRequest.h" +#include "model/DescribeTotalAndRateLineResult.h" +#include "model/GetIpProfileRequest.h" +#include "model/GetIpProfileResult.h" +#include "model/DescribeHitRateColumnRequest.h" +#include "model/DescribeHitRateColumnResult.h" +#include "model/DescribeHitRatePieRequest.h" +#include "model/DescribeHitRatePieResult.h" + + +namespace AlibabaCloud +{ + namespace Sas-api + { + class ALIBABACLOUD_SAS-API_EXPORT Sas-apiClient : public RpcServiceClient + { + public: + typedef Outcome DescribeAccountProfileByKeyWordOutcome; + typedef std::future DescribeAccountProfileByKeyWordOutcomeCallable; + typedef std::function&)> DescribeAccountProfileByKeyWordAsyncHandler; + typedef Outcome DescribeThreatTypeLinesOutcome; + typedef std::future DescribeThreatTypeLinesOutcomeCallable; + typedef std::function&)> DescribeThreatTypeLinesAsyncHandler; + typedef Outcome DescribeThreatDistributeOutcome; + typedef std::future DescribeThreatDistributeOutcomeCallable; + typedef std::function&)> DescribeThreatDistributeAsyncHandler; + typedef Outcome GetPhoneProfileOutcome; + typedef std::future GetPhoneProfileOutcomeCallable; + typedef std::function&)> GetPhoneProfileAsyncHandler; + typedef Outcome DescribeAccountProfileByKeyOutcome; + typedef std::future DescribeAccountProfileByKeyOutcomeCallable; + typedef std::function&)> DescribeAccountProfileByKeyAsyncHandler; + typedef Outcome GetInstanceCountOutcome; + typedef std::future GetInstanceCountOutcomeCallable; + typedef std::function&)> GetInstanceCountAsyncHandler; + typedef Outcome DescribePerDateDataOutcome; + typedef std::future DescribePerDateDataOutcomeCallable; + typedef std::function&)> DescribePerDateDataAsyncHandler; + typedef Outcome GetAccountProfileOutcome; + typedef std::future GetAccountProfileOutcomeCallable; + typedef std::function&)> GetAccountProfileAsyncHandler; + typedef Outcome DescribeTotalAndRateLineOutcome; + typedef std::future DescribeTotalAndRateLineOutcomeCallable; + typedef std::function&)> DescribeTotalAndRateLineAsyncHandler; + typedef Outcome GetIpProfileOutcome; + typedef std::future GetIpProfileOutcomeCallable; + typedef std::function&)> GetIpProfileAsyncHandler; + typedef Outcome DescribeHitRateColumnOutcome; + typedef std::future DescribeHitRateColumnOutcomeCallable; + typedef std::function&)> DescribeHitRateColumnAsyncHandler; + typedef Outcome DescribeHitRatePieOutcome; + typedef std::future DescribeHitRatePieOutcomeCallable; + typedef std::function&)> DescribeHitRatePieAsyncHandler; + + Sas-apiClient(const Credentials &credentials, const ClientConfiguration &configuration); + Sas-apiClient(const std::shared_ptr &credentialsProvider, const ClientConfiguration &configuration); + Sas-apiClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration); + ~Sas-apiClient(); + DescribeAccountProfileByKeyWordOutcome describeAccountProfileByKeyWord(const Model::DescribeAccountProfileByKeyWordRequest &request)const; + void describeAccountProfileByKeyWordAsync(const Model::DescribeAccountProfileByKeyWordRequest& request, const DescribeAccountProfileByKeyWordAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeAccountProfileByKeyWordOutcomeCallable describeAccountProfileByKeyWordCallable(const Model::DescribeAccountProfileByKeyWordRequest& request) const; + DescribeThreatTypeLinesOutcome describeThreatTypeLines(const Model::DescribeThreatTypeLinesRequest &request)const; + void describeThreatTypeLinesAsync(const Model::DescribeThreatTypeLinesRequest& request, const DescribeThreatTypeLinesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeThreatTypeLinesOutcomeCallable describeThreatTypeLinesCallable(const Model::DescribeThreatTypeLinesRequest& request) const; + DescribeThreatDistributeOutcome describeThreatDistribute(const Model::DescribeThreatDistributeRequest &request)const; + void describeThreatDistributeAsync(const Model::DescribeThreatDistributeRequest& request, const DescribeThreatDistributeAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeThreatDistributeOutcomeCallable describeThreatDistributeCallable(const Model::DescribeThreatDistributeRequest& request) const; + GetPhoneProfileOutcome getPhoneProfile(const Model::GetPhoneProfileRequest &request)const; + void getPhoneProfileAsync(const Model::GetPhoneProfileRequest& request, const GetPhoneProfileAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetPhoneProfileOutcomeCallable getPhoneProfileCallable(const Model::GetPhoneProfileRequest& request) const; + DescribeAccountProfileByKeyOutcome describeAccountProfileByKey(const Model::DescribeAccountProfileByKeyRequest &request)const; + void describeAccountProfileByKeyAsync(const Model::DescribeAccountProfileByKeyRequest& request, const DescribeAccountProfileByKeyAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeAccountProfileByKeyOutcomeCallable describeAccountProfileByKeyCallable(const Model::DescribeAccountProfileByKeyRequest& request) const; + GetInstanceCountOutcome getInstanceCount(const Model::GetInstanceCountRequest &request)const; + void getInstanceCountAsync(const Model::GetInstanceCountRequest& request, const GetInstanceCountAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetInstanceCountOutcomeCallable getInstanceCountCallable(const Model::GetInstanceCountRequest& request) const; + DescribePerDateDataOutcome describePerDateData(const Model::DescribePerDateDataRequest &request)const; + void describePerDateDataAsync(const Model::DescribePerDateDataRequest& request, const DescribePerDateDataAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribePerDateDataOutcomeCallable describePerDateDataCallable(const Model::DescribePerDateDataRequest& request) const; + GetAccountProfileOutcome getAccountProfile(const Model::GetAccountProfileRequest &request)const; + void getAccountProfileAsync(const Model::GetAccountProfileRequest& request, const GetAccountProfileAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetAccountProfileOutcomeCallable getAccountProfileCallable(const Model::GetAccountProfileRequest& request) const; + DescribeTotalAndRateLineOutcome describeTotalAndRateLine(const Model::DescribeTotalAndRateLineRequest &request)const; + void describeTotalAndRateLineAsync(const Model::DescribeTotalAndRateLineRequest& request, const DescribeTotalAndRateLineAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeTotalAndRateLineOutcomeCallable describeTotalAndRateLineCallable(const Model::DescribeTotalAndRateLineRequest& request) const; + GetIpProfileOutcome getIpProfile(const Model::GetIpProfileRequest &request)const; + void getIpProfileAsync(const Model::GetIpProfileRequest& request, const GetIpProfileAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetIpProfileOutcomeCallable getIpProfileCallable(const Model::GetIpProfileRequest& request) const; + DescribeHitRateColumnOutcome describeHitRateColumn(const Model::DescribeHitRateColumnRequest &request)const; + void describeHitRateColumnAsync(const Model::DescribeHitRateColumnRequest& request, const DescribeHitRateColumnAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeHitRateColumnOutcomeCallable describeHitRateColumnCallable(const Model::DescribeHitRateColumnRequest& request) const; + DescribeHitRatePieOutcome describeHitRatePie(const Model::DescribeHitRatePieRequest &request)const; + void describeHitRatePieAsync(const Model::DescribeHitRatePieRequest& request, const DescribeHitRatePieAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeHitRatePieOutcomeCallable describeHitRatePieCallable(const Model::DescribeHitRatePieRequest& request) const; + + private: + std::shared_ptr endpointProvider_; + }; + } +} + +#endif // !ALIBABACLOUD_SAS-API_SAS-APICLIENT_H_ diff --git a/sas-api/include/alibabacloud/sas-api/Sas-apiExport.h b/sas-api/include/alibabacloud/sas-api/Sas-apiExport.h new file mode 100644 index 000000000..07ff71a2a --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/Sas-apiExport.h @@ -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_SAS-API_SAS-APIEXPORT_H_ +#define ALIBABACLOUD_SAS-API_SAS-APIEXPORT_H_ + +#include + +#if defined(ALIBABACLOUD_SHARED) +# if defined(ALIBABACLOUD_SAS-API_LIBRARY) +# define ALIBABACLOUD_SAS-API_EXPORT ALIBABACLOUD_DECL_EXPORT +# else +# define ALIBABACLOUD_SAS-API_EXPORT ALIBABACLOUD_DECL_IMPORT +# endif +#else +# define ALIBABACLOUD_SAS-API_EXPORT +#endif + +#endif // !ALIBABACLOUD_SAS-API_SAS-APIEXPORT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyRequest.h b/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyRequest.h new file mode 100644 index 000000000..b078976e2 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyRequest.h @@ -0,0 +1,51 @@ +/* + * 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_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeAccountProfileByKeyRequest : public RpcServiceRequest + { + + public: + DescribeAccountProfileByKeyRequest(); + ~DescribeAccountProfileByKeyRequest(); + + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + std::string getKeyword()const; + void setKeyword(const std::string& keyword); + + private: + std::string sourceIp_; + std::string keyword_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyResult.h b/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyResult.h new file mode 100644 index 000000000..72035205f --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyResult.h @@ -0,0 +1,61 @@ +/* + * 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_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYRESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeAccountProfileByKeyResult : public ServiceResult + { + public: + + + DescribeAccountProfileByKeyResult(); + explicit DescribeAccountProfileByKeyResult(const std::string &payload); + ~DescribeAccountProfileByKeyResult(); + std::string getPhone()const; + std::string getIp()const; + std::string getIpInfo()const; + std::string getPhoneInfo()const; + int getKeywordCount()const; + int getKeywordLimit()const; + + protected: + void parse(const std::string &payload); + private: + std::string phone_; + std::string ip_; + std::string ipInfo_; + std::string phoneInfo_; + int keywordCount_; + int keywordLimit_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYRESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyWordRequest.h b/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyWordRequest.h new file mode 100644 index 000000000..695d0c4b1 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyWordRequest.h @@ -0,0 +1,51 @@ +/* + * 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_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYWORDREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYWORDREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeAccountProfileByKeyWordRequest : public RpcServiceRequest + { + + public: + DescribeAccountProfileByKeyWordRequest(); + ~DescribeAccountProfileByKeyWordRequest(); + + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + std::string getKeyword()const; + void setKeyword(const std::string& keyword); + + private: + std::string sourceIp_; + std::string keyword_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYWORDREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyWordResult.h b/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyWordResult.h new file mode 100644 index 000000000..dad40de07 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeAccountProfileByKeyWordResult.h @@ -0,0 +1,57 @@ +/* + * 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_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYWORDRESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYWORDRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeAccountProfileByKeyWordResult : public ServiceResult + { + public: + + + DescribeAccountProfileByKeyWordResult(); + explicit DescribeAccountProfileByKeyWordResult(const std::string &payload); + ~DescribeAccountProfileByKeyWordResult(); + std::string getPhone()const; + std::string getIp()const; + std::string getIpInfo()const; + std::string getPhoneInfo()const; + + protected: + void parse(const std::string &payload); + private: + std::string phone_; + std::string ip_; + std::string ipInfo_; + std::string phoneInfo_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBEACCOUNTPROFILEBYKEYWORDRESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeHitRateColumnRequest.h b/sas-api/include/alibabacloud/sas-api/model/DescribeHitRateColumnRequest.h new file mode 100644 index 000000000..5836ea7ec --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeHitRateColumnRequest.h @@ -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_SAS-API_MODEL_DESCRIBEHITRATECOLUMNREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBEHITRATECOLUMNREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeHitRateColumnRequest : public RpcServiceRequest + { + + public: + DescribeHitRateColumnRequest(); + ~DescribeHitRateColumnRequest(); + + std::string getEndDate()const; + void setEndDate(const std::string& endDate); + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + int getHitDay()const; + void setHitDay(int hitDay); + std::string getStartDate()const; + void setStartDate(const std::string& startDate); + int getApiType()const; + void setApiType(int apiType); + + private: + std::string endDate_; + std::string sourceIp_; + int hitDay_; + std::string startDate_; + int apiType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBEHITRATECOLUMNREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeHitRateColumnResult.h b/sas-api/include/alibabacloud/sas-api/model/DescribeHitRateColumnResult.h new file mode 100644 index 000000000..259ca7a19 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeHitRateColumnResult.h @@ -0,0 +1,64 @@ +/* + * 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_SAS-API_MODEL_DESCRIBEHITRATECOLUMNRESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBEHITRATECOLUMNRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeHitRateColumnResult : public ServiceResult + { + public: + struct TimeScope + { + long start; + long interval; + }; + struct Item + { + long data; + std::string id; + std::string name; + }; + + + DescribeHitRateColumnResult(); + explicit DescribeHitRateColumnResult(const std::string &payload); + ~DescribeHitRateColumnResult(); + TimeScope getTimeScope()const; + std::vector getItems()const; + + protected: + void parse(const std::string &payload); + private: + TimeScope timeScope_; + std::vector items_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBEHITRATECOLUMNRESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeHitRatePieRequest.h b/sas-api/include/alibabacloud/sas-api/model/DescribeHitRatePieRequest.h new file mode 100644 index 000000000..fc6be0d1a --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeHitRatePieRequest.h @@ -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_SAS-API_MODEL_DESCRIBEHITRATEPIEREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBEHITRATEPIEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeHitRatePieRequest : public RpcServiceRequest + { + + public: + DescribeHitRatePieRequest(); + ~DescribeHitRatePieRequest(); + + std::string getEndDate()const; + void setEndDate(const std::string& endDate); + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + std::string getStartDate()const; + void setStartDate(const std::string& startDate); + int getHitDay()const; + void setHitDay(int hitDay); + int getApiType()const; + void setApiType(int apiType); + + private: + std::string endDate_; + std::string sourceIp_; + std::string startDate_; + int hitDay_; + int apiType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBEHITRATEPIEREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeHitRatePieResult.h b/sas-api/include/alibabacloud/sas-api/model/DescribeHitRatePieResult.h new file mode 100644 index 000000000..5a0964c02 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeHitRatePieResult.h @@ -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_SAS-API_MODEL_DESCRIBEHITRATEPIERESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBEHITRATEPIERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeHitRatePieResult : public ServiceResult + { + public: + struct Item + { + long data; + std::string name; + }; + + + DescribeHitRatePieResult(); + explicit DescribeHitRatePieResult(const std::string &payload); + ~DescribeHitRatePieResult(); + std::vector getItems()const; + + protected: + void parse(const std::string &payload); + private: + std::vector items_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBEHITRATEPIERESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribePerDateDataRequest.h b/sas-api/include/alibabacloud/sas-api/model/DescribePerDateDataRequest.h new file mode 100644 index 000000000..c3aed512f --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribePerDateDataRequest.h @@ -0,0 +1,51 @@ +/* + * 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_SAS-API_MODEL_DESCRIBEPERDATEDATAREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBEPERDATEDATAREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribePerDateDataRequest : public RpcServiceRequest + { + + public: + DescribePerDateDataRequest(); + ~DescribePerDateDataRequest(); + + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + int getApiType()const; + void setApiType(int apiType); + + private: + std::string sourceIp_; + int apiType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBEPERDATEDATAREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribePerDateDataResult.h b/sas-api/include/alibabacloud/sas-api/model/DescribePerDateDataResult.h new file mode 100644 index 000000000..dd39c1f1a --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribePerDateDataResult.h @@ -0,0 +1,85 @@ +/* + * 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_SAS-API_MODEL_DESCRIBEPERDATEDATARESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBEPERDATEDATARESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribePerDateDataResult : public ServiceResult + { + public: + struct DataViewItem + { + long isOpenCommonPort7d; + long isHiJack1d; + long hitRate; + long isC230d; + long isHiJack7d; + std::string dataTime; + long isNetAttack30d; + long isBotnet30d; + long callTimes; + long isCheatFlow1d; + long isCheatFlow30d; + long isBlackCampaign7d; + long isVirtualOperator; + long isCheatFlow7d; + long isOpenCommonPort1d; + long isBlackCampaign1d; + long isC27d; + long isNetAttack7d; + long isBlackCampaign30d; + long isBlackPhone; + long isNetAttack1d; + long isC21d; + long isProxy7d; + long isProxy1d; + long isBotnet7d; + long isOpenCommonPort30d; + long isProxy30d; + long isBotnet1d; + long isGreyPhone; + long isHiJack30d; + long totalHit; + }; + + + DescribePerDateDataResult(); + explicit DescribePerDateDataResult(const std::string &payload); + ~DescribePerDateDataResult(); + std::vector getDataView()const; + + protected: + void parse(const std::string &payload); + private: + std::vector dataView_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBEPERDATEDATARESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeThreatDistributeRequest.h b/sas-api/include/alibabacloud/sas-api/model/DescribeThreatDistributeRequest.h new file mode 100644 index 000000000..259471d63 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeThreatDistributeRequest.h @@ -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_SAS-API_MODEL_DESCRIBETHREATDISTRIBUTEREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBETHREATDISTRIBUTEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeThreatDistributeRequest : public RpcServiceRequest + { + + public: + DescribeThreatDistributeRequest(); + ~DescribeThreatDistributeRequest(); + + std::string getEndDate()const; + void setEndDate(const std::string& endDate); + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + int getHitDay()const; + void setHitDay(int hitDay); + std::string getStartDate()const; + void setStartDate(const std::string& startDate); + int getApiType()const; + void setApiType(int apiType); + + private: + std::string endDate_; + std::string sourceIp_; + int hitDay_; + std::string startDate_; + int apiType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBETHREATDISTRIBUTEREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeThreatDistributeResult.h b/sas-api/include/alibabacloud/sas-api/model/DescribeThreatDistributeResult.h new file mode 100644 index 000000000..ae639984a --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeThreatDistributeResult.h @@ -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_SAS-API_MODEL_DESCRIBETHREATDISTRIBUTERESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBETHREATDISTRIBUTERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeThreatDistributeResult : public ServiceResult + { + public: + struct Item + { + float data; + std::string id; + std::string name; + }; + + + DescribeThreatDistributeResult(); + explicit DescribeThreatDistributeResult(const std::string &payload); + ~DescribeThreatDistributeResult(); + std::vector getCategories()const; + std::vector getItems()const; + + protected: + void parse(const std::string &payload); + private: + std::vector categories_; + std::vector items_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBETHREATDISTRIBUTERESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeThreatTypeLinesRequest.h b/sas-api/include/alibabacloud/sas-api/model/DescribeThreatTypeLinesRequest.h new file mode 100644 index 000000000..05570fa03 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeThreatTypeLinesRequest.h @@ -0,0 +1,51 @@ +/* + * 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_SAS-API_MODEL_DESCRIBETHREATTYPELINESREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBETHREATTYPELINESREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeThreatTypeLinesRequest : public RpcServiceRequest + { + + public: + DescribeThreatTypeLinesRequest(); + ~DescribeThreatTypeLinesRequest(); + + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + int getApiType()const; + void setApiType(int apiType); + + private: + std::string sourceIp_; + int apiType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBETHREATTYPELINESREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeThreatTypeLinesResult.h b/sas-api/include/alibabacloud/sas-api/model/DescribeThreatTypeLinesResult.h new file mode 100644 index 000000000..045eaeea2 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeThreatTypeLinesResult.h @@ -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_SAS-API_MODEL_DESCRIBETHREATTYPELINESRESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBETHREATTYPELINESRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeThreatTypeLinesResult : public ServiceResult + { + public: + struct Item + { + float data; + std::string id; + std::string name; + }; + + + DescribeThreatTypeLinesResult(); + explicit DescribeThreatTypeLinesResult(const std::string &payload); + ~DescribeThreatTypeLinesResult(); + std::vector getCategories()const; + std::vector getItems()const; + + protected: + void parse(const std::string &payload); + private: + std::vector categories_; + std::vector items_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBETHREATTYPELINESRESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeTotalAndRateLineRequest.h b/sas-api/include/alibabacloud/sas-api/model/DescribeTotalAndRateLineRequest.h new file mode 100644 index 000000000..9ce9a2161 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeTotalAndRateLineRequest.h @@ -0,0 +1,51 @@ +/* + * 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_SAS-API_MODEL_DESCRIBETOTALANDRATELINEREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBETOTALANDRATELINEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeTotalAndRateLineRequest : public RpcServiceRequest + { + + public: + DescribeTotalAndRateLineRequest(); + ~DescribeTotalAndRateLineRequest(); + + std::string getSourceIp()const; + void setSourceIp(const std::string& sourceIp); + int getApiType()const; + void setApiType(int apiType); + + private: + std::string sourceIp_; + int apiType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBETOTALANDRATELINEREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/DescribeTotalAndRateLineResult.h b/sas-api/include/alibabacloud/sas-api/model/DescribeTotalAndRateLineResult.h new file mode 100644 index 000000000..2d4938437 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/DescribeTotalAndRateLineResult.h @@ -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_SAS-API_MODEL_DESCRIBETOTALANDRATELINERESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_DESCRIBETOTALANDRATELINERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT DescribeTotalAndRateLineResult : public ServiceResult + { + public: + struct Item + { + float data; + std::string id; + std::string name; + }; + + + DescribeTotalAndRateLineResult(); + explicit DescribeTotalAndRateLineResult(const std::string &payload); + ~DescribeTotalAndRateLineResult(); + std::vector getCategories()const; + std::vector getItems()const; + + protected: + void parse(const std::string &payload); + private: + std::vector categories_; + std::vector items_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_DESCRIBETOTALANDRATELINERESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/GetAccountProfileRequest.h b/sas-api/include/alibabacloud/sas-api/model/GetAccountProfileRequest.h new file mode 100644 index 000000000..2b69845bc --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/GetAccountProfileRequest.h @@ -0,0 +1,81 @@ +/* + * 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_SAS-API_MODEL_GETACCOUNTPROFILEREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_GETACCOUNTPROFILEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT GetAccountProfileRequest : public RpcServiceRequest + { + + public: + GetAccountProfileRequest(); + ~GetAccountProfileRequest(); + + std::string getDeviceIdMd5()const; + void setDeviceIdMd5(const std::string& deviceIdMd5); + int getCarrier()const; + void setCarrier(int carrier); + std::string getOs()const; + void setOs(const std::string& os); + std::string getPhone()const; + void setPhone(const std::string& phone); + std::string getRequestUrl()const; + void setRequestUrl(const std::string& requestUrl); + std::string getIp()const; + void setIp(const std::string& ip); + std::string getUserAgent()const; + void setUserAgent(const std::string& userAgent); + int getConnectionType()const; + void setConnectionType(int connectionType); + int getSensType()const; + void setSensType(int sensType); + int getDeviceType()const; + void setDeviceType(int deviceType); + long getAccessTimestamp()const; + void setAccessTimestamp(long accessTimestamp); + int getBusinessType()const; + void setBusinessType(int businessType); + + private: + std::string deviceIdMd5_; + int carrier_; + std::string os_; + std::string phone_; + std::string requestUrl_; + std::string ip_; + std::string userAgent_; + int connectionType_; + int sensType_; + int deviceType_; + long accessTimestamp_; + int businessType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_GETACCOUNTPROFILEREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/GetAccountProfileResult.h b/sas-api/include/alibabacloud/sas-api/model/GetAccountProfileResult.h new file mode 100644 index 000000000..b70e3bca7 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/GetAccountProfileResult.h @@ -0,0 +1,64 @@ +/* + * 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_SAS-API_MODEL_GETACCOUNTPROFILERESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_GETACCOUNTPROFILERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT GetAccountProfileResult : public ServiceResult + { + public: + struct Data + { + std::string phone; + std::string ip; + std::string ipInfo; + std::string phoneInfo; + }; + + + GetAccountProfileResult(); + explicit GetAccountProfileResult(const std::string &payload); + ~GetAccountProfileResult(); + std::string getMessage()const; + Data getData()const; + int getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string message_; + Data data_; + int code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_GETACCOUNTPROFILERESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/GetInstanceCountRequest.h b/sas-api/include/alibabacloud/sas-api/model/GetInstanceCountRequest.h new file mode 100644 index 000000000..59c9dd3cb --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/GetInstanceCountRequest.h @@ -0,0 +1,48 @@ +/* + * 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_SAS-API_MODEL_GETINSTANCECOUNTREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_GETINSTANCECOUNTREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT GetInstanceCountRequest : public RpcServiceRequest + { + + public: + GetInstanceCountRequest(); + ~GetInstanceCountRequest(); + + long getOwnerId()const; + void setOwnerId(long ownerId); + + private: + long ownerId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_GETINSTANCECOUNTREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/GetInstanceCountResult.h b/sas-api/include/alibabacloud/sas-api/model/GetInstanceCountResult.h new file mode 100644 index 000000000..d05242a96 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/GetInstanceCountResult.h @@ -0,0 +1,57 @@ +/* + * 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_SAS-API_MODEL_GETINSTANCECOUNTRESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_GETINSTANCECOUNTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT GetInstanceCountResult : public ServiceResult + { + public: + + + GetInstanceCountResult(); + explicit GetInstanceCountResult(const std::string &payload); + ~GetInstanceCountResult(); + std::string getMessage()const; + int getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string message_; + int data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_GETINSTANCECOUNTRESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/GetIpProfileRequest.h b/sas-api/include/alibabacloud/sas-api/model/GetIpProfileRequest.h new file mode 100644 index 000000000..d6f8a739a --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/GetIpProfileRequest.h @@ -0,0 +1,75 @@ +/* + * 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_SAS-API_MODEL_GETIPPROFILEREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_GETIPPROFILEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT GetIpProfileRequest : public RpcServiceRequest + { + + public: + GetIpProfileRequest(); + ~GetIpProfileRequest(); + + std::string getDeviceIdMd5()const; + void setDeviceIdMd5(const std::string& deviceIdMd5); + int getCarrier()const; + void setCarrier(int carrier); + std::string getOs()const; + void setOs(const std::string& os); + std::string getRequestUrl()const; + void setRequestUrl(const std::string& requestUrl); + std::string getIp()const; + void setIp(const std::string& ip); + std::string getUserAgent()const; + void setUserAgent(const std::string& userAgent); + int getConnectionType()const; + void setConnectionType(int connectionType); + int getSensType()const; + void setSensType(int sensType); + int getDeviceType()const; + void setDeviceType(int deviceType); + int getBusinessType()const; + void setBusinessType(int businessType); + + private: + std::string deviceIdMd5_; + int carrier_; + std::string os_; + std::string requestUrl_; + std::string ip_; + std::string userAgent_; + int connectionType_; + int sensType_; + int deviceType_; + int businessType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_GETIPPROFILEREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/GetIpProfileResult.h b/sas-api/include/alibabacloud/sas-api/model/GetIpProfileResult.h new file mode 100644 index 000000000..8d7664de6 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/GetIpProfileResult.h @@ -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. + */ + +#ifndef ALIBABACLOUD_SAS-API_MODEL_GETIPPROFILERESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_GETIPPROFILERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT GetIpProfileResult : public ServiceResult + { + public: + struct Data + { + std::string ip; + std::string info; + }; + + + GetIpProfileResult(); + explicit GetIpProfileResult(const std::string &payload); + ~GetIpProfileResult(); + std::string getMessage()const; + Data getData()const; + int getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string message_; + Data data_; + int code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_GETIPPROFILERESULT_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/GetPhoneProfileRequest.h b/sas-api/include/alibabacloud/sas-api/model/GetPhoneProfileRequest.h new file mode 100644 index 000000000..fc1ffbc77 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/GetPhoneProfileRequest.h @@ -0,0 +1,57 @@ +/* + * 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_SAS-API_MODEL_GETPHONEPROFILEREQUEST_H_ +#define ALIBABACLOUD_SAS-API_MODEL_GETPHONEPROFILEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT GetPhoneProfileRequest : public RpcServiceRequest + { + + public: + GetPhoneProfileRequest(); + ~GetPhoneProfileRequest(); + + std::string getPhone()const; + void setPhone(const std::string& phone); + int getSensType()const; + void setSensType(int sensType); + std::string getDataVersion()const; + void setDataVersion(const std::string& dataVersion); + int getBusinessType()const; + void setBusinessType(int businessType); + + private: + std::string phone_; + int sensType_; + std::string dataVersion_; + int businessType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_GETPHONEPROFILEREQUEST_H_ \ No newline at end of file diff --git a/sas-api/include/alibabacloud/sas-api/model/GetPhoneProfileResult.h b/sas-api/include/alibabacloud/sas-api/model/GetPhoneProfileResult.h new file mode 100644 index 000000000..f8b3acfb5 --- /dev/null +++ b/sas-api/include/alibabacloud/sas-api/model/GetPhoneProfileResult.h @@ -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. + */ + +#ifndef ALIBABACLOUD_SAS-API_MODEL_GETPHONEPROFILERESULT_H_ +#define ALIBABACLOUD_SAS-API_MODEL_GETPHONEPROFILERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas-api + { + namespace Model + { + class ALIBABACLOUD_SAS-API_EXPORT GetPhoneProfileResult : public ServiceResult + { + public: + struct Data + { + std::string phone; + std::string info; + }; + + + GetPhoneProfileResult(); + explicit GetPhoneProfileResult(const std::string &payload); + ~GetPhoneProfileResult(); + std::string getMessage()const; + Data getData()const; + int getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string message_; + Data data_; + int code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS-API_MODEL_GETPHONEPROFILERESULT_H_ \ No newline at end of file diff --git a/sas-api/src/Sas-apiClient.cc b/sas-api/src/Sas-apiClient.cc new file mode 100644 index 000000000..c4a35e03d --- /dev/null +++ b/sas-api/src/Sas-apiClient.cc @@ -0,0 +1,485 @@ +/* + * 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 +#include + +using namespace AlibabaCloud; +using namespace AlibabaCloud::Location; +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +namespace +{ + const std::string SERVICE_NAME = "Sas-api"; +} + +Sas-apiClient::Sas-apiClient(const Credentials &credentials, const ClientConfiguration &configuration) : + RpcServiceClient(SERVICE_NAME, std::make_shared(credentials), configuration) +{ + auto locationClient = std::make_shared(credentials, configuration); + endpointProvider_ = std::make_shared(locationClient, configuration.regionId(), SERVICE_NAME, "sas-api"); +} + +Sas-apiClient::Sas-apiClient(const std::shared_ptr& credentialsProvider, const ClientConfiguration & configuration) : + RpcServiceClient(SERVICE_NAME, credentialsProvider, configuration) +{ + auto locationClient = std::make_shared(credentialsProvider, configuration); + endpointProvider_ = std::make_shared(locationClient, configuration.regionId(), SERVICE_NAME, "sas-api"); +} + +Sas-apiClient::Sas-apiClient(const std::string & accessKeyId, const std::string & accessKeySecret, const ClientConfiguration & configuration) : + RpcServiceClient(SERVICE_NAME, std::make_shared(accessKeyId, accessKeySecret), configuration) +{ + auto locationClient = std::make_shared(accessKeyId, accessKeySecret, configuration); + endpointProvider_ = std::make_shared(locationClient, configuration.regionId(), SERVICE_NAME, "sas-api"); +} + +Sas-apiClient::~Sas-apiClient() +{} + +Sas-apiClient::DescribeAccountProfileByKeyWordOutcome Sas-apiClient::describeAccountProfileByKeyWord(const DescribeAccountProfileByKeyWordRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeAccountProfileByKeyWordOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeAccountProfileByKeyWordOutcome(DescribeAccountProfileByKeyWordResult(outcome.result())); + else + return DescribeAccountProfileByKeyWordOutcome(outcome.error()); +} + +void Sas-apiClient::describeAccountProfileByKeyWordAsync(const DescribeAccountProfileByKeyWordRequest& request, const DescribeAccountProfileByKeyWordAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeAccountProfileByKeyWord(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::DescribeAccountProfileByKeyWordOutcomeCallable Sas-apiClient::describeAccountProfileByKeyWordCallable(const DescribeAccountProfileByKeyWordRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeAccountProfileByKeyWord(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::DescribeThreatTypeLinesOutcome Sas-apiClient::describeThreatTypeLines(const DescribeThreatTypeLinesRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeThreatTypeLinesOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeThreatTypeLinesOutcome(DescribeThreatTypeLinesResult(outcome.result())); + else + return DescribeThreatTypeLinesOutcome(outcome.error()); +} + +void Sas-apiClient::describeThreatTypeLinesAsync(const DescribeThreatTypeLinesRequest& request, const DescribeThreatTypeLinesAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeThreatTypeLines(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::DescribeThreatTypeLinesOutcomeCallable Sas-apiClient::describeThreatTypeLinesCallable(const DescribeThreatTypeLinesRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeThreatTypeLines(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::DescribeThreatDistributeOutcome Sas-apiClient::describeThreatDistribute(const DescribeThreatDistributeRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeThreatDistributeOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeThreatDistributeOutcome(DescribeThreatDistributeResult(outcome.result())); + else + return DescribeThreatDistributeOutcome(outcome.error()); +} + +void Sas-apiClient::describeThreatDistributeAsync(const DescribeThreatDistributeRequest& request, const DescribeThreatDistributeAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeThreatDistribute(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::DescribeThreatDistributeOutcomeCallable Sas-apiClient::describeThreatDistributeCallable(const DescribeThreatDistributeRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeThreatDistribute(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::GetPhoneProfileOutcome Sas-apiClient::getPhoneProfile(const GetPhoneProfileRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetPhoneProfileOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetPhoneProfileOutcome(GetPhoneProfileResult(outcome.result())); + else + return GetPhoneProfileOutcome(outcome.error()); +} + +void Sas-apiClient::getPhoneProfileAsync(const GetPhoneProfileRequest& request, const GetPhoneProfileAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getPhoneProfile(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::GetPhoneProfileOutcomeCallable Sas-apiClient::getPhoneProfileCallable(const GetPhoneProfileRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getPhoneProfile(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::DescribeAccountProfileByKeyOutcome Sas-apiClient::describeAccountProfileByKey(const DescribeAccountProfileByKeyRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeAccountProfileByKeyOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeAccountProfileByKeyOutcome(DescribeAccountProfileByKeyResult(outcome.result())); + else + return DescribeAccountProfileByKeyOutcome(outcome.error()); +} + +void Sas-apiClient::describeAccountProfileByKeyAsync(const DescribeAccountProfileByKeyRequest& request, const DescribeAccountProfileByKeyAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeAccountProfileByKey(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::DescribeAccountProfileByKeyOutcomeCallable Sas-apiClient::describeAccountProfileByKeyCallable(const DescribeAccountProfileByKeyRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeAccountProfileByKey(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::GetInstanceCountOutcome Sas-apiClient::getInstanceCount(const GetInstanceCountRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetInstanceCountOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetInstanceCountOutcome(GetInstanceCountResult(outcome.result())); + else + return GetInstanceCountOutcome(outcome.error()); +} + +void Sas-apiClient::getInstanceCountAsync(const GetInstanceCountRequest& request, const GetInstanceCountAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getInstanceCount(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::GetInstanceCountOutcomeCallable Sas-apiClient::getInstanceCountCallable(const GetInstanceCountRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getInstanceCount(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::DescribePerDateDataOutcome Sas-apiClient::describePerDateData(const DescribePerDateDataRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribePerDateDataOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribePerDateDataOutcome(DescribePerDateDataResult(outcome.result())); + else + return DescribePerDateDataOutcome(outcome.error()); +} + +void Sas-apiClient::describePerDateDataAsync(const DescribePerDateDataRequest& request, const DescribePerDateDataAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describePerDateData(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::DescribePerDateDataOutcomeCallable Sas-apiClient::describePerDateDataCallable(const DescribePerDateDataRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describePerDateData(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::GetAccountProfileOutcome Sas-apiClient::getAccountProfile(const GetAccountProfileRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetAccountProfileOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetAccountProfileOutcome(GetAccountProfileResult(outcome.result())); + else + return GetAccountProfileOutcome(outcome.error()); +} + +void Sas-apiClient::getAccountProfileAsync(const GetAccountProfileRequest& request, const GetAccountProfileAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getAccountProfile(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::GetAccountProfileOutcomeCallable Sas-apiClient::getAccountProfileCallable(const GetAccountProfileRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getAccountProfile(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::DescribeTotalAndRateLineOutcome Sas-apiClient::describeTotalAndRateLine(const DescribeTotalAndRateLineRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeTotalAndRateLineOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeTotalAndRateLineOutcome(DescribeTotalAndRateLineResult(outcome.result())); + else + return DescribeTotalAndRateLineOutcome(outcome.error()); +} + +void Sas-apiClient::describeTotalAndRateLineAsync(const DescribeTotalAndRateLineRequest& request, const DescribeTotalAndRateLineAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeTotalAndRateLine(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::DescribeTotalAndRateLineOutcomeCallable Sas-apiClient::describeTotalAndRateLineCallable(const DescribeTotalAndRateLineRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeTotalAndRateLine(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::GetIpProfileOutcome Sas-apiClient::getIpProfile(const GetIpProfileRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetIpProfileOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetIpProfileOutcome(GetIpProfileResult(outcome.result())); + else + return GetIpProfileOutcome(outcome.error()); +} + +void Sas-apiClient::getIpProfileAsync(const GetIpProfileRequest& request, const GetIpProfileAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getIpProfile(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::GetIpProfileOutcomeCallable Sas-apiClient::getIpProfileCallable(const GetIpProfileRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getIpProfile(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::DescribeHitRateColumnOutcome Sas-apiClient::describeHitRateColumn(const DescribeHitRateColumnRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeHitRateColumnOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeHitRateColumnOutcome(DescribeHitRateColumnResult(outcome.result())); + else + return DescribeHitRateColumnOutcome(outcome.error()); +} + +void Sas-apiClient::describeHitRateColumnAsync(const DescribeHitRateColumnRequest& request, const DescribeHitRateColumnAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeHitRateColumn(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::DescribeHitRateColumnOutcomeCallable Sas-apiClient::describeHitRateColumnCallable(const DescribeHitRateColumnRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeHitRateColumn(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +Sas-apiClient::DescribeHitRatePieOutcome Sas-apiClient::describeHitRatePie(const DescribeHitRatePieRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeHitRatePieOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeHitRatePieOutcome(DescribeHitRatePieResult(outcome.result())); + else + return DescribeHitRatePieOutcome(outcome.error()); +} + +void Sas-apiClient::describeHitRatePieAsync(const DescribeHitRatePieRequest& request, const DescribeHitRatePieAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeHitRatePie(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +Sas-apiClient::DescribeHitRatePieOutcomeCallable Sas-apiClient::describeHitRatePieCallable(const DescribeHitRatePieRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeHitRatePie(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + diff --git a/sas-api/src/model/DescribeAccountProfileByKeyRequest.cc b/sas-api/src/model/DescribeAccountProfileByKeyRequest.cc new file mode 100644 index 000000000..27164c9a2 --- /dev/null +++ b/sas-api/src/model/DescribeAccountProfileByKeyRequest.cc @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Sas-api::Model::DescribeAccountProfileByKeyRequest; + +DescribeAccountProfileByKeyRequest::DescribeAccountProfileByKeyRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "DescribeAccountProfileByKey") +{} + +DescribeAccountProfileByKeyRequest::~DescribeAccountProfileByKeyRequest() +{} + +std::string DescribeAccountProfileByKeyRequest::getSourceIp()const +{ + return sourceIp_; +} + +void DescribeAccountProfileByKeyRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +std::string DescribeAccountProfileByKeyRequest::getKeyword()const +{ + return keyword_; +} + +void DescribeAccountProfileByKeyRequest::setKeyword(const std::string& keyword) +{ + keyword_ = keyword; + setParameter("Keyword", keyword); +} + diff --git a/sas-api/src/model/DescribeAccountProfileByKeyResult.cc b/sas-api/src/model/DescribeAccountProfileByKeyResult.cc new file mode 100644 index 000000000..33f7f5585 --- /dev/null +++ b/sas-api/src/model/DescribeAccountProfileByKeyResult.cc @@ -0,0 +1,87 @@ +/* + * 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 +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +DescribeAccountProfileByKeyResult::DescribeAccountProfileByKeyResult() : + ServiceResult() +{} + +DescribeAccountProfileByKeyResult::DescribeAccountProfileByKeyResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeAccountProfileByKeyResult::~DescribeAccountProfileByKeyResult() +{} + +void DescribeAccountProfileByKeyResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + + setRequestId(value["RequestId"].asString()); + if(!value["Ip"].isNull()) + ip_ = value["Ip"].asString(); + if(!value["IpInfo"].isNull()) + ipInfo_ = value["IpInfo"].asString(); + if(!value["Phone"].isNull()) + phone_ = value["Phone"].asString(); + if(!value["PhoneInfo"].isNull()) + phoneInfo_ = value["PhoneInfo"].asString(); + if(!value["KeywordCount"].isNull()) + keywordCount_ = std::stoi(value["KeywordCount"].asString()); + if(!value["KeywordLimit"].isNull()) + keywordLimit_ = std::stoi(value["KeywordLimit"].asString()); + +} + +std::string DescribeAccountProfileByKeyResult::getPhone()const +{ + return phone_; +} + +std::string DescribeAccountProfileByKeyResult::getIp()const +{ + return ip_; +} + +std::string DescribeAccountProfileByKeyResult::getIpInfo()const +{ + return ipInfo_; +} + +std::string DescribeAccountProfileByKeyResult::getPhoneInfo()const +{ + return phoneInfo_; +} + +int DescribeAccountProfileByKeyResult::getKeywordCount()const +{ + return keywordCount_; +} + +int DescribeAccountProfileByKeyResult::getKeywordLimit()const +{ + return keywordLimit_; +} + diff --git a/sas-api/src/model/DescribeAccountProfileByKeyWordRequest.cc b/sas-api/src/model/DescribeAccountProfileByKeyWordRequest.cc new file mode 100644 index 000000000..4ac8dc191 --- /dev/null +++ b/sas-api/src/model/DescribeAccountProfileByKeyWordRequest.cc @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Sas-api::Model::DescribeAccountProfileByKeyWordRequest; + +DescribeAccountProfileByKeyWordRequest::DescribeAccountProfileByKeyWordRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "DescribeAccountProfileByKeyWord") +{} + +DescribeAccountProfileByKeyWordRequest::~DescribeAccountProfileByKeyWordRequest() +{} + +std::string DescribeAccountProfileByKeyWordRequest::getSourceIp()const +{ + return sourceIp_; +} + +void DescribeAccountProfileByKeyWordRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +std::string DescribeAccountProfileByKeyWordRequest::getKeyword()const +{ + return keyword_; +} + +void DescribeAccountProfileByKeyWordRequest::setKeyword(const std::string& keyword) +{ + keyword_ = keyword; + setParameter("Keyword", keyword); +} + diff --git a/sas-api/src/model/DescribeAccountProfileByKeyWordResult.cc b/sas-api/src/model/DescribeAccountProfileByKeyWordResult.cc new file mode 100644 index 000000000..fbb95be1b --- /dev/null +++ b/sas-api/src/model/DescribeAccountProfileByKeyWordResult.cc @@ -0,0 +1,73 @@ +/* + * 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 +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +DescribeAccountProfileByKeyWordResult::DescribeAccountProfileByKeyWordResult() : + ServiceResult() +{} + +DescribeAccountProfileByKeyWordResult::DescribeAccountProfileByKeyWordResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeAccountProfileByKeyWordResult::~DescribeAccountProfileByKeyWordResult() +{} + +void DescribeAccountProfileByKeyWordResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + + setRequestId(value["RequestId"].asString()); + if(!value["Ip"].isNull()) + ip_ = value["Ip"].asString(); + if(!value["IpInfo"].isNull()) + ipInfo_ = value["IpInfo"].asString(); + if(!value["Phone"].isNull()) + phone_ = value["Phone"].asString(); + if(!value["PhoneInfo"].isNull()) + phoneInfo_ = value["PhoneInfo"].asString(); + +} + +std::string DescribeAccountProfileByKeyWordResult::getPhone()const +{ + return phone_; +} + +std::string DescribeAccountProfileByKeyWordResult::getIp()const +{ + return ip_; +} + +std::string DescribeAccountProfileByKeyWordResult::getIpInfo()const +{ + return ipInfo_; +} + +std::string DescribeAccountProfileByKeyWordResult::getPhoneInfo()const +{ + return phoneInfo_; +} + diff --git a/sas-api/src/model/DescribeHitRateColumnRequest.cc b/sas-api/src/model/DescribeHitRateColumnRequest.cc new file mode 100644 index 000000000..79f619969 --- /dev/null +++ b/sas-api/src/model/DescribeHitRateColumnRequest.cc @@ -0,0 +1,82 @@ +/* + * 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 + +using AlibabaCloud::Sas-api::Model::DescribeHitRateColumnRequest; + +DescribeHitRateColumnRequest::DescribeHitRateColumnRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "DescribeHitRateColumn") +{} + +DescribeHitRateColumnRequest::~DescribeHitRateColumnRequest() +{} + +std::string DescribeHitRateColumnRequest::getEndDate()const +{ + return endDate_; +} + +void DescribeHitRateColumnRequest::setEndDate(const std::string& endDate) +{ + endDate_ = endDate; + setParameter("EndDate", endDate); +} + +std::string DescribeHitRateColumnRequest::getSourceIp()const +{ + return sourceIp_; +} + +void DescribeHitRateColumnRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +int DescribeHitRateColumnRequest::getHitDay()const +{ + return hitDay_; +} + +void DescribeHitRateColumnRequest::setHitDay(int hitDay) +{ + hitDay_ = hitDay; + setParameter("HitDay", std::to_string(hitDay)); +} + +std::string DescribeHitRateColumnRequest::getStartDate()const +{ + return startDate_; +} + +void DescribeHitRateColumnRequest::setStartDate(const std::string& startDate) +{ + startDate_ = startDate; + setParameter("StartDate", startDate); +} + +int DescribeHitRateColumnRequest::getApiType()const +{ + return apiType_; +} + +void DescribeHitRateColumnRequest::setApiType(int apiType) +{ + apiType_ = apiType; + setParameter("ApiType", std::to_string(apiType)); +} + diff --git a/sas-api/src/model/DescribeHitRateColumnResult.cc b/sas-api/src/model/DescribeHitRateColumnResult.cc new file mode 100644 index 000000000..bb03f5d95 --- /dev/null +++ b/sas-api/src/model/DescribeHitRateColumnResult.cc @@ -0,0 +1,72 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +DescribeHitRateColumnResult::DescribeHitRateColumnResult() : + ServiceResult() +{} + +DescribeHitRateColumnResult::DescribeHitRateColumnResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeHitRateColumnResult::~DescribeHitRateColumnResult() +{} + +void DescribeHitRateColumnResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + + setRequestId(value["RequestId"].asString()); + auto allItems = value["Items"]["Item"]; + for (auto value : allItems) + { + Item itemsObject; + if(!value["Data"].isNull()) + itemsObject.data = std::stol(value["Data"].asString()); + if(!value["Id"].isNull()) + itemsObject.id = value["Id"].asString(); + if(!value["Name"].isNull()) + itemsObject.name = value["Name"].asString(); + items_.push_back(itemsObject); + } + auto timeScopeNode = value["TimeScope"]; + if(!timeScopeNode["Interval"].isNull()) + timeScope_.interval = std::stol(timeScopeNode["Interval"].asString()); + if(!timeScopeNode["Start"].isNull()) + timeScope_.start = std::stol(timeScopeNode["Start"].asString()); + +} + +DescribeHitRateColumnResult::TimeScope DescribeHitRateColumnResult::getTimeScope()const +{ + return timeScope_; +} + +std::vector DescribeHitRateColumnResult::getItems()const +{ + return items_; +} + diff --git a/sas-api/src/model/DescribeHitRatePieRequest.cc b/sas-api/src/model/DescribeHitRatePieRequest.cc new file mode 100644 index 000000000..67164df45 --- /dev/null +++ b/sas-api/src/model/DescribeHitRatePieRequest.cc @@ -0,0 +1,82 @@ +/* + * 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 + +using AlibabaCloud::Sas-api::Model::DescribeHitRatePieRequest; + +DescribeHitRatePieRequest::DescribeHitRatePieRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "DescribeHitRatePie") +{} + +DescribeHitRatePieRequest::~DescribeHitRatePieRequest() +{} + +std::string DescribeHitRatePieRequest::getEndDate()const +{ + return endDate_; +} + +void DescribeHitRatePieRequest::setEndDate(const std::string& endDate) +{ + endDate_ = endDate; + setParameter("EndDate", endDate); +} + +std::string DescribeHitRatePieRequest::getSourceIp()const +{ + return sourceIp_; +} + +void DescribeHitRatePieRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +std::string DescribeHitRatePieRequest::getStartDate()const +{ + return startDate_; +} + +void DescribeHitRatePieRequest::setStartDate(const std::string& startDate) +{ + startDate_ = startDate; + setParameter("StartDate", startDate); +} + +int DescribeHitRatePieRequest::getHitDay()const +{ + return hitDay_; +} + +void DescribeHitRatePieRequest::setHitDay(int hitDay) +{ + hitDay_ = hitDay; + setParameter("HitDay", std::to_string(hitDay)); +} + +int DescribeHitRatePieRequest::getApiType()const +{ + return apiType_; +} + +void DescribeHitRatePieRequest::setApiType(int apiType) +{ + apiType_ = apiType; + setParameter("ApiType", std::to_string(apiType)); +} + diff --git a/sas-api/src/model/DescribeHitRatePieResult.cc b/sas-api/src/model/DescribeHitRatePieResult.cc new file mode 100644 index 000000000..e040a5115 --- /dev/null +++ b/sas-api/src/model/DescribeHitRatePieResult.cc @@ -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. + */ + +#include +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +DescribeHitRatePieResult::DescribeHitRatePieResult() : + ServiceResult() +{} + +DescribeHitRatePieResult::DescribeHitRatePieResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeHitRatePieResult::~DescribeHitRatePieResult() +{} + +void DescribeHitRatePieResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + + setRequestId(value["RequestId"].asString()); + auto allItems = value["Items"]["Item"]; + for (auto value : allItems) + { + Item itemsObject; + if(!value["Data"].isNull()) + itemsObject.data = std::stol(value["Data"].asString()); + if(!value["Name"].isNull()) + itemsObject.name = value["Name"].asString(); + items_.push_back(itemsObject); + } + +} + +std::vector DescribeHitRatePieResult::getItems()const +{ + return items_; +} + diff --git a/sas-api/src/model/DescribePerDateDataRequest.cc b/sas-api/src/model/DescribePerDateDataRequest.cc new file mode 100644 index 000000000..ef6765dc7 --- /dev/null +++ b/sas-api/src/model/DescribePerDateDataRequest.cc @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Sas-api::Model::DescribePerDateDataRequest; + +DescribePerDateDataRequest::DescribePerDateDataRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "DescribePerDateData") +{} + +DescribePerDateDataRequest::~DescribePerDateDataRequest() +{} + +std::string DescribePerDateDataRequest::getSourceIp()const +{ + return sourceIp_; +} + +void DescribePerDateDataRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +int DescribePerDateDataRequest::getApiType()const +{ + return apiType_; +} + +void DescribePerDateDataRequest::setApiType(int apiType) +{ + apiType_ = apiType; + setParameter("ApiType", std::to_string(apiType)); +} + diff --git a/sas-api/src/model/DescribePerDateDataResult.cc b/sas-api/src/model/DescribePerDateDataResult.cc new file mode 100644 index 000000000..404464995 --- /dev/null +++ b/sas-api/src/model/DescribePerDateDataResult.cc @@ -0,0 +1,118 @@ +/* + * 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 +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +DescribePerDateDataResult::DescribePerDateDataResult() : + ServiceResult() +{} + +DescribePerDateDataResult::DescribePerDateDataResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribePerDateDataResult::~DescribePerDateDataResult() +{} + +void DescribePerDateDataResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + + setRequestId(value["RequestId"].asString()); + auto allDataView = value["DataView"]["dataViewItem"]; + for (auto value : allDataView) + { + DataViewItem dataViewObject; + if(!value["DataTime"].isNull()) + dataViewObject.dataTime = value["DataTime"].asString(); + if(!value["CallTimes"].isNull()) + dataViewObject.callTimes = std::stol(value["CallTimes"].asString()); + if(!value["TotalHit"].isNull()) + dataViewObject.totalHit = std::stol(value["TotalHit"].asString()); + if(!value["HitRate"].isNull()) + dataViewObject.hitRate = std::stol(value["HitRate"].asString()); + if(!value["IsGreyPhone"].isNull()) + dataViewObject.isGreyPhone = std::stol(value["IsGreyPhone"].asString()); + if(!value["IsBlackPhone"].isNull()) + dataViewObject.isBlackPhone = std::stol(value["IsBlackPhone"].asString()); + if(!value["IsVirtualOperator"].isNull()) + dataViewObject.isVirtualOperator = std::stol(value["IsVirtualOperator"].asString()); + if(!value["IsOpenCommonPort1d"].isNull()) + dataViewObject.isOpenCommonPort1d = std::stol(value["IsOpenCommonPort1d"].asString()); + if(!value["IsOpenCommonPort7d"].isNull()) + dataViewObject.isOpenCommonPort7d = std::stol(value["IsOpenCommonPort7d"].asString()); + if(!value["IsOpenCommonPort30d"].isNull()) + dataViewObject.isOpenCommonPort30d = std::stol(value["IsOpenCommonPort30d"].asString()); + if(!value["IsCheatFlow1d"].isNull()) + dataViewObject.isCheatFlow1d = std::stol(value["IsCheatFlow1d"].asString()); + if(!value["IsCheatFlow7d"].isNull()) + dataViewObject.isCheatFlow7d = std::stol(value["IsCheatFlow7d"].asString()); + if(!value["IsCheatFlow30d"].isNull()) + dataViewObject.isCheatFlow30d = std::stol(value["IsCheatFlow30d"].asString()); + if(!value["IsProxy1d"].isNull()) + dataViewObject.isProxy1d = std::stol(value["IsProxy1d"].asString()); + if(!value["IsProxy7d"].isNull()) + dataViewObject.isProxy7d = std::stol(value["IsProxy7d"].asString()); + if(!value["IsProxy30d"].isNull()) + dataViewObject.isProxy30d = std::stol(value["IsProxy30d"].asString()); + if(!value["IsHiJack1d"].isNull()) + dataViewObject.isHiJack1d = std::stol(value["IsHiJack1d"].asString()); + if(!value["IsHiJack7d"].isNull()) + dataViewObject.isHiJack7d = std::stol(value["IsHiJack7d"].asString()); + if(!value["IsHiJack30d"].isNull()) + dataViewObject.isHiJack30d = std::stol(value["IsHiJack30d"].asString()); + if(!value["IsC21d"].isNull()) + dataViewObject.isC21d = std::stol(value["IsC21d"].asString()); + if(!value["IsC27d"].isNull()) + dataViewObject.isC27d = std::stol(value["IsC27d"].asString()); + if(!value["IsC230d"].isNull()) + dataViewObject.isC230d = std::stol(value["IsC230d"].asString()); + if(!value["IsBotnet1d"].isNull()) + dataViewObject.isBotnet1d = std::stol(value["IsBotnet1d"].asString()); + if(!value["IsBotnet7d"].isNull()) + dataViewObject.isBotnet7d = std::stol(value["IsBotnet7d"].asString()); + if(!value["IsBotnet30d"].isNull()) + dataViewObject.isBotnet30d = std::stol(value["IsBotnet30d"].asString()); + if(!value["IsNetAttack1d"].isNull()) + dataViewObject.isNetAttack1d = std::stol(value["IsNetAttack1d"].asString()); + if(!value["IsNetAttack7d"].isNull()) + dataViewObject.isNetAttack7d = std::stol(value["IsNetAttack7d"].asString()); + if(!value["IsNetAttack30d"].isNull()) + dataViewObject.isNetAttack30d = std::stol(value["IsNetAttack30d"].asString()); + if(!value["IsBlackCampaign1d"].isNull()) + dataViewObject.isBlackCampaign1d = std::stol(value["IsBlackCampaign1d"].asString()); + if(!value["IsBlackCampaign7d"].isNull()) + dataViewObject.isBlackCampaign7d = std::stol(value["IsBlackCampaign7d"].asString()); + if(!value["IsBlackCampaign30d"].isNull()) + dataViewObject.isBlackCampaign30d = std::stol(value["IsBlackCampaign30d"].asString()); + dataView_.push_back(dataViewObject); + } + +} + +std::vector DescribePerDateDataResult::getDataView()const +{ + return dataView_; +} + diff --git a/sas-api/src/model/DescribeThreatDistributeRequest.cc b/sas-api/src/model/DescribeThreatDistributeRequest.cc new file mode 100644 index 000000000..7462a0239 --- /dev/null +++ b/sas-api/src/model/DescribeThreatDistributeRequest.cc @@ -0,0 +1,82 @@ +/* + * 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 + +using AlibabaCloud::Sas-api::Model::DescribeThreatDistributeRequest; + +DescribeThreatDistributeRequest::DescribeThreatDistributeRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "DescribeThreatDistribute") +{} + +DescribeThreatDistributeRequest::~DescribeThreatDistributeRequest() +{} + +std::string DescribeThreatDistributeRequest::getEndDate()const +{ + return endDate_; +} + +void DescribeThreatDistributeRequest::setEndDate(const std::string& endDate) +{ + endDate_ = endDate; + setParameter("EndDate", endDate); +} + +std::string DescribeThreatDistributeRequest::getSourceIp()const +{ + return sourceIp_; +} + +void DescribeThreatDistributeRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +int DescribeThreatDistributeRequest::getHitDay()const +{ + return hitDay_; +} + +void DescribeThreatDistributeRequest::setHitDay(int hitDay) +{ + hitDay_ = hitDay; + setParameter("HitDay", std::to_string(hitDay)); +} + +std::string DescribeThreatDistributeRequest::getStartDate()const +{ + return startDate_; +} + +void DescribeThreatDistributeRequest::setStartDate(const std::string& startDate) +{ + startDate_ = startDate; + setParameter("StartDate", startDate); +} + +int DescribeThreatDistributeRequest::getApiType()const +{ + return apiType_; +} + +void DescribeThreatDistributeRequest::setApiType(int apiType) +{ + apiType_ = apiType; + setParameter("ApiType", std::to_string(apiType)); +} + diff --git a/sas-api/src/model/DescribeThreatDistributeResult.cc b/sas-api/src/model/DescribeThreatDistributeResult.cc new file mode 100644 index 000000000..a24baa571 --- /dev/null +++ b/sas-api/src/model/DescribeThreatDistributeResult.cc @@ -0,0 +1,70 @@ +/* + * 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 +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +DescribeThreatDistributeResult::DescribeThreatDistributeResult() : + ServiceResult() +{} + +DescribeThreatDistributeResult::DescribeThreatDistributeResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeThreatDistributeResult::~DescribeThreatDistributeResult() +{} + +void DescribeThreatDistributeResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + + setRequestId(value["RequestId"].asString()); + auto allItems = value["Items"]["Item"]; + for (auto value : allItems) + { + Item itemsObject; + if(!value["Data"].isNull()) + itemsObject.data = std::stof(value["Data"].asString()); + if(!value["Id"].isNull()) + itemsObject.id = value["Id"].asString(); + if(!value["Name"].isNull()) + itemsObject.name = value["Name"].asString(); + items_.push_back(itemsObject); + } + auto allCategories = value["Categories"]["CategoriesItem"]; + for (const auto &item : allCategories) + categories_.push_back(item.asString()); + +} + +std::vector DescribeThreatDistributeResult::getCategories()const +{ + return categories_; +} + +std::vector DescribeThreatDistributeResult::getItems()const +{ + return items_; +} + diff --git a/sas-api/src/model/DescribeThreatTypeLinesRequest.cc b/sas-api/src/model/DescribeThreatTypeLinesRequest.cc new file mode 100644 index 000000000..d77271a89 --- /dev/null +++ b/sas-api/src/model/DescribeThreatTypeLinesRequest.cc @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Sas-api::Model::DescribeThreatTypeLinesRequest; + +DescribeThreatTypeLinesRequest::DescribeThreatTypeLinesRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "DescribeThreatTypeLines") +{} + +DescribeThreatTypeLinesRequest::~DescribeThreatTypeLinesRequest() +{} + +std::string DescribeThreatTypeLinesRequest::getSourceIp()const +{ + return sourceIp_; +} + +void DescribeThreatTypeLinesRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +int DescribeThreatTypeLinesRequest::getApiType()const +{ + return apiType_; +} + +void DescribeThreatTypeLinesRequest::setApiType(int apiType) +{ + apiType_ = apiType; + setParameter("ApiType", std::to_string(apiType)); +} + diff --git a/sas-api/src/model/DescribeThreatTypeLinesResult.cc b/sas-api/src/model/DescribeThreatTypeLinesResult.cc new file mode 100644 index 000000000..deddec4eb --- /dev/null +++ b/sas-api/src/model/DescribeThreatTypeLinesResult.cc @@ -0,0 +1,70 @@ +/* + * 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 +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +DescribeThreatTypeLinesResult::DescribeThreatTypeLinesResult() : + ServiceResult() +{} + +DescribeThreatTypeLinesResult::DescribeThreatTypeLinesResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeThreatTypeLinesResult::~DescribeThreatTypeLinesResult() +{} + +void DescribeThreatTypeLinesResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + + setRequestId(value["RequestId"].asString()); + auto allItems = value["Items"]["Item"]; + for (auto value : allItems) + { + Item itemsObject; + if(!value["Data"].isNull()) + itemsObject.data = std::stof(value["Data"].asString()); + if(!value["Id"].isNull()) + itemsObject.id = value["Id"].asString(); + if(!value["Name"].isNull()) + itemsObject.name = value["Name"].asString(); + items_.push_back(itemsObject); + } + auto allCategories = value["Categories"]["CategoriesItem"]; + for (const auto &item : allCategories) + categories_.push_back(item.asString()); + +} + +std::vector DescribeThreatTypeLinesResult::getCategories()const +{ + return categories_; +} + +std::vector DescribeThreatTypeLinesResult::getItems()const +{ + return items_; +} + diff --git a/sas-api/src/model/DescribeTotalAndRateLineRequest.cc b/sas-api/src/model/DescribeTotalAndRateLineRequest.cc new file mode 100644 index 000000000..992d6a573 --- /dev/null +++ b/sas-api/src/model/DescribeTotalAndRateLineRequest.cc @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Sas-api::Model::DescribeTotalAndRateLineRequest; + +DescribeTotalAndRateLineRequest::DescribeTotalAndRateLineRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "DescribeTotalAndRateLine") +{} + +DescribeTotalAndRateLineRequest::~DescribeTotalAndRateLineRequest() +{} + +std::string DescribeTotalAndRateLineRequest::getSourceIp()const +{ + return sourceIp_; +} + +void DescribeTotalAndRateLineRequest::setSourceIp(const std::string& sourceIp) +{ + sourceIp_ = sourceIp; + setParameter("SourceIp", sourceIp); +} + +int DescribeTotalAndRateLineRequest::getApiType()const +{ + return apiType_; +} + +void DescribeTotalAndRateLineRequest::setApiType(int apiType) +{ + apiType_ = apiType; + setParameter("ApiType", std::to_string(apiType)); +} + diff --git a/sas-api/src/model/DescribeTotalAndRateLineResult.cc b/sas-api/src/model/DescribeTotalAndRateLineResult.cc new file mode 100644 index 000000000..f244eb0ef --- /dev/null +++ b/sas-api/src/model/DescribeTotalAndRateLineResult.cc @@ -0,0 +1,70 @@ +/* + * 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 +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +DescribeTotalAndRateLineResult::DescribeTotalAndRateLineResult() : + ServiceResult() +{} + +DescribeTotalAndRateLineResult::DescribeTotalAndRateLineResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeTotalAndRateLineResult::~DescribeTotalAndRateLineResult() +{} + +void DescribeTotalAndRateLineResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + + setRequestId(value["RequestId"].asString()); + auto allItems = value["Items"]["Item"]; + for (auto value : allItems) + { + Item itemsObject; + if(!value["Data"].isNull()) + itemsObject.data = std::stof(value["Data"].asString()); + if(!value["Id"].isNull()) + itemsObject.id = value["Id"].asString(); + if(!value["Name"].isNull()) + itemsObject.name = value["Name"].asString(); + items_.push_back(itemsObject); + } + auto allCategories = value["Categories"]["CategoriesItem"]; + for (const auto &item : allCategories) + categories_.push_back(item.asString()); + +} + +std::vector DescribeTotalAndRateLineResult::getCategories()const +{ + return categories_; +} + +std::vector DescribeTotalAndRateLineResult::getItems()const +{ + return items_; +} + diff --git a/sas-api/src/model/GetAccountProfileRequest.cc b/sas-api/src/model/GetAccountProfileRequest.cc new file mode 100644 index 000000000..5a8815c83 --- /dev/null +++ b/sas-api/src/model/GetAccountProfileRequest.cc @@ -0,0 +1,159 @@ +/* + * 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 + +using AlibabaCloud::Sas-api::Model::GetAccountProfileRequest; + +GetAccountProfileRequest::GetAccountProfileRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "GetAccountProfile") +{} + +GetAccountProfileRequest::~GetAccountProfileRequest() +{} + +std::string GetAccountProfileRequest::getDeviceIdMd5()const +{ + return deviceIdMd5_; +} + +void GetAccountProfileRequest::setDeviceIdMd5(const std::string& deviceIdMd5) +{ + deviceIdMd5_ = deviceIdMd5; + setParameter("DeviceIdMd5", deviceIdMd5); +} + +int GetAccountProfileRequest::getCarrier()const +{ + return carrier_; +} + +void GetAccountProfileRequest::setCarrier(int carrier) +{ + carrier_ = carrier; + setParameter("Carrier", std::to_string(carrier)); +} + +std::string GetAccountProfileRequest::getOs()const +{ + return os_; +} + +void GetAccountProfileRequest::setOs(const std::string& os) +{ + os_ = os; + setParameter("Os", os); +} + +std::string GetAccountProfileRequest::getPhone()const +{ + return phone_; +} + +void GetAccountProfileRequest::setPhone(const std::string& phone) +{ + phone_ = phone; + setParameter("Phone", phone); +} + +std::string GetAccountProfileRequest::getRequestUrl()const +{ + return requestUrl_; +} + +void GetAccountProfileRequest::setRequestUrl(const std::string& requestUrl) +{ + requestUrl_ = requestUrl; + setParameter("RequestUrl", requestUrl); +} + +std::string GetAccountProfileRequest::getIp()const +{ + return ip_; +} + +void GetAccountProfileRequest::setIp(const std::string& ip) +{ + ip_ = ip; + setParameter("Ip", ip); +} + +std::string GetAccountProfileRequest::getUserAgent()const +{ + return userAgent_; +} + +void GetAccountProfileRequest::setUserAgent(const std::string& userAgent) +{ + userAgent_ = userAgent; + setParameter("UserAgent", userAgent); +} + +int GetAccountProfileRequest::getConnectionType()const +{ + return connectionType_; +} + +void GetAccountProfileRequest::setConnectionType(int connectionType) +{ + connectionType_ = connectionType; + setParameter("ConnectionType", std::to_string(connectionType)); +} + +int GetAccountProfileRequest::getSensType()const +{ + return sensType_; +} + +void GetAccountProfileRequest::setSensType(int sensType) +{ + sensType_ = sensType; + setParameter("SensType", std::to_string(sensType)); +} + +int GetAccountProfileRequest::getDeviceType()const +{ + return deviceType_; +} + +void GetAccountProfileRequest::setDeviceType(int deviceType) +{ + deviceType_ = deviceType; + setParameter("DeviceType", std::to_string(deviceType)); +} + +long GetAccountProfileRequest::getAccessTimestamp()const +{ + return accessTimestamp_; +} + +void GetAccountProfileRequest::setAccessTimestamp(long accessTimestamp) +{ + accessTimestamp_ = accessTimestamp; + setParameter("AccessTimestamp", std::to_string(accessTimestamp)); +} + +int GetAccountProfileRequest::getBusinessType()const +{ + return businessType_; +} + +void GetAccountProfileRequest::setBusinessType(int businessType) +{ + businessType_ = businessType; + setParameter("BusinessType", std::to_string(businessType)); +} + diff --git a/sas-api/src/model/GetAccountProfileResult.cc b/sas-api/src/model/GetAccountProfileResult.cc new file mode 100644 index 000000000..5b0bee15f --- /dev/null +++ b/sas-api/src/model/GetAccountProfileResult.cc @@ -0,0 +1,80 @@ +/* + * 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 +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +GetAccountProfileResult::GetAccountProfileResult() : + ServiceResult() +{} + +GetAccountProfileResult::GetAccountProfileResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetAccountProfileResult::~GetAccountProfileResult() +{} + +void GetAccountProfileResult::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["Ip"].isNull()) + data_.ip = dataNode["Ip"].asString(); + if(!dataNode["Phone"].isNull()) + data_.phone = dataNode["Phone"].asString(); + if(!dataNode["IpInfo"].isNull()) + data_.ipInfo = dataNode["IpInfo"].asString(); + if(!dataNode["PhoneInfo"].isNull()) + data_.phoneInfo = dataNode["PhoneInfo"].asString(); + if(!value["Code"].isNull()) + code_ = std::stoi(value["Code"].asString()); + if(!value["Message"].isNull()) + message_ = value["Message"].asString(); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + +} + +std::string GetAccountProfileResult::getMessage()const +{ + return message_; +} + +GetAccountProfileResult::Data GetAccountProfileResult::getData()const +{ + return data_; +} + +int GetAccountProfileResult::getCode()const +{ + return code_; +} + +bool GetAccountProfileResult::getSuccess()const +{ + return success_; +} + diff --git a/sas-api/src/model/GetInstanceCountRequest.cc b/sas-api/src/model/GetInstanceCountRequest.cc new file mode 100644 index 000000000..0516e7b40 --- /dev/null +++ b/sas-api/src/model/GetInstanceCountRequest.cc @@ -0,0 +1,38 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Sas-api::Model::GetInstanceCountRequest; + +GetInstanceCountRequest::GetInstanceCountRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "GetInstanceCount") +{} + +GetInstanceCountRequest::~GetInstanceCountRequest() +{} + +long GetInstanceCountRequest::getOwnerId()const +{ + return ownerId_; +} + +void GetInstanceCountRequest::setOwnerId(long ownerId) +{ + ownerId_ = ownerId; + setParameter("OwnerId", std::to_string(ownerId)); +} + diff --git a/sas-api/src/model/GetInstanceCountResult.cc b/sas-api/src/model/GetInstanceCountResult.cc new file mode 100644 index 000000000..6f797ad1b --- /dev/null +++ b/sas-api/src/model/GetInstanceCountResult.cc @@ -0,0 +1,73 @@ +/* + * 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 +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +GetInstanceCountResult::GetInstanceCountResult() : + ServiceResult() +{} + +GetInstanceCountResult::GetInstanceCountResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetInstanceCountResult::~GetInstanceCountResult() +{} + +void GetInstanceCountResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + + setRequestId(value["RequestId"].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() == "true"; + if(!value["Data"].isNull()) + data_ = std::stoi(value["Data"].asString()); + +} + +std::string GetInstanceCountResult::getMessage()const +{ + return message_; +} + +int GetInstanceCountResult::getData()const +{ + return data_; +} + +std::string GetInstanceCountResult::getCode()const +{ + return code_; +} + +bool GetInstanceCountResult::getSuccess()const +{ + return success_; +} + diff --git a/sas-api/src/model/GetIpProfileRequest.cc b/sas-api/src/model/GetIpProfileRequest.cc new file mode 100644 index 000000000..c94f56d0b --- /dev/null +++ b/sas-api/src/model/GetIpProfileRequest.cc @@ -0,0 +1,137 @@ +/* + * 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 + +using AlibabaCloud::Sas-api::Model::GetIpProfileRequest; + +GetIpProfileRequest::GetIpProfileRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "GetIpProfile") +{} + +GetIpProfileRequest::~GetIpProfileRequest() +{} + +std::string GetIpProfileRequest::getDeviceIdMd5()const +{ + return deviceIdMd5_; +} + +void GetIpProfileRequest::setDeviceIdMd5(const std::string& deviceIdMd5) +{ + deviceIdMd5_ = deviceIdMd5; + setParameter("DeviceIdMd5", deviceIdMd5); +} + +int GetIpProfileRequest::getCarrier()const +{ + return carrier_; +} + +void GetIpProfileRequest::setCarrier(int carrier) +{ + carrier_ = carrier; + setParameter("Carrier", std::to_string(carrier)); +} + +std::string GetIpProfileRequest::getOs()const +{ + return os_; +} + +void GetIpProfileRequest::setOs(const std::string& os) +{ + os_ = os; + setParameter("Os", os); +} + +std::string GetIpProfileRequest::getRequestUrl()const +{ + return requestUrl_; +} + +void GetIpProfileRequest::setRequestUrl(const std::string& requestUrl) +{ + requestUrl_ = requestUrl; + setParameter("RequestUrl", requestUrl); +} + +std::string GetIpProfileRequest::getIp()const +{ + return ip_; +} + +void GetIpProfileRequest::setIp(const std::string& ip) +{ + ip_ = ip; + setParameter("Ip", ip); +} + +std::string GetIpProfileRequest::getUserAgent()const +{ + return userAgent_; +} + +void GetIpProfileRequest::setUserAgent(const std::string& userAgent) +{ + userAgent_ = userAgent; + setParameter("UserAgent", userAgent); +} + +int GetIpProfileRequest::getConnectionType()const +{ + return connectionType_; +} + +void GetIpProfileRequest::setConnectionType(int connectionType) +{ + connectionType_ = connectionType; + setParameter("ConnectionType", std::to_string(connectionType)); +} + +int GetIpProfileRequest::getSensType()const +{ + return sensType_; +} + +void GetIpProfileRequest::setSensType(int sensType) +{ + sensType_ = sensType; + setParameter("SensType", std::to_string(sensType)); +} + +int GetIpProfileRequest::getDeviceType()const +{ + return deviceType_; +} + +void GetIpProfileRequest::setDeviceType(int deviceType) +{ + deviceType_ = deviceType; + setParameter("DeviceType", std::to_string(deviceType)); +} + +int GetIpProfileRequest::getBusinessType()const +{ + return businessType_; +} + +void GetIpProfileRequest::setBusinessType(int businessType) +{ + businessType_ = businessType; + setParameter("BusinessType", std::to_string(businessType)); +} + diff --git a/sas-api/src/model/GetIpProfileResult.cc b/sas-api/src/model/GetIpProfileResult.cc new file mode 100644 index 000000000..12fd6e6dd --- /dev/null +++ b/sas-api/src/model/GetIpProfileResult.cc @@ -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. + */ + +#include +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +GetIpProfileResult::GetIpProfileResult() : + ServiceResult() +{} + +GetIpProfileResult::GetIpProfileResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetIpProfileResult::~GetIpProfileResult() +{} + +void GetIpProfileResult::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["Ip"].isNull()) + data_.ip = dataNode["Ip"].asString(); + if(!dataNode["Info"].isNull()) + data_.info = dataNode["Info"].asString(); + if(!value["Code"].isNull()) + code_ = std::stoi(value["Code"].asString()); + if(!value["Message"].isNull()) + message_ = value["Message"].asString(); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + +} + +std::string GetIpProfileResult::getMessage()const +{ + return message_; +} + +GetIpProfileResult::Data GetIpProfileResult::getData()const +{ + return data_; +} + +int GetIpProfileResult::getCode()const +{ + return code_; +} + +bool GetIpProfileResult::getSuccess()const +{ + return success_; +} + diff --git a/sas-api/src/model/GetPhoneProfileRequest.cc b/sas-api/src/model/GetPhoneProfileRequest.cc new file mode 100644 index 000000000..ac974dbff --- /dev/null +++ b/sas-api/src/model/GetPhoneProfileRequest.cc @@ -0,0 +1,71 @@ +/* + * 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 + +using AlibabaCloud::Sas-api::Model::GetPhoneProfileRequest; + +GetPhoneProfileRequest::GetPhoneProfileRequest() : + RpcServiceRequest("sas-api", "2017-07-05", "GetPhoneProfile") +{} + +GetPhoneProfileRequest::~GetPhoneProfileRequest() +{} + +std::string GetPhoneProfileRequest::getPhone()const +{ + return phone_; +} + +void GetPhoneProfileRequest::setPhone(const std::string& phone) +{ + phone_ = phone; + setParameter("Phone", phone); +} + +int GetPhoneProfileRequest::getSensType()const +{ + return sensType_; +} + +void GetPhoneProfileRequest::setSensType(int sensType) +{ + sensType_ = sensType; + setParameter("SensType", std::to_string(sensType)); +} + +std::string GetPhoneProfileRequest::getDataVersion()const +{ + return dataVersion_; +} + +void GetPhoneProfileRequest::setDataVersion(const std::string& dataVersion) +{ + dataVersion_ = dataVersion; + setParameter("DataVersion", dataVersion); +} + +int GetPhoneProfileRequest::getBusinessType()const +{ + return businessType_; +} + +void GetPhoneProfileRequest::setBusinessType(int businessType) +{ + businessType_ = businessType; + setParameter("BusinessType", std::to_string(businessType)); +} + diff --git a/sas-api/src/model/GetPhoneProfileResult.cc b/sas-api/src/model/GetPhoneProfileResult.cc new file mode 100644 index 000000000..9854b0428 --- /dev/null +++ b/sas-api/src/model/GetPhoneProfileResult.cc @@ -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. + */ + +#include +#include + +using namespace AlibabaCloud::Sas-api; +using namespace AlibabaCloud::Sas-api::Model; + +GetPhoneProfileResult::GetPhoneProfileResult() : + ServiceResult() +{} + +GetPhoneProfileResult::GetPhoneProfileResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetPhoneProfileResult::~GetPhoneProfileResult() +{} + +void GetPhoneProfileResult::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["Phone"].isNull()) + data_.phone = dataNode["Phone"].asString(); + if(!dataNode["Info"].isNull()) + data_.info = dataNode["Info"].asString(); + if(!value["Code"].isNull()) + code_ = std::stoi(value["Code"].asString()); + if(!value["Message"].isNull()) + message_ = value["Message"].asString(); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + +} + +std::string GetPhoneProfileResult::getMessage()const +{ + return message_; +} + +GetPhoneProfileResult::Data GetPhoneProfileResult::getData()const +{ + return data_; +} + +int GetPhoneProfileResult::getCode()const +{ + return code_; +} + +bool GetPhoneProfileResult::getSuccess()const +{ + return success_; +} +