Compare commits

..

49 Commits

Author SHA1 Message Date
haowei.yao
596b96d689 ECS SDK Auto Released By junmei.zjm,Version:1.34.11
Signed-off-by: haowei.yao <haowei.yao@alibaba-inc.com>
2019-03-13 16:42:23 +08:00
haowei.yao
43169f9d50 TESLAMAXCOMPUTE SDK Auto Released By shenshi,Version:1.34.10
Signed-off-by: haowei.yao <haowei.yao@alibaba-inc.com>
2019-03-13 16:05:42 +08:00
zhangzifa
c99809b8e4 support http put and delete 2019-03-13 14:35:52 +08:00
haowei.yao
85e2f3ebe4 XSPACE SDK Auto Released By xiaoyan.yan,Version:1.34.9
Signed-off-by: haowei.yao <haowei.yao@alibaba-inc.com>
2019-03-12 12:28:26 +08:00
zhangzifa
a6d33574bd fix windows string length strict 2019-03-12 12:18:57 +08:00
zhangzifa
c17dc7c79a refactor endpoints implementation 2019-03-08 14:05:32 +08:00
zhangzifa
563e907601 fix ecs deleteInstance invalid Force parameter 2019-03-08 13:49:02 +08:00
zhangzifa
33a44c856d provide more information when error occurs 2019-02-27 11:44:11 +08:00
zhangzifa
f877a9ef39 update readme 2019-02-22 17:31:00 +08:00
zhangzifa
eb7ab33440 add DEBUG switch and fix win build error 2019-02-21 13:35:56 +08:00
zhangzifa
6a5f788210 fix memory leak in url encode and decode 2019-02-21 10:29:22 +08:00
zhangzifa
fdc3251134 fix most cpplint checkpoint 2019-02-19 16:24:07 +08:00
zhangzifa
043df1b674 add more unit test for location and sts 2019-02-18 10:50:59 +08:00
zhangzifa
5f3caa1943 add examples and build with as many cpus as possible 2019-02-15 14:56:39 +08:00
Jackson Tian
01dcff0b7c Update README.md 2019-02-13 17:10:20 +08:00
zhangzifa
ae7e11733f handle kinds of error message
update test case and reduce duplicate code
2019-02-13 17:09:18 +08:00
zhangzifa
da28515bd8 replace tab with 2 spaces in core dir
Copyright time changed to 1999-2019
2019-02-03 11:34:19 +08:00
zhangzifa
138dbdc61e add POST support and fix user specified scheme via commonrequest 2019-01-31 17:11:31 +08:00
zhangzifa
b429dcc915 add basic function test
update travis to run function test
2019-01-28 19:37:52 +08:00
zhangzifa
57daafe4cc fix ecs build failure 2019-01-25 21:20:25 +08:00
zhangzifa
ecd09578e8 fix typo in issue template
optimize issu template description
2019-01-24 10:55:51 +08:00
zhangzifa
78df52c437 add issue template 2019-01-23 20:46:47 +08:00
zhangzifa
e477d06dea unit test for coreclient 2019-01-23 15:03:38 +08:00
zhangzifa
e00a04b071 unit test for InstanceProfileCredentialsProvider 2019-01-18 21:37:30 +08:00
zhangzifa
48fc5dfe8c unit test for EndpointProvider and StsAssumeRoleCrendentialsProvider 2019-01-18 16:38:43 +08:00
zhangzifa
6cfcc11657 unit test for sts and location 2019-01-17 22:50:14 +08:00
Jackson Tian
7b7c45cb26 Update README_zh.md 2019-01-17 07:57:21 +08:00
Jackson Tian
cf825c63a5 Update README.md 2019-01-17 07:57:21 +08:00
zhangzifa
fc29617d7d add unit test case for ecsmetadata and fix other ut 2019-01-14 20:57:24 +08:00
zhangzifa
352be1dd14 add more unit test for location and std 2019-01-12 23:29:10 +08:00
zhangzifa
66910b1961 add more unit test 2019-01-11 17:31:24 +08:00
Jackson Tian
790577e792 Add codecov badge 2019-01-10 20:51:55 +08:00
Jackson Tian
1ee62b8677 update license year 2019-01-10 19:07:59 +08:00
zhangzifa
21edc7f283 fix unit test build failed 2019-01-10 18:55:58 +08:00
Jackson Tian
919f98cbdd fix travis config
* fix travis config
* remove the useless files
2019-01-10 15:59:00 +08:00
zhangzifa
ad045aa702 fix build failed 2019-01-10 15:47:11 +08:00
Jackson Tian
6e65f364a1 Add travis config 2019-01-10 11:23:54 +08:00
Jackson Tian
bc0df2dcec use github repo as central 2019-01-09 14:07:33 +08:00
yixiong.jxy
9664fb1b00 DCDN SDK Auto Released By xiaoyao,Version:1.34.8
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-12-20 15:37:04 +08:00
yixiong.jxy
0df947c481 DCDN SDK Auto Released By xiaoyao,Version:1.34.7
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-12-11 19:52:39 +08:00
yixiong.jxy
9b7dbef9c8 LIVE SDK Auto Released By renrang.yl,Version:1.34.6
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-12-06 10:28:48 +08:00
yixiong.jxy
e5522c68c8 SCDN SDK Auto Released By xiaoyao,Version:1.34.5
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-12-03 19:32:39 +08:00
yixiong.jxy
24eaa468b9 DCDN SDK Auto Released By xiaoyao,Version:1.34.4
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-12-03 17:42:54 +08:00
yixiong.jxy
44ac453806 CDN SDK Auto Released By xiaoyao,Version:1.34.3
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-12-03 16:57:53 +08:00
yixiong.jxy
aa71e41fab ESS SDK Auto Released By deyan.jdy,Version:1.34.2
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-12-03 15:07:49 +08:00
yixiong.jxy
2fb169a7d4 VOD SDK Auto Released By xiao.xwp,Version:1.34.1
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-11-30 15:20:26 +08:00
yixiong.jxy
bdfb1e8514 ECS SDK Auto Released By licheng.lj,Version:1.34.0
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-11-28 18:28:25 +08:00
yixiong.jxy
cc52fb9dd8 IOT SDK Auto Released By cheyun.lxf,Version:1.33.6
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-11-28 13:45:18 +08:00
yixiong.jxy
893339c43d IOT SDK Auto Released By cheyun.lxf,Version:1.33.5
Signed-off-by: yixiong.jxy <yixiong.jxy@alibaba-inc.com>
2018-11-27 15:00:25 +08:00
1214 changed files with 55431 additions and 7472 deletions

26
.github/ISSUE_TEMPLATE/bug_report.md vendored Normal file
View File

@@ -0,0 +1,26 @@
---
name: "Bug Report"
about: Create a report to help us improve
---
<!--
Thank you for reporting a possible bug in Alibaba Cloud C++ SDK
Please fill in as much of the template below as you can.
Product and API: the product and API you are working on when bug occurs
Platform: output of `uname -a` (UNIX), or version and 32 or 64-bit (Windows)
How to Reproduce: If possible, please provide code that demonstrates the problem,
keeping it as simple and free of external dependencies as you can.
If crash, please provide the stack trace.
If build error, please provide compiler information: compiler and version, etc
-->
* **Product and API**:
* **Platform**:
* **How to Reproduce**
<!-- Please provide more details below this comment. -->

28
.github/ISSUE_TEMPLATE/bug_report_cn.md vendored Normal file
View File

@@ -0,0 +1,28 @@
---
name: "缺陷问题反馈"
about: 提交缺陷问题反馈
---
<!--
感谢提交问题反馈。
请提供尽量全面的信息协助问题定位修复。
产品和接口问题发生时工作所在的产品和调用的API
平台:操作系统信息,类型,版本
如果可能,请提供一份最小问题复现代码。
如果崩溃,请提供错误栈。
如果编译出错,请提供 cmake 版本,编译器版本,编译命令等信息。
-->
* **产品和接口**:
* **平台**:
* **最小代码**:
<!-- 请提供其他可能协助问题定位的信息 -->

13
.gitignore vendored Normal file
View File

@@ -0,0 +1,13 @@
tools/endpoints.json
initCoverage.info
testCoverage.info
coverageReport/
Testing/
.vscode/
ft_build/
ut_build/
sdk_build/
test/httpserver/node_modules
test/httpserver/package-lock.json
test/httpserver/nohup.out

15
.travis.yml Normal file
View File

@@ -0,0 +1,15 @@
dist: xenial
sudo: require
language: cpp
compiler: gcc
install:
- sudo apt-get install lcov libcurl4-openssl-dev libssl-dev uuid-dev libjsoncpp-dev nodejs npm
script:
- ./unit_test.sh
- ./generate_code_cov.sh
- ./function_test.sh
after_success:
- bash <(curl -s https://codecov.io/bash)

View File

@@ -44,9 +44,10 @@ endif()
ExternalProject_Add(catch
URL ${CMAKE_CURRENT_SOURCE_DIR}/catch-2.0.1.hpp
URL_HASH MD5=9b3d2cb5c0f9532cddfbbfd0a622f0af
DOWNLOAD_NO_EXTRACT 1
CONFIGURE_COMMAND ""
DOWNLOAD_COMMAND ""
CONFIGURE_COMMAND ""
BUILD_COMMAND ""
INSTALL_COMMAND
${CMAKE_COMMAND} -E copy_if_different <DOWNLOADED_FILE> <INSTALL_DIR>/catch.hpp
${CMAKE_COMMAND} -E copy_if_different
${CMAKE_CURRENT_SOURCE_DIR}/catch-2.0.1.hpp <INSTALL_DIR>/catch.hpp
)

View File

@@ -1,3 +1,50 @@
2019-03-13 Version: 1.34.11
1, add DescribeDemands interface
2019-03-13 Version: 1.34.10
1, Distinguish between system and service parameters
2019-03-12 Version: 1.34.9
1, add agency infomation
2, update sdk core resources
2018-12-20 Version: 1.34.8
1, Sync CDN API.
2018-12-11 Version: 1.34.7
1, Sync CDN API.
2018-12-06 Version: 1.34.6
1, Add DescribeLiveDomainRealTimeBpsData, DescribeLiveDomainRealTimeHttpCodeData,DescribeLiveDomainRealTimeTrafficData.
2, Update DescirbeCasterChannels and DescribeCasterStreamUrl.
2018-12-03 Version: 1.34.5
1, Sync CDN API.
2018-12-03 Version: 1.34.4
1, Sync CDN API.
2018-12-03 Version: 1.34.3
1, Update 2014-11-11 API.
2018-12-03 Version: 1.34.2
1, Add a parameter to RemoveInstances.
2018-11-30 Version: 1.34.1
1, Add new apis called AddVodTemplate, UpdateVodTemplate, DeleteVodTemplate, ListVodTemplate, GetVodTemplate and SetDefaultVodTemplate which support vodtemplate feature.
2, Add a new api called CreateUploadAttachedMedia to get upload auth for attached media
3, Add new apis called AddWorkFlow, UpdateWorkFlow, DeleteWorkFlow, ListWorkFlow, GetWorkFlow which support workflow feature.
2018-11-28 Version: 1.34.0
1, Add RedeployInstance interface, and support to migrate ecs instance with specified maintenance events actively
2018-11-28 Version: 1.33.6
1, Add APIs InvokeThingsService, SetDevicesProperty and QueryDeviceByTags .
2018-11-27 Version: 1.33.5
1, Add APIs InvokeThingsService, SetDevicesProperty and QueryDeviceByTags .
2018-11-22 Version: 1.33.4
1, Increase the scene field

View File

@@ -1,95 +1,94 @@
#
# 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.
#
cmake_minimum_required(VERSION 3.1)
cmake_policy(SET CMP0048 NEW)
file(STRINGS "VERSION" version)
project(alibabacloud-sdk VERSION ${version})
message(STATUS "Project version: ${PROJECT_VERSION}")
set(TARGET_OUTPUT_NAME_PREFIX "alibabacloud-sdk-" CACHE STRING "The target's output name prefix")
option(BUILD_SHARED_LIBS "Enable shared library" ON)
option(BUILD_UNIT_TESTS "Enable unit tests" OFF)
option(BUILD_FUNCTION_TESTS "Enable function test" OFF)
set(LIB_TYPE STATIC)
if(BUILD_SHARED_LIBS)
set(LIB_TYPE SHARED)
add_definitions(-DALIBABACLOUD_SHARED)
endif()
set_property(GLOBAL
PROPERTY
USE_FOLDERS ON)
set(CMAKE_CXX_STANDARD 11)
include(ExternalProject)
include(GNUInstallDirs)
add_subdirectory(3rdparty)
add_subdirectory(core)
if(BUILD_UNIT_TESTS)
enable_testing()
add_subdirectory(test/core)
endif()
if(BUILD_FUNCTION_TESTS)
enable_testing()
add_subdirectory(test/function_test/cdn)
add_subdirectory(test/function_test/core)
add_subdirectory(test/function_test/ecs)
add_subdirectory(test/function_test/nlp)
add_subdirectory(test/function_test/rds)
add_subdirectory(test/function_test/slb)
add_subdirectory(test/function_test/vpc)
endif()
add_subdirectory(ecs)
add_subdirectory(slb)
add_subdirectory(vpc)
add_subdirectory(cdn)
add_subdirectory(rds)
add_subdirectory(cloudphoto)
add_subdirectory(ess)
add_subdirectory(tesladam)
add_subdirectory(cms)
add_subdirectory(afs)
add_subdirectory(aegis)
add_subdirectory(ehpc)
add_subdirectory(cs)
add_subdirectory(ccc)
add_subdirectory(teslamaxcompute)
add_subdirectory(push)
add_subdirectory(csb)
add_subdirectory(domain)
add_subdirectory(green)
add_subdirectory(hsm)
add_subdirectory(dcdn)
add_subdirectory(pvtz)
add_subdirectory(cloudauth)
add_subdirectory(dyvmsapi)
add_subdirectory(drds)
add_subdirectory(jarvis)
add_subdirectory(scdn)
add_subdirectory(live)
add_subdirectory(rtc)
add_subdirectory(chatbot)
add_subdirectory(teslastream)
add_subdirectory(mopen)
add_subdirectory(mts)
add_subdirectory(iot)
add_subdirectory(linkface)
add_subdirectory(ots)
add_subdirectory(smartag)
add_subdirectory(vod)
add_subdirectory(ccs)
add_subdirectory(saf)
add_subdirectory(arms)
add_subdirectory(lubancloud)
add_subdirectory(alimt)
cmake_minimum_required(VERSION 3.1)
cmake_policy(SET CMP0048 NEW)
file(STRINGS "VERSION" version)
project(alibabacloud-sdk VERSION ${version})
message(STATUS "Project version: ${PROJECT_VERSION}")
set(TARGET_OUTPUT_NAME_PREFIX "alibabacloud-sdk-" CACHE STRING "The target's output name prefix")
option(BUILD_SHARED_LIBS "Enable shared library" ON)
option(BUILD_TESTS "Enable tests" ON)
set(LIB_TYPE STATIC)
if(BUILD_SHARED_LIBS)
set(LIB_TYPE SHARED)
add_definitions(-DALIBABACLOUD_SHARED)
endif()
set_property(GLOBAL
PROPERTY
USE_FOLDERS ON)
set(CMAKE_CXX_STANDARD 11)
include(ExternalProject)
include(GNUInstallDirs)
add_subdirectory(3rdparty)
add_subdirectory(core)
if(BUILD_TESTS)
enable_testing()
add_subdirectory(core-tests)
endif()
add_subdirectory(ecs)
add_subdirectory(slb)
add_subdirectory(vpc)
add_subdirectory(cdn)
add_subdirectory(rds)
add_subdirectory(cloudphoto)
add_subdirectory(ess)
add_subdirectory(tesladam)
add_subdirectory(cms)
add_subdirectory(afs)
add_subdirectory(aegis)
add_subdirectory(ehpc)
add_subdirectory(cs)
add_subdirectory(ccc)
add_subdirectory(teslamaxcompute)
add_subdirectory(push)
add_subdirectory(csb)
add_subdirectory(domain)
add_subdirectory(green)
add_subdirectory(hsm)
add_subdirectory(dcdn)
add_subdirectory(pvtz)
add_subdirectory(cloudauth)
add_subdirectory(dyvmsapi)
add_subdirectory(drds)
add_subdirectory(jarvis)
add_subdirectory(scdn)
add_subdirectory(live)
add_subdirectory(rtc)
add_subdirectory(chatbot)
add_subdirectory(teslastream)
add_subdirectory(mopen)
add_subdirectory(mts)
add_subdirectory(iot)
add_subdirectory(linkface)
add_subdirectory(ots)
add_subdirectory(smartag)
add_subdirectory(vod)
add_subdirectory(ccs)
add_subdirectory(saf)
add_subdirectory(arms)
add_subdirectory(lubancloud)
add_subdirectory(alimt)
add_subdirectory(xspace)

View File

@@ -1,4 +1,4 @@
Copyright 2009-2017 Alibaba Cloud All rights reserved.
Copyright 2009-2019 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.
@@ -10,4 +10,4 @@ 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.
limitations under the License.

244
README.md
View File

@@ -1,81 +1,163 @@
# Alibaba Cloud C++ Software Development Kit
[中文文档](./README_zh.md)
The Alibaba Cloud C++ Software Development Kit (SDK) allows you to access Alibaba Cloud services such as Elastic Compute Service (ECS), Server Load Balancer (SLB), and CloudMonitor. You can access Alibaba Cloud services without the need to handle API related tasks, such as signing and constructing your requests.
This document introduces how to obtain and call Alibaba Cloud C++ SDK.
If you have any problem while using C++ SDK, please join the **DingTalk group: 11771185 (the official SDK customer service group of Alibaba Cloud)** for consultation.
## Prerequisites
- To use Alibaba Cloud C++ SDK, you must have an Alibaba Cloud account and an AccessKey.
The AccessKey is required when initializing the client. You can create an AccessKey in the Alibaba Cloud console. For more information, see [Create an AccessKey](https://usercenter.console.aliyun.com/?spm=5176.doc52740.2.3.QKZk8w#/manage/ak).
>**Note:** To increase the security of your account, we recommend that you use the AccessKey of the RAM user to access Alibaba Cloud services.
- To use Alibaba Cloud C++ SDK to access the APIs of a product, you must first activate the product on the [Alibaba Cloud console](https://home.console.aliyun.com/?spm=5176.doc52740.2.4.QKZk8w) if required.
## Install C++ SDK
1. Install third-party libraries on the Linux platform, including `libcurl`, `libopenssl`, `libuuid`, and `libjsoncpp`.
- Run the following commands on the Redhat/Fedora system to install third-party libraries.
```
sudo dnf install libcurl-devel openssl-devel libuuid-devel libjsoncpp-devel
```
- Run the following commands on the Debian/Ubuntu system to install third-party libraries.
```
sudo apt-get install libcurl4-openssl-dev libssl-dev uuid-dev libjsoncpp-dev
```
2. Run the following commands to clone source codes from GitHub.
```
git clone https://github.com/aliyun/aliyun-openapi-cpp-sdk.git
```
## Use the C++ SDK
Before using C++ SDK, you must first configure the preprocessor to define `ALIBABACLOUD_SHARED` to achieve dynamic linking with Alibaba Cloud C++ SDK shared libraries. Then you must create a client instance, specify the region of cloud services and provide authentication parameters before sending API requests.
The following code shows how to call the [DescribeInstances](~~25506~~) API of ECS to query detailed information of all ECS instances in a specific region.
```
#include <iostream>
#include <alibabacloud/core/AlibabaCloud.h>
#include <alibabacloud/ecs/EcsClient.h>
using namespace AlibabaCloud;
using namespace AlibabaCloud::Ecs;
int main(int argc, char** argv)
{
// Initialize the SDK
AlibabaCloud::InitializeSdk();
// Configure the ECS instance
ClientConfiguration configuration("<your-region-id>");
EcsClient client("<your-access-key-id>", "<your-access-key-secret>", configuration);
// Create an API request and set parameters
Model::DescribeInstancesRequest request;
request.setPageSize(10);
auto outcome = client.describeInstances(request);
if (!outcome.isSuccess())
{
// Handle exceptions
std::cout << outcome.error().errorCode() << std::endl;
AlibabaCloud::ShutdownSdk();
return -1;
}
std::cout << "totalCount: " << outcome.result().getTotalCount() << std::endl;
// Close the SDK
AlibabaCloud::ShutdownSdk();
return 0;
}
```
# Alibaba Cloud C++ Software Development Kit
[中文文档](./README_zh.md)
[![Build Status](https://travis-ci.org/aliyun/aliyun-openapi-cpp-sdk.svg?branch=master)](https://travis-ci.org/aliyun/aliyun-openapi-cpp-sdk)
[![codecov](https://codecov.io/gh/aliyun/aliyun-openapi-cpp-sdk/branch/master/graph/badge.svg)](https://codecov.io/gh/aliyun/aliyun-openapi-cpp-sdk)
The Alibaba Cloud C++ Software Development Kit (SDK) allows you to access Alibaba Cloud services such as Elastic Compute Service (ECS), Server Load Balancer (SLB), and CloudMonitor. You can access Alibaba Cloud services without the need to handle API related tasks, such as signing and constructing your requests.
This document introduces how to obtain and call Alibaba Cloud C++ SDK.
If you have any problem while using C++ SDK, please submit an [issue](https://github.com/aliyun/aliyun-openapi-cpp-sdk/issues/new).
## Prerequisites
- To use Alibaba Cloud C++ SDK, you must have an Alibaba Cloud account and an AccessKey.
The AccessKey is required when initializing the client. You can create an AccessKey in the Alibaba Cloud console. For more information, see [Create an AccessKey](https://usercenter.console.aliyun.com/?spm=5176.doc52740.2.3.QKZk8w#/manage/ak).
>**Note:** To increase the security of your account, we recommend that you use the AccessKey of the RAM user to access Alibaba Cloud services.
- To use Alibaba Cloud C++ SDK to access the APIs of a product, you must first activate the product on the [Alibaba Cloud console](https://home.console.aliyun.com/?spm=5176.doc52740.2.4.QKZk8w) if required.
- C++11 supported compiler installed
- Windows: Visual Studio 2015 or newer
- Linux: GCC 4.9 or newer
- CMake 3.0 or newer
- 4G memory or more
## Install C++ SDK from source code
### Linux
1. Install third-party libraries on the Linux platform, including `libcurl`, `libopenssl`, `libuuid`, and `libjsoncpp`.
- Run the following commands on the `Redhat/Fedora` system
```
sudo dnf install libcurl-devel openssl-devel libuuid-devel libjsoncpp-devel
```
- Run the following commands on the `Debian/Ubuntu` system
```
sudo apt-get install libcurl4-openssl-dev libssl-dev uuid-dev libjsoncpp-dev
```
2. Run the following commands to clone source codes from GitHub.
```bash
git clone https://github.com/aliyun/aliyun-openapi-cpp-sdk.git
```
3. Build and install SDK
- Manually build and install
```bash
cd aliyun-openapi-cpp-sdk
mkdir sdk_build
cd sdk_build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr ..
make
sudo make install
```
- Or you may do this with `easyinstall.sh` in the source directory
```shell
cd aliyun-openapi-cpp-sdk
sudo sh easyinstall.sh
```
**The C++ SDK will be installed to `/usr`.**
### windows
1. Install [perl](https://www.perl.org/get.html#win32).
2. Run the following command to clone code from Github via git-bash:
```bash
git clone https://github.com/aliyun/aliyun-openapi-cpp-sdk.git
```
2. Build Visual Studio solution
- Change directory to source code and make directory sdk_build
- Open CMake UI and
- `Browse Source` to open source code directory.
- `Browse build` to open the created sdk_build directory
- `Configure`
- `Generate`
3. Build and Install C++ SDK
- Open `aliyun-openapi-cpp-sdk\\sdk_build\\alibabacloud-sdk.sln` with Visual Studio
- Select `Release`
- Check INSTALL option from Build -> Configuration Manager
- Build->Build Solutions to build.
**SDK will be installed to `C:\Program File (x86)\alibabacloud-sdk`**
## Use the C++ SDK
Before using C++ SDK, you must first configure the preprocessor to define `ALIBABACLOUD_SHARED` to achieve dynamic linking with Alibaba Cloud C++ SDK shared libraries. Then you must create a client instance, specify the region of cloud services and provide authentication parameters before sending API requests.
The following code shows how to call the [DescribeInstances](~~25506~~) API of ECS to query detailed information of all ECS instances in a specific region.
```cpp
#include <iostream>
#include <alibabacloud/core/AlibabaCloud.h>
#include <alibabacloud/ecs/EcsClient.h>
using namespace AlibabaCloud;
using namespace AlibabaCloud::Ecs;
int main(int argc, char** argv) {
// Initialize the SDK
AlibabaCloud::InitializeSdk();
// Configure the ECS instance
ClientConfiguration configuration("<your-region-id>");
EcsClient client("<your-access-key-id>", "<your-access-key-secret>", configuration);
// Create an API request and set parameters
Model::DescribeInstancesRequest request;
request.setPageSize(10);
auto outcome = client.describeInstances(request);
if (!outcome.isSuccess()) {
// Handle exceptions
std::cout << outcome.error().errorCode() << std::endl;
AlibabaCloud::ShutdownSdk();
return -1;
}
std::cout << "totalCount: " << outcome.result().getTotalCount() << std::endl;
// Close the SDK
AlibabaCloud::ShutdownSdk();
return 0;
}
```
Copy the above to ecs_test.cc, then build with the following command.
```bash
~$ g++ -o ecstest ecs_test.cc --std=c++11 -lalibabacloud-sdk-core -l alibabacloud-sdk-ecs
~$ ./ecstest
# Result or error message will be shown here.
~$
```
**More [examples](https://github.com/aliyun/aliyun-openapi-cpp-sdk/tree/master/examples)**
## LICENSE
Please refer to [LICENSE](https://github.com/aliyun/aliyun-openapi-cpp-sdk/blob/master/LICENSE) (Apache 2.0 LICENSE).

View File

@@ -1,10 +1,13 @@
# 阿里云开发者C++工具套件
[![Build Status](https://travis-ci.org/aliyun/aliyun-openapi-cpp-sdk.svg?branch=master)](https://travis-ci.org/aliyun/aliyun-openapi-cpp-sdk)
[![codecov](https://codecov.io/gh/aliyun/aliyun-openapi-cpp-sdk/branch/master/graph/badge.svg)](https://codecov.io/gh/aliyun/aliyun-openapi-cpp-sdk)
欢迎使用阿里云开发者工具套件SDK
适用于阿里云的 C++ SDK 提供了一组现代化的 C++C++ 11 或更高版本)接口,让您不用复杂编程即可访问云服务器、云监控等多个阿里云服务。
如果您在使用SDK的过程中遇到任何问题欢迎前往[阿里云SDK问答社区](https://yq.aliyun.com/tags/type_ask-tagid_23350)提问,提问前请阅读[提问引导](https://help.aliyun.com/document_detail/93957.html)。亦可在当前GitHub提交Issues。
如果您在使用SDK的过程中遇到任何问题欢迎前往[阿里云SDK问答社区](https://yq.aliyun.com/tags/type_ask-tagid_23350)提问,提问前请阅读[提问引导](https://help.aliyun.com/document_detail/93957.html)。亦可在当前 GitHub [提交 Issues](https://github.com/aliyun/aliyun-openapi-cpp-sdk/issues/new)
完成本文档中的操作开始使用 C++ SDK。
@@ -19,8 +22,11 @@
* 开通了云产品服务。有些云产品如对象存储OSS需要先在[阿里云控制台](https://home.console.aliyun.com)开通服务。
* 安装支持 C++ 11 或更高版本的编译器:
* Visual Studio 2015 或以上版本
* GCC 4.9 或以上版本
* Windows: Visual Studio 2015 或以上版本
* Linux: GCC 4.9 或以上版本
* 安装 CMake 3.0 或以上版本
* 建议 4G 或以上内存
## 从源代码构建 SDK
@@ -33,43 +39,77 @@
git clone https://github.com/aliyun/aliyun-openapi-cpp-sdk.git
```
2. 安装 cmake 3.0 或以上版本,进入 SDK 创建生成必要的构建文件
2. 创建生成必要的构建文件
```
```bash
cd <path/to/aliyun-openapi-cpp-sdk>
mkdir sdk_build
cd sdk_build
cmake ..
```
### Windows
进入 sdk_build 目录使用 Visual Studio 打开 alibabacloud-sdk.sln 生成解决方案。
或者您也可以使用 VS 的开发人员命令提示符,执行以下命令编译并安装:
```
msbuild ALL_BUILD.vcxproj
msbuild INSTALL.vcxproj
```
### Linux
要在 Linux 平台进行编译, 您必须安装依赖的外部库文件 libcurl、libopenssl、libuuid、libjsoncpp, 通常情况下,系统的包管理器中的会有提供。
例如:在基于 Redhat / Fedora 的系统上安装这些软件包
```
```bash
sudo dnf install libcurl-devel openssl-devel libuuid-devel libjsoncpp-devel
```
在基于 Debian/Ubuntu 的系统
```bash
sudo apt-get install libcurl4-openssl-dev libssl-dev uuid-dev libjsoncpp-dev
```
在安装依赖库后执行以下命令编译并安装:
手动编译安装
```bash
cd aliyun-openapi-cpp-sdk
mkdir sdk_build
cd sdk_build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr ..
make
sudo make install
```
make
sudo make install
或者通过 `easyinstall.sh`一键式安装
```bash
cd aliyun-openapi-cpp-sdk
sudo sh easyinstall.sh
```
**C++ SDK 将被安装在 `/usr`.**
### Windows
通过 cmake 生成 Visual Studio 解决方案:
在 aliyun-openapi-cpp-sdk 下创建 sdk_build 目录
打开 cmake-ui 选择源代码目录和构建目录,点击 `配置(configure)``生成(generate)` 构建 VS 解决方案。
进入 sdk_build 目录使用 Visual Studio 打开 alibabacloud-sdk.sln 解决方案。
选择构建 `Release` 输出,并打开配置管理器勾选 `INSTALL`
构建 -> 生成解决方案。
或者您也可以使用 VS 的开发人员命令提示符,执行以下命令编译并安装:
```
msbuild ALL_BUILD.vcxproj
msbuild INSTALL.vcxproj
```
**C++ SDK 将安装在 `C:\Program File (x86)\alibabacloud-sdk` 目录**
**注意:请以管理员身份运行 Visual Studio否则无法安装 SDK**
## 如何使用 C++ SDK
在调用 C++ SDK时您首先需要配置预处理器定义 ALIBABACLOUD_SHARED 以引用阿里云 C++ SDK 的共享库,然后通过创建 Client 实例提供身份验证并指定云服务的地域然后发送API请求。
@@ -86,35 +126,46 @@ sudo make install
using namespace AlibabaCloud;
using namespace AlibabaCloud::Ecs;
int main(int argc, char** argv)
{
// 初始化 SDK
AlibabaCloud::InitializeSdk();
int main(int argc, char** argv) {
// 初始化 SDK
AlibabaCloud::InitializeSdk();
// 配置 ecs 实例
ClientConfiguration configuration("<your-region-id>");
EcsClient client("<your-access-key-id>", "<your-access-key-secret>", configuration);
// 配置 ecs 实例
ClientConfiguration configuration("<your-region-id>");
EcsClient client("<your-access-key-id>", "<your-access-key-secret>", configuration);
// 创建API请求并设置参数
Model::DescribeInstancesRequest request;
request.setPageSize(10);
// 创建API请求并设置参数
Model::DescribeInstancesRequest request;
request.setPageSize(10);
auto outcome = client.describeInstances(request);
if (!outcome.isSuccess())
{
// 异常处理
std::cout << outcome.error().errorCode() << std::endl;
AlibabaCloud::ShutdownSdk();
return -1;
}
std::cout << "totalCount: " << outcome.result().getTotalCount() << std::endl;
auto outcome = client.describeInstances(request);
if (!outcome.isSuccess()) {
// 异常处理
std::cout << outcome.error().errorCode() << std::endl;
AlibabaCloud::ShutdownSdk();
return -1;
}
// 关闭 SDK
AlibabaCloud::ShutdownSdk();
return 0;
std::cout << "totalCount: " << outcome.result().getTotalCount() << std::endl;
// 关闭 SDK
AlibabaCloud::ShutdownSdk();
return 0;
}
```
复制上述文件到 ecs_test.cc。
Linux 下
```bash
~$ g++ -o ecstest ecs_test.cc --std=c++11 -lalibabacloud-sdk-core -l alibabacloud-sdk-ecs
~$ ./ecstest
# 结果或错误返回将在此展示
~$
```
**更多 [例程](https://github.com/aliyun/aliyun-openapi-cpp-sdk/tree/master/examples) 请(参考)[https://github.com/aliyun/aliyun-openapi-cpp-sdk/blob/master/examples/README_zh.md]**
## 许可协议
请参阅 LICENSE 文件Apache 2.0 许可证)。

View File

@@ -1 +1 @@
1.33.4
1.34.11

View File

@@ -91,6 +91,8 @@ set(cdn_public_header_model
include/alibabacloud/cdn/model/ModifyCdnServiceResult.h
include/alibabacloud/cdn/model/DescribeLiveStreamRecordIndexFileRequest.h
include/alibabacloud/cdn/model/DescribeLiveStreamRecordIndexFileResult.h
include/alibabacloud/cdn/model/BatchSetCdnDomainConfigRequest.h
include/alibabacloud/cdn/model/BatchSetCdnDomainConfigResult.h
include/alibabacloud/cdn/model/DeleteUserUsageDataExportTaskRequest.h
include/alibabacloud/cdn/model/DeleteUserUsageDataExportTaskResult.h
include/alibabacloud/cdn/model/DescribeDomainHitRateDataRequest.h
@@ -386,6 +388,8 @@ set(cdn_src
src/model/ModifyCdnServiceResult.cc
src/model/DescribeLiveStreamRecordIndexFileRequest.cc
src/model/DescribeLiveStreamRecordIndexFileResult.cc
src/model/BatchSetCdnDomainConfigRequest.cc
src/model/BatchSetCdnDomainConfigResult.cc
src/model/DeleteUserUsageDataExportTaskRequest.cc
src/model/DeleteUserUsageDataExportTaskResult.cc
src/model/DescribeDomainHitRateDataRequest.cc

View File

@@ -92,6 +92,8 @@
#include "model/ModifyCdnServiceResult.h"
#include "model/DescribeLiveStreamRecordIndexFileRequest.h"
#include "model/DescribeLiveStreamRecordIndexFileResult.h"
#include "model/BatchSetCdnDomainConfigRequest.h"
#include "model/BatchSetCdnDomainConfigResult.h"
#include "model/DeleteUserUsageDataExportTaskRequest.h"
#include "model/DeleteUserUsageDataExportTaskResult.h"
#include "model/DescribeDomainHitRateDataRequest.h"
@@ -428,6 +430,9 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::DescribeLiveStreamRecordIndexFileResult> DescribeLiveStreamRecordIndexFileOutcome;
typedef std::future<DescribeLiveStreamRecordIndexFileOutcome> DescribeLiveStreamRecordIndexFileOutcomeCallable;
typedef std::function<void(const CdnClient*, const Model::DescribeLiveStreamRecordIndexFileRequest&, const DescribeLiveStreamRecordIndexFileOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeLiveStreamRecordIndexFileAsyncHandler;
typedef Outcome<Error, Model::BatchSetCdnDomainConfigResult> BatchSetCdnDomainConfigOutcome;
typedef std::future<BatchSetCdnDomainConfigOutcome> BatchSetCdnDomainConfigOutcomeCallable;
typedef std::function<void(const CdnClient*, const Model::BatchSetCdnDomainConfigRequest&, const BatchSetCdnDomainConfigOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> BatchSetCdnDomainConfigAsyncHandler;
typedef Outcome<Error, Model::DeleteUserUsageDataExportTaskResult> DeleteUserUsageDataExportTaskOutcome;
typedef std::future<DeleteUserUsageDataExportTaskOutcome> DeleteUserUsageDataExportTaskOutcomeCallable;
typedef std::function<void(const CdnClient*, const Model::DeleteUserUsageDataExportTaskRequest&, const DeleteUserUsageDataExportTaskOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DeleteUserUsageDataExportTaskAsyncHandler;
@@ -871,6 +876,9 @@ namespace AlibabaCloud
DescribeLiveStreamRecordIndexFileOutcome describeLiveStreamRecordIndexFile(const Model::DescribeLiveStreamRecordIndexFileRequest &request)const;
void describeLiveStreamRecordIndexFileAsync(const Model::DescribeLiveStreamRecordIndexFileRequest& request, const DescribeLiveStreamRecordIndexFileAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeLiveStreamRecordIndexFileOutcomeCallable describeLiveStreamRecordIndexFileCallable(const Model::DescribeLiveStreamRecordIndexFileRequest& request) const;
BatchSetCdnDomainConfigOutcome batchSetCdnDomainConfig(const Model::BatchSetCdnDomainConfigRequest &request)const;
void batchSetCdnDomainConfigAsync(const Model::BatchSetCdnDomainConfigRequest& request, const BatchSetCdnDomainConfigAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
BatchSetCdnDomainConfigOutcomeCallable batchSetCdnDomainConfigCallable(const Model::BatchSetCdnDomainConfigRequest& request) const;
DeleteUserUsageDataExportTaskOutcome deleteUserUsageDataExportTask(const Model::DeleteUserUsageDataExportTaskRequest &request)const;
void deleteUserUsageDataExportTaskAsync(const Model::DeleteUserUsageDataExportTaskRequest& request, const DeleteUserUsageDataExportTaskAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DeleteUserUsageDataExportTaskOutcomeCallable deleteUserUsageDataExportTaskCallable(const Model::DeleteUserUsageDataExportTaskRequest& request) const;

View File

@@ -0,0 +1,63 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CDN_MODEL_BATCHSETCDNDOMAINCONFIGREQUEST_H_
#define ALIBABACLOUD_CDN_MODEL_BATCHSETCDNDOMAINCONFIGREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/cdn/CdnExport.h>
namespace AlibabaCloud
{
namespace Cdn
{
namespace Model
{
class ALIBABACLOUD_CDN_EXPORT BatchSetCdnDomainConfigRequest : public RpcServiceRequest
{
public:
BatchSetCdnDomainConfigRequest();
~BatchSetCdnDomainConfigRequest();
std::string getFunctions()const;
void setFunctions(const std::string& functions);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getDomainNames()const;
void setDomainNames(const std::string& domainNames);
std::string getOwnerAccount()const;
void setOwnerAccount(const std::string& ownerAccount);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
private:
std::string functions_;
std::string securityToken_;
std::string domainNames_;
std::string ownerAccount_;
long ownerId_;
std::string accessKeyId_;
};
}
}
}
#endif // !ALIBABACLOUD_CDN_MODEL_BATCHSETCDNDOMAINCONFIGREQUEST_H_

View File

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

View File

@@ -35,29 +35,86 @@ namespace AlibabaCloud
DescribeCdnMonitorDataRequest();
~DescribeCdnMonitorDataRequest();
long getCallerParentId()const;
void setCallerParentId(long callerParentId);
bool getProxy_original_security_transport()const;
void setProxy_original_security_transport(bool proxy_original_security_transport);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getProxy_original_source_ip()const;
void setProxy_original_source_ip(const std::string& proxy_original_source_ip);
std::string getOwnerIdLoginEmail()const;
void setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail);
std::string getCallerType()const;
void setCallerType(const std::string& callerType);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getRequestContent()const;
void setRequestContent(const std::string& requestContent);
std::string getCallerBidEmail()const;
void setCallerBidEmail(const std::string& callerBidEmail);
std::string getCallerUidEmail()const;
void setCallerUidEmail(const std::string& callerUidEmail);
long getCallerUid()const;
void setCallerUid(long callerUid);
std::string getApp_ip()const;
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getOutString()const;
void setOutString(const std::string& outString);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
void setEndTime(const std::string& endTime);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getCallerBid()const;
void setCallerBid(const std::string& callerBid);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getVersion()const;
void setVersion(const std::string& version);
bool getProxy_trust_transport_info()const;
void setProxy_trust_transport_info(bool proxy_trust_transport_info);
bool getAk_mfa_present()const;
void setAk_mfa_present(bool ak_mfa_present);
bool getSecurity_transport()const;
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getFields()const;
void setFields(const std::string& fields);
private:
long callerParentId_;
bool proxy_original_security_transport_;
std::string startTime_;
std::string proxy_original_source_ip_;
std::string ownerIdLoginEmail_;
std::string callerType_;
std::string accessKeyId_;
std::string securityToken_;
std::string requestContent_;
std::string callerBidEmail_;
std::string callerUidEmail_;
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string outString_;
std::string domainName_;
std::string endTime_;
std::string interval_;
std::string startTime_;
std::string callerBid_;
long ownerId_;
std::string accessKeyId_;
std::string version_;
bool proxy_trust_transport_info_;
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
std::string interval_;
std::string fields_;
};
}

View File

@@ -46,7 +46,7 @@ namespace AlibabaCloud
DescribeCdnMonitorDataResult();
explicit DescribeCdnMonitorDataResult(const std::string &payload);
~DescribeCdnMonitorDataResult();
long getMonitorInterval()const;
std::string getMonitorInterval()const;
std::string getEndTime()const;
std::string getDomainName()const;
std::vector<CDNMonitorData> getMonitorDatas()const;
@@ -55,7 +55,7 @@ namespace AlibabaCloud
protected:
void parse(const std::string &payload);
private:
long monitorInterval_;
std::string monitorInterval_;
std::string endTime_;
std::string domainName_;
std::vector<CDNMonitorData> monitorDatas_;

View File

@@ -35,32 +35,98 @@ namespace AlibabaCloud
DescribeDomainAverageResponseTimeRequest();
~DescribeDomainAverageResponseTimeRequest();
long getCallerParentId()const;
void setCallerParentId(long callerParentId);
bool getProxy_original_security_transport()const;
void setProxy_original_security_transport(bool proxy_original_security_transport);
std::string getLocationNameEn()const;
void setLocationNameEn(const std::string& locationNameEn);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getIspNameEn()const;
void setIspNameEn(const std::string& ispNameEn);
std::string getProxy_original_source_ip()const;
void setProxy_original_source_ip(const std::string& proxy_original_source_ip);
std::string getOwnerIdLoginEmail()const;
void setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail);
std::string getCallerType()const;
void setCallerType(const std::string& callerType);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getDomainType()const;
void setDomainType(const std::string& domainType);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getRequestContent()const;
void setRequestContent(const std::string& requestContent);
std::string getCallerBidEmail()const;
void setCallerBidEmail(const std::string& callerBidEmail);
std::string getCallerUidEmail()const;
void setCallerUidEmail(const std::string& callerUidEmail);
long getCallerUid()const;
void setCallerUid(long callerUid);
std::string getApp_ip()const;
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getOutString()const;
void setOutString(const std::string& outString);
std::string getTimeMerge()const;
void setTimeMerge(const std::string& timeMerge);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
void setEndTime(const std::string& endTime);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getCallerBid()const;
void setCallerBid(const std::string& callerBid);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getVersion()const;
void setVersion(const std::string& version);
bool getProxy_trust_transport_info()const;
void setProxy_trust_transport_info(bool proxy_trust_transport_info);
bool getAk_mfa_present()const;
void setAk_mfa_present(bool ak_mfa_present);
bool getSecurity_transport()const;
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getFields()const;
void setFields(const std::string& fields);
private:
long callerParentId_;
bool proxy_original_security_transport_;
std::string locationNameEn_;
std::string startTime_;
std::string ispNameEn_;
std::string proxy_original_source_ip_;
std::string ownerIdLoginEmail_;
std::string callerType_;
std::string accessKeyId_;
std::string domainType_;
std::string securityToken_;
std::string requestContent_;
std::string callerBidEmail_;
std::string callerUidEmail_;
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string outString_;
std::string timeMerge_;
std::string domainName_;
std::string endTime_;
std::string interval_;
std::string startTime_;
std::string callerBid_;
long ownerId_;
std::string accessKeyId_;
std::string version_;
bool proxy_trust_transport_info_;
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
std::string interval_;
std::string fields_;
};
}

View File

@@ -43,19 +43,27 @@ namespace AlibabaCloud
explicit DescribeDomainAverageResponseTimeResult(const std::string &payload);
~DescribeDomainAverageResponseTimeResult();
std::vector<DataModule> getAvgRTPerInterval()const;
std::string getIspNameEn()const;
std::string getIspName()const;
std::string getEndTime()const;
std::string getDomainName()const;
std::string getDataInterval()const;
std::string getLocationNameEn()const;
std::string getStartTime()const;
std::string getDataInterval()const;
std::string getLocationName()const;
protected:
void parse(const std::string &payload);
private:
std::vector<DataModule> avgRTPerInterval_;
std::string ispNameEn_;
std::string ispName_;
std::string endTime_;
std::string domainName_;
std::string dataInterval_;
std::string locationNameEn_;
std::string startTime_;
std::string dataInterval_;
std::string locationName_;
};
}

View File

@@ -35,38 +35,86 @@ namespace AlibabaCloud
DescribeDomainHitRateDataRequest();
~DescribeDomainHitRateDataRequest();
long getCallerParentId()const;
void setCallerParentId(long callerParentId);
bool getProxy_original_security_transport()const;
void setProxy_original_security_transport(bool proxy_original_security_transport);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getProxy_original_source_ip()const;
void setProxy_original_source_ip(const std::string& proxy_original_source_ip);
std::string getOwnerIdLoginEmail()const;
void setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail);
std::string getCallerType()const;
void setCallerType(const std::string& callerType);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getTimeMerge()const;
void setTimeMerge(const std::string& timeMerge);
std::string getRequestContent()const;
void setRequestContent(const std::string& requestContent);
std::string getCallerBidEmail()const;
void setCallerBidEmail(const std::string& callerBidEmail);
std::string getCallerUidEmail()const;
void setCallerUidEmail(const std::string& callerUidEmail);
long getCallerUid()const;
void setCallerUid(long callerUid);
std::string getApp_ip()const;
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getOutString()const;
void setOutString(const std::string& outString);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
void setEndTime(const std::string& endTime);
std::string getLocationNameEn()const;
void setLocationNameEn(const std::string& locationNameEn);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getIspNameEn()const;
void setIspNameEn(const std::string& ispNameEn);
std::string getCallerBid()const;
void setCallerBid(const std::string& callerBid);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getVersion()const;
void setVersion(const std::string& version);
bool getProxy_trust_transport_info()const;
void setProxy_trust_transport_info(bool proxy_trust_transport_info);
bool getAk_mfa_present()const;
void setAk_mfa_present(bool ak_mfa_present);
bool getSecurity_transport()const;
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getFields()const;
void setFields(const std::string& fields);
private:
long callerParentId_;
bool proxy_original_security_transport_;
std::string startTime_;
std::string proxy_original_source_ip_;
std::string ownerIdLoginEmail_;
std::string callerType_;
std::string accessKeyId_;
std::string securityToken_;
std::string timeMerge_;
std::string requestContent_;
std::string callerBidEmail_;
std::string callerUidEmail_;
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string outString_;
std::string domainName_;
std::string endTime_;
std::string locationNameEn_;
std::string interval_;
std::string startTime_;
std::string ispNameEn_;
std::string callerBid_;
long ownerId_;
std::string accessKeyId_;
std::string version_;
bool proxy_trust_transport_info_;
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
std::string interval_;
std::string fields_;
};
}

View File

@@ -45,8 +45,8 @@ namespace AlibabaCloud
std::vector<DataModule> getHitRateInterval()const;
std::string getEndTime()const;
std::string getDomainName()const;
std::string getDataInterval()const;
std::string getStartTime()const;
std::string getDataInterval()const;
protected:
void parse(const std::string &payload);
@@ -54,8 +54,8 @@ namespace AlibabaCloud
std::vector<DataModule> hitRateInterval_;
std::string endTime_;
std::string domainName_;
std::string dataInterval_;
std::string startTime_;
std::string dataInterval_;
};
}

View File

@@ -35,38 +35,95 @@ namespace AlibabaCloud
DescribeDomainHttpCodeDataRequest();
~DescribeDomainHttpCodeDataRequest();
long getCallerParentId()const;
void setCallerParentId(long callerParentId);
bool getProxy_original_security_transport()const;
void setProxy_original_security_transport(bool proxy_original_security_transport);
std::string getLocationNameEn()const;
void setLocationNameEn(const std::string& locationNameEn);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getIspNameEn()const;
void setIspNameEn(const std::string& ispNameEn);
std::string getProxy_original_source_ip()const;
void setProxy_original_source_ip(const std::string& proxy_original_source_ip);
std::string getOwnerIdLoginEmail()const;
void setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail);
std::string getCallerType()const;
void setCallerType(const std::string& callerType);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getRequestContent()const;
void setRequestContent(const std::string& requestContent);
std::string getCallerBidEmail()const;
void setCallerBidEmail(const std::string& callerBidEmail);
std::string getCallerUidEmail()const;
void setCallerUidEmail(const std::string& callerUidEmail);
long getCallerUid()const;
void setCallerUid(long callerUid);
std::string getApp_ip()const;
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getOutString()const;
void setOutString(const std::string& outString);
std::string getTimeMerge()const;
void setTimeMerge(const std::string& timeMerge);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
void setEndTime(const std::string& endTime);
std::string getLocationNameEn()const;
void setLocationNameEn(const std::string& locationNameEn);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getIspNameEn()const;
void setIspNameEn(const std::string& ispNameEn);
std::string getCallerBid()const;
void setCallerBid(const std::string& callerBid);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getVersion()const;
void setVersion(const std::string& version);
bool getProxy_trust_transport_info()const;
void setProxy_trust_transport_info(bool proxy_trust_transport_info);
bool getAk_mfa_present()const;
void setAk_mfa_present(bool ak_mfa_present);
bool getSecurity_transport()const;
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getFields()const;
void setFields(const std::string& fields);
private:
long callerParentId_;
bool proxy_original_security_transport_;
std::string locationNameEn_;
std::string startTime_;
std::string ispNameEn_;
std::string proxy_original_source_ip_;
std::string ownerIdLoginEmail_;
std::string callerType_;
std::string accessKeyId_;
std::string securityToken_;
std::string requestContent_;
std::string callerBidEmail_;
std::string callerUidEmail_;
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string outString_;
std::string timeMerge_;
std::string domainName_;
std::string endTime_;
std::string locationNameEn_;
std::string interval_;
std::string startTime_;
std::string ispNameEn_;
std::string callerBid_;
long ownerId_;
std::string accessKeyId_;
std::string version_;
bool proxy_trust_transport_info_;
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
std::string interval_;
std::string fields_;
};
}

View File

@@ -50,8 +50,8 @@ namespace AlibabaCloud
~DescribeDomainHttpCodeDataResult();
std::string getEndTime()const;
std::string getDomainName()const;
std::string getDataInterval()const;
std::string getStartTime()const;
std::string getDataInterval()const;
std::vector<UsageData> getHttpCodeData()const;
protected:
@@ -59,8 +59,8 @@ namespace AlibabaCloud
private:
std::string endTime_;
std::string domainName_;
std::string dataInterval_;
std::string startTime_;
std::string dataInterval_;
std::vector<UsageData> httpCodeData_;
};

View File

@@ -35,26 +35,83 @@ namespace AlibabaCloud
DescribeDomainISPDataRequest();
~DescribeDomainISPDataRequest();
long getCallerParentId()const;
void setCallerParentId(long callerParentId);
bool getProxy_original_security_transport()const;
void setProxy_original_security_transport(bool proxy_original_security_transport);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getProxy_original_source_ip()const;
void setProxy_original_source_ip(const std::string& proxy_original_source_ip);
std::string getOwnerIdLoginEmail()const;
void setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail);
std::string getCallerType()const;
void setCallerType(const std::string& callerType);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getRequestContent()const;
void setRequestContent(const std::string& requestContent);
std::string getCallerBidEmail()const;
void setCallerBidEmail(const std::string& callerBidEmail);
std::string getCallerUidEmail()const;
void setCallerUidEmail(const std::string& callerUidEmail);
long getCallerUid()const;
void setCallerUid(long callerUid);
std::string getApp_ip()const;
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getProduct()const;
void setProduct(const std::string& product);
std::string getOutString()const;
void setOutString(const std::string& outString);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
void setEndTime(const std::string& endTime);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getCallerBid()const;
void setCallerBid(const std::string& callerBid);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getVersion()const;
void setVersion(const std::string& version);
bool getProxy_trust_transport_info()const;
void setProxy_trust_transport_info(bool proxy_trust_transport_info);
bool getAk_mfa_present()const;
void setAk_mfa_present(bool ak_mfa_present);
bool getSecurity_transport()const;
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
private:
long callerParentId_;
bool proxy_original_security_transport_;
std::string startTime_;
std::string proxy_original_source_ip_;
std::string ownerIdLoginEmail_;
std::string callerType_;
std::string accessKeyId_;
std::string securityToken_;
std::string requestContent_;
std::string callerBidEmail_;
std::string callerUidEmail_;
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string product_;
std::string outString_;
std::string domainName_;
std::string endTime_;
std::string startTime_;
std::string callerBid_;
long ownerId_;
std::string accessKeyId_;
std::string version_;
bool proxy_trust_transport_info_;
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
};
}

View File

@@ -67,8 +67,6 @@ namespace AlibabaCloud
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getProduct()const;
void setProduct(const std::string& product);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
@@ -87,6 +85,10 @@ namespace AlibabaCloud
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getFields()const;
void setFields(const std::string& fields);
private:
long callerParentId_;
@@ -105,7 +107,6 @@ namespace AlibabaCloud
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string product_;
std::string domainName_;
std::string endTime_;
std::string callerBid_;
@@ -115,6 +116,8 @@ namespace AlibabaCloud
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
std::string interval_;
std::string fields_;
};
}

View File

@@ -63,8 +63,6 @@ namespace AlibabaCloud
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getProduct()const;
void setProduct(const std::string& product);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
@@ -83,6 +81,10 @@ namespace AlibabaCloud
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getFields()const;
void setFields(const std::string& fields);
private:
long callerParentId_;
@@ -99,7 +101,6 @@ namespace AlibabaCloud
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string product_;
std::string domainName_;
std::string endTime_;
std::string callerBid_;
@@ -109,6 +110,8 @@ namespace AlibabaCloud
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
std::string interval_;
std::string fields_;
};
}

View File

@@ -67,8 +67,6 @@ namespace AlibabaCloud
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getProduct()const;
void setProduct(const std::string& product);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
@@ -87,6 +85,10 @@ namespace AlibabaCloud
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getFields()const;
void setFields(const std::string& fields);
private:
long callerParentId_;
@@ -105,7 +107,6 @@ namespace AlibabaCloud
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string product_;
std::string domainName_;
std::string endTime_;
std::string callerBid_;
@@ -115,6 +116,8 @@ namespace AlibabaCloud
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
std::string interval_;
std::string fields_;
};
}

View File

@@ -63,8 +63,6 @@ namespace AlibabaCloud
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getProduct()const;
void setProduct(const std::string& product);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
@@ -83,6 +81,10 @@ namespace AlibabaCloud
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getFields()const;
void setFields(const std::string& fields);
private:
long callerParentId_;
@@ -99,7 +101,6 @@ namespace AlibabaCloud
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string product_;
std::string domainName_;
std::string endTime_;
std::string callerBid_;
@@ -109,6 +110,8 @@ namespace AlibabaCloud
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
std::string interval_;
std::string fields_;
};
}

View File

@@ -35,26 +35,83 @@ namespace AlibabaCloud
DescribeDomainRegionDataRequest();
~DescribeDomainRegionDataRequest();
long getCallerParentId()const;
void setCallerParentId(long callerParentId);
bool getProxy_original_security_transport()const;
void setProxy_original_security_transport(bool proxy_original_security_transport);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getProxy_original_source_ip()const;
void setProxy_original_source_ip(const std::string& proxy_original_source_ip);
std::string getOwnerIdLoginEmail()const;
void setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail);
std::string getCallerType()const;
void setCallerType(const std::string& callerType);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getRequestContent()const;
void setRequestContent(const std::string& requestContent);
std::string getCallerBidEmail()const;
void setCallerBidEmail(const std::string& callerBidEmail);
std::string getCallerUidEmail()const;
void setCallerUidEmail(const std::string& callerUidEmail);
long getCallerUid()const;
void setCallerUid(long callerUid);
std::string getApp_ip()const;
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getProduct()const;
void setProduct(const std::string& product);
std::string getOutString()const;
void setOutString(const std::string& outString);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
void setEndTime(const std::string& endTime);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getCallerBid()const;
void setCallerBid(const std::string& callerBid);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getVersion()const;
void setVersion(const std::string& version);
bool getProxy_trust_transport_info()const;
void setProxy_trust_transport_info(bool proxy_trust_transport_info);
bool getAk_mfa_present()const;
void setAk_mfa_present(bool ak_mfa_present);
bool getSecurity_transport()const;
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
private:
long callerParentId_;
bool proxy_original_security_transport_;
std::string startTime_;
std::string proxy_original_source_ip_;
std::string ownerIdLoginEmail_;
std::string callerType_;
std::string accessKeyId_;
std::string securityToken_;
std::string requestContent_;
std::string callerBidEmail_;
std::string callerUidEmail_;
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string product_;
std::string outString_;
std::string domainName_;
std::string endTime_;
std::string startTime_;
std::string callerBid_;
long ownerId_;
std::string accessKeyId_;
std::string version_;
bool proxy_trust_transport_info_;
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
};
}

View File

@@ -35,29 +35,86 @@ namespace AlibabaCloud
DescribeDomainReqHitRateDataRequest();
~DescribeDomainReqHitRateDataRequest();
long getCallerParentId()const;
void setCallerParentId(long callerParentId);
bool getProxy_original_security_transport()const;
void setProxy_original_security_transport(bool proxy_original_security_transport);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getProxy_original_source_ip()const;
void setProxy_original_source_ip(const std::string& proxy_original_source_ip);
std::string getOwnerIdLoginEmail()const;
void setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail);
std::string getCallerType()const;
void setCallerType(const std::string& callerType);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getRequestContent()const;
void setRequestContent(const std::string& requestContent);
std::string getCallerBidEmail()const;
void setCallerBidEmail(const std::string& callerBidEmail);
std::string getCallerUidEmail()const;
void setCallerUidEmail(const std::string& callerUidEmail);
long getCallerUid()const;
void setCallerUid(long callerUid);
std::string getApp_ip()const;
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getOutString()const;
void setOutString(const std::string& outString);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
void setEndTime(const std::string& endTime);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getCallerBid()const;
void setCallerBid(const std::string& callerBid);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getVersion()const;
void setVersion(const std::string& version);
bool getProxy_trust_transport_info()const;
void setProxy_trust_transport_info(bool proxy_trust_transport_info);
bool getAk_mfa_present()const;
void setAk_mfa_present(bool ak_mfa_present);
bool getSecurity_transport()const;
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
std::string getInterval()const;
void setInterval(const std::string& interval);
std::string getFields()const;
void setFields(const std::string& fields);
private:
long callerParentId_;
bool proxy_original_security_transport_;
std::string startTime_;
std::string proxy_original_source_ip_;
std::string ownerIdLoginEmail_;
std::string callerType_;
std::string accessKeyId_;
std::string securityToken_;
std::string requestContent_;
std::string callerBidEmail_;
std::string callerUidEmail_;
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string outString_;
std::string domainName_;
std::string endTime_;
std::string interval_;
std::string startTime_;
std::string callerBid_;
long ownerId_;
std::string accessKeyId_;
std::string version_;
bool proxy_trust_transport_info_;
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
std::string interval_;
std::string fields_;
};
}

View File

@@ -45,8 +45,8 @@ namespace AlibabaCloud
std::vector<DataModule> getReqHitRateInterval()const;
std::string getEndTime()const;
std::string getDomainName()const;
std::string getDataInterval()const;
std::string getStartTime()const;
std::string getDataInterval()const;
protected:
void parse(const std::string &payload);
@@ -54,8 +54,8 @@ namespace AlibabaCloud
std::vector<DataModule> reqHitRateInterval_;
std::string endTime_;
std::string domainName_;
std::string dataInterval_;
std::string startTime_;
std::string dataInterval_;
};
}

View File

@@ -35,26 +35,83 @@ namespace AlibabaCloud
DescribeDomainsUsageByDayRequest();
~DescribeDomainsUsageByDayRequest();
long getCallerParentId()const;
void setCallerParentId(long callerParentId);
bool getProxy_original_security_transport()const;
void setProxy_original_security_transport(bool proxy_original_security_transport);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getProxy_original_source_ip()const;
void setProxy_original_source_ip(const std::string& proxy_original_source_ip);
std::string getOwnerIdLoginEmail()const;
void setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail);
std::string getCallerType()const;
void setCallerType(const std::string& callerType);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getRequestContent()const;
void setRequestContent(const std::string& requestContent);
std::string getCallerBidEmail()const;
void setCallerBidEmail(const std::string& callerBidEmail);
std::string getCallerUidEmail()const;
void setCallerUidEmail(const std::string& callerUidEmail);
long getCallerUid()const;
void setCallerUid(long callerUid);
std::string getApp_ip()const;
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getProduct()const;
void setProduct(const std::string& product);
std::string getOutString()const;
void setOutString(const std::string& outString);
std::string getDomainName()const;
void setDomainName(const std::string& domainName);
std::string getEndTime()const;
void setEndTime(const std::string& endTime);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
std::string getCallerBid()const;
void setCallerBid(const std::string& callerBid);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getVersion()const;
void setVersion(const std::string& version);
bool getProxy_trust_transport_info()const;
void setProxy_trust_transport_info(bool proxy_trust_transport_info);
bool getAk_mfa_present()const;
void setAk_mfa_present(bool ak_mfa_present);
bool getSecurity_transport()const;
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
private:
long callerParentId_;
bool proxy_original_security_transport_;
std::string startTime_;
std::string proxy_original_source_ip_;
std::string ownerIdLoginEmail_;
std::string callerType_;
std::string accessKeyId_;
std::string securityToken_;
std::string requestContent_;
std::string callerBidEmail_;
std::string callerUidEmail_;
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string product_;
std::string outString_;
std::string domainName_;
std::string endTime_;
std::string startTime_;
std::string callerBid_;
long ownerId_;
std::string accessKeyId_;
std::string version_;
bool proxy_trust_transport_info_;
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
};
}

View File

@@ -35,26 +35,80 @@ namespace AlibabaCloud
DescribeTopDomainsByFlowRequest();
~DescribeTopDomainsByFlowRequest();
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
long getLimit()const;
void setLimit(long limit);
std::string getEndTime()const;
void setEndTime(const std::string& endTime);
long getCallerParentId()const;
void setCallerParentId(long callerParentId);
bool getProxy_original_security_transport()const;
void setProxy_original_security_transport(bool proxy_original_security_transport);
std::string getStartTime()const;
void setStartTime(const std::string& startTime);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getProxy_original_source_ip()const;
void setProxy_original_source_ip(const std::string& proxy_original_source_ip);
std::string getOwnerIdLoginEmail()const;
void setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail);
std::string getCallerType()const;
void setCallerType(const std::string& callerType);
std::string getAccessKeyId()const;
void setAccessKeyId(const std::string& accessKeyId);
std::string getSecurityToken()const;
void setSecurityToken(const std::string& securityToken);
std::string getRequestContent()const;
void setRequestContent(const std::string& requestContent);
long getLimit()const;
void setLimit(long limit);
std::string getCallerBidEmail()const;
void setCallerBidEmail(const std::string& callerBidEmail);
std::string getCallerUidEmail()const;
void setCallerUidEmail(const std::string& callerUidEmail);
long getCallerUid()const;
void setCallerUid(long callerUid);
std::string getApp_ip()const;
void setApp_ip(const std::string& app_ip);
std::string getPopProduct()const;
void setPopProduct(const std::string& popProduct);
std::string getProduct()const;
void setProduct(const std::string& product);
std::string getEndTime()const;
void setEndTime(const std::string& endTime);
std::string getCallerBid()const;
void setCallerBid(const std::string& callerBid);
long getOwnerId()const;
void setOwnerId(long ownerId);
std::string getVersion()const;
void setVersion(const std::string& version);
bool getProxy_trust_transport_info()const;
void setProxy_trust_transport_info(bool proxy_trust_transport_info);
bool getAk_mfa_present()const;
void setAk_mfa_present(bool ak_mfa_present);
bool getSecurity_transport()const;
void setSecurity_transport(bool security_transport);
std::string getRequestId()const;
void setRequestId(const std::string& requestId);
private:
std::string securityToken_;
long limit_;
std::string endTime_;
long callerParentId_;
bool proxy_original_security_transport_;
std::string startTime_;
long ownerId_;
std::string proxy_original_source_ip_;
std::string ownerIdLoginEmail_;
std::string callerType_;
std::string accessKeyId_;
std::string securityToken_;
std::string requestContent_;
long limit_;
std::string callerBidEmail_;
std::string callerUidEmail_;
long callerUid_;
std::string app_ip_;
std::string popProduct_;
std::string product_;
std::string endTime_;
std::string callerBid_;
long ownerId_;
std::string version_;
bool proxy_trust_transport_info_;
bool ak_mfa_present_;
bool security_transport_;
std::string requestId_;
};
}

View File

@@ -42,6 +42,8 @@ namespace AlibabaCloud
std::string startTime;
};
std::string status;
std::string taskId;
std::string taskName;
std::string createTime;
std::string updateTime;
TaskConfig taskConfig;

View File

@@ -37,6 +37,8 @@ namespace AlibabaCloud
std::string getPrivateKey()const;
void setPrivateKey(const std::string& privateKey);
std::string getForceSet()const;
void setForceSet(const std::string& forceSet);
std::string getServerCertificateStatus()const;
void setServerCertificateStatus(const std::string& serverCertificateStatus);
std::string getServerCertificate()const;
@@ -58,6 +60,7 @@ namespace AlibabaCloud
private:
std::string privateKey_;
std::string forceSet_;
std::string serverCertificateStatus_;
std::string serverCertificate_;
std::string securityToken_;

View File

@@ -1311,6 +1311,42 @@ CdnClient::DescribeLiveStreamRecordIndexFileOutcomeCallable CdnClient::describeL
return task->get_future();
}
CdnClient::BatchSetCdnDomainConfigOutcome CdnClient::batchSetCdnDomainConfig(const BatchSetCdnDomainConfigRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return BatchSetCdnDomainConfigOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return BatchSetCdnDomainConfigOutcome(BatchSetCdnDomainConfigResult(outcome.result()));
else
return BatchSetCdnDomainConfigOutcome(outcome.error());
}
void CdnClient::batchSetCdnDomainConfigAsync(const BatchSetCdnDomainConfigRequest& request, const BatchSetCdnDomainConfigAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, batchSetCdnDomainConfig(request), context);
};
asyncExecute(new Runnable(fn));
}
CdnClient::BatchSetCdnDomainConfigOutcomeCallable CdnClient::batchSetCdnDomainConfigCallable(const BatchSetCdnDomainConfigRequest &request) const
{
auto task = std::make_shared<std::packaged_task<BatchSetCdnDomainConfigOutcome()>>(
[this, request]()
{
return this->batchSetCdnDomainConfig(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
CdnClient::DeleteUserUsageDataExportTaskOutcome CdnClient::deleteUserUsageDataExportTask(const DeleteUserUsageDataExportTaskRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();

View File

@@ -0,0 +1,93 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/cdn/model/BatchSetCdnDomainConfigRequest.h>
using AlibabaCloud::Cdn::Model::BatchSetCdnDomainConfigRequest;
BatchSetCdnDomainConfigRequest::BatchSetCdnDomainConfigRequest() :
RpcServiceRequest("cdn", "2014-11-11", "BatchSetCdnDomainConfig")
{}
BatchSetCdnDomainConfigRequest::~BatchSetCdnDomainConfigRequest()
{}
std::string BatchSetCdnDomainConfigRequest::getFunctions()const
{
return functions_;
}
void BatchSetCdnDomainConfigRequest::setFunctions(const std::string& functions)
{
functions_ = functions;
setParameter("Functions", functions);
}
std::string BatchSetCdnDomainConfigRequest::getSecurityToken()const
{
return securityToken_;
}
void BatchSetCdnDomainConfigRequest::setSecurityToken(const std::string& securityToken)
{
securityToken_ = securityToken;
setParameter("SecurityToken", securityToken);
}
std::string BatchSetCdnDomainConfigRequest::getDomainNames()const
{
return domainNames_;
}
void BatchSetCdnDomainConfigRequest::setDomainNames(const std::string& domainNames)
{
domainNames_ = domainNames;
setParameter("DomainNames", domainNames);
}
std::string BatchSetCdnDomainConfigRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void BatchSetCdnDomainConfigRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setParameter("OwnerAccount", ownerAccount);
}
long BatchSetCdnDomainConfigRequest::getOwnerId()const
{
return ownerId_;
}
void BatchSetCdnDomainConfigRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
}
std::string BatchSetCdnDomainConfigRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void BatchSetCdnDomainConfigRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}

View File

@@ -0,0 +1,45 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/cdn/model/BatchSetCdnDomainConfigResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Cdn;
using namespace AlibabaCloud::Cdn::Model;
BatchSetCdnDomainConfigResult::BatchSetCdnDomainConfigResult() :
ServiceResult()
{}
BatchSetCdnDomainConfigResult::BatchSetCdnDomainConfigResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
BatchSetCdnDomainConfigResult::~BatchSetCdnDomainConfigResult()
{}
void BatchSetCdnDomainConfigResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
}

View File

@@ -25,6 +25,83 @@ DescribeCdnMonitorDataRequest::DescribeCdnMonitorDataRequest() :
DescribeCdnMonitorDataRequest::~DescribeCdnMonitorDataRequest()
{}
long DescribeCdnMonitorDataRequest::getCallerParentId()const
{
return callerParentId_;
}
void DescribeCdnMonitorDataRequest::setCallerParentId(long callerParentId)
{
callerParentId_ = callerParentId;
setParameter("CallerParentId", std::to_string(callerParentId));
}
bool DescribeCdnMonitorDataRequest::getProxy_original_security_transport()const
{
return proxy_original_security_transport_;
}
void DescribeCdnMonitorDataRequest::setProxy_original_security_transport(bool proxy_original_security_transport)
{
proxy_original_security_transport_ = proxy_original_security_transport;
setParameter("Proxy_original_security_transport", std::to_string(proxy_original_security_transport));
}
std::string DescribeCdnMonitorDataRequest::getStartTime()const
{
return startTime_;
}
void DescribeCdnMonitorDataRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeCdnMonitorDataRequest::getProxy_original_source_ip()const
{
return proxy_original_source_ip_;
}
void DescribeCdnMonitorDataRequest::setProxy_original_source_ip(const std::string& proxy_original_source_ip)
{
proxy_original_source_ip_ = proxy_original_source_ip;
setParameter("Proxy_original_source_ip", proxy_original_source_ip);
}
std::string DescribeCdnMonitorDataRequest::getOwnerIdLoginEmail()const
{
return ownerIdLoginEmail_;
}
void DescribeCdnMonitorDataRequest::setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail)
{
ownerIdLoginEmail_ = ownerIdLoginEmail;
setParameter("OwnerIdLoginEmail", ownerIdLoginEmail);
}
std::string DescribeCdnMonitorDataRequest::getCallerType()const
{
return callerType_;
}
void DescribeCdnMonitorDataRequest::setCallerType(const std::string& callerType)
{
callerType_ = callerType;
setParameter("CallerType", callerType);
}
std::string DescribeCdnMonitorDataRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeCdnMonitorDataRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeCdnMonitorDataRequest::getSecurityToken()const
{
return securityToken_;
@@ -36,6 +113,83 @@ void DescribeCdnMonitorDataRequest::setSecurityToken(const std::string& security
setParameter("SecurityToken", securityToken);
}
std::string DescribeCdnMonitorDataRequest::getRequestContent()const
{
return requestContent_;
}
void DescribeCdnMonitorDataRequest::setRequestContent(const std::string& requestContent)
{
requestContent_ = requestContent;
setParameter("RequestContent", requestContent);
}
std::string DescribeCdnMonitorDataRequest::getCallerBidEmail()const
{
return callerBidEmail_;
}
void DescribeCdnMonitorDataRequest::setCallerBidEmail(const std::string& callerBidEmail)
{
callerBidEmail_ = callerBidEmail;
setParameter("CallerBidEmail", callerBidEmail);
}
std::string DescribeCdnMonitorDataRequest::getCallerUidEmail()const
{
return callerUidEmail_;
}
void DescribeCdnMonitorDataRequest::setCallerUidEmail(const std::string& callerUidEmail)
{
callerUidEmail_ = callerUidEmail;
setParameter("CallerUidEmail", callerUidEmail);
}
long DescribeCdnMonitorDataRequest::getCallerUid()const
{
return callerUid_;
}
void DescribeCdnMonitorDataRequest::setCallerUid(long callerUid)
{
callerUid_ = callerUid;
setParameter("CallerUid", std::to_string(callerUid));
}
std::string DescribeCdnMonitorDataRequest::getApp_ip()const
{
return app_ip_;
}
void DescribeCdnMonitorDataRequest::setApp_ip(const std::string& app_ip)
{
app_ip_ = app_ip;
setParameter("App_ip", app_ip);
}
std::string DescribeCdnMonitorDataRequest::getPopProduct()const
{
return popProduct_;
}
void DescribeCdnMonitorDataRequest::setPopProduct(const std::string& popProduct)
{
popProduct_ = popProduct;
setParameter("PopProduct", popProduct);
}
std::string DescribeCdnMonitorDataRequest::getOutString()const
{
return outString_;
}
void DescribeCdnMonitorDataRequest::setOutString(const std::string& outString)
{
outString_ = outString;
setParameter("OutString", outString);
}
std::string DescribeCdnMonitorDataRequest::getDomainName()const
{
return domainName_;
@@ -58,26 +212,15 @@ void DescribeCdnMonitorDataRequest::setEndTime(const std::string& endTime)
setParameter("EndTime", endTime);
}
std::string DescribeCdnMonitorDataRequest::getInterval()const
std::string DescribeCdnMonitorDataRequest::getCallerBid()const
{
return interval_;
return callerBid_;
}
void DescribeCdnMonitorDataRequest::setInterval(const std::string& interval)
void DescribeCdnMonitorDataRequest::setCallerBid(const std::string& callerBid)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeCdnMonitorDataRequest::getStartTime()const
{
return startTime_;
}
void DescribeCdnMonitorDataRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
callerBid_ = callerBid;
setParameter("CallerBid", callerBid);
}
long DescribeCdnMonitorDataRequest::getOwnerId()const
@@ -91,14 +234,80 @@ void DescribeCdnMonitorDataRequest::setOwnerId(long ownerId)
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeCdnMonitorDataRequest::getAccessKeyId()const
std::string DescribeCdnMonitorDataRequest::getVersion()const
{
return accessKeyId_;
return version_;
}
void DescribeCdnMonitorDataRequest::setAccessKeyId(const std::string& accessKeyId)
void DescribeCdnMonitorDataRequest::setVersion(const std::string& version)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
version_ = version;
setParameter("Version", version);
}
bool DescribeCdnMonitorDataRequest::getProxy_trust_transport_info()const
{
return proxy_trust_transport_info_;
}
void DescribeCdnMonitorDataRequest::setProxy_trust_transport_info(bool proxy_trust_transport_info)
{
proxy_trust_transport_info_ = proxy_trust_transport_info;
setParameter("Proxy_trust_transport_info", std::to_string(proxy_trust_transport_info));
}
bool DescribeCdnMonitorDataRequest::getAk_mfa_present()const
{
return ak_mfa_present_;
}
void DescribeCdnMonitorDataRequest::setAk_mfa_present(bool ak_mfa_present)
{
ak_mfa_present_ = ak_mfa_present;
setParameter("Ak_mfa_present", std::to_string(ak_mfa_present));
}
bool DescribeCdnMonitorDataRequest::getSecurity_transport()const
{
return security_transport_;
}
void DescribeCdnMonitorDataRequest::setSecurity_transport(bool security_transport)
{
security_transport_ = security_transport;
setParameter("Security_transport", std::to_string(security_transport));
}
std::string DescribeCdnMonitorDataRequest::getRequestId()const
{
return requestId_;
}
void DescribeCdnMonitorDataRequest::setRequestId(const std::string& requestId)
{
requestId_ = requestId;
setParameter("RequestId", requestId);
}
std::string DescribeCdnMonitorDataRequest::getInterval()const
{
return interval_;
}
void DescribeCdnMonitorDataRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeCdnMonitorDataRequest::getFields()const
{
return fields_;
}
void DescribeCdnMonitorDataRequest::setFields(const std::string& fields)
{
fields_ = fields;
setParameter("Fields", fields);
}

View File

@@ -46,30 +46,30 @@ void DescribeCdnMonitorDataResult::parse(const std::string &payload)
CDNMonitorData monitorDatasObject;
if(!value["TimeStamp"].isNull())
monitorDatasObject.timeStamp = value["TimeStamp"].asString();
if(!value["QueryPerSecond"].isNull())
monitorDatasObject.queryPerSecond = value["QueryPerSecond"].asString();
if(!value["BytesPerSecond"].isNull())
monitorDatasObject.bytesPerSecond = value["BytesPerSecond"].asString();
if(!value["BytesHitRate"].isNull())
monitorDatasObject.bytesHitRate = value["BytesHitRate"].asString();
if(!value["QueryPerSecond"].isNull())
monitorDatasObject.queryPerSecond = value["QueryPerSecond"].asString();
if(!value["RequestHitRate"].isNull())
monitorDatasObject.requestHitRate = value["RequestHitRate"].asString();
if(!value["BytesHitRate"].isNull())
monitorDatasObject.bytesHitRate = value["BytesHitRate"].asString();
if(!value["AverageObjectSize"].isNull())
monitorDatasObject.averageObjectSize = value["AverageObjectSize"].asString();
monitorDatas_.push_back(monitorDatasObject);
}
if(!value["DomainName"].isNull())
domainName_ = value["DomainName"].asString();
if(!value["MonitorInterval"].isNull())
monitorInterval_ = std::stol(value["MonitorInterval"].asString());
if(!value["StartTime"].isNull())
startTime_ = value["StartTime"].asString();
if(!value["EndTime"].isNull())
endTime_ = value["EndTime"].asString();
if(!value["MonitorInterval"].isNull())
monitorInterval_ = value["MonitorInterval"].asString();
}
long DescribeCdnMonitorDataResult::getMonitorInterval()const
std::string DescribeCdnMonitorDataResult::getMonitorInterval()const
{
return monitorInterval_;
}

View File

@@ -25,6 +25,116 @@ DescribeDomainAverageResponseTimeRequest::DescribeDomainAverageResponseTimeReque
DescribeDomainAverageResponseTimeRequest::~DescribeDomainAverageResponseTimeRequest()
{}
long DescribeDomainAverageResponseTimeRequest::getCallerParentId()const
{
return callerParentId_;
}
void DescribeDomainAverageResponseTimeRequest::setCallerParentId(long callerParentId)
{
callerParentId_ = callerParentId;
setParameter("CallerParentId", std::to_string(callerParentId));
}
bool DescribeDomainAverageResponseTimeRequest::getProxy_original_security_transport()const
{
return proxy_original_security_transport_;
}
void DescribeDomainAverageResponseTimeRequest::setProxy_original_security_transport(bool proxy_original_security_transport)
{
proxy_original_security_transport_ = proxy_original_security_transport;
setParameter("Proxy_original_security_transport", std::to_string(proxy_original_security_transport));
}
std::string DescribeDomainAverageResponseTimeRequest::getLocationNameEn()const
{
return locationNameEn_;
}
void DescribeDomainAverageResponseTimeRequest::setLocationNameEn(const std::string& locationNameEn)
{
locationNameEn_ = locationNameEn;
setParameter("LocationNameEn", locationNameEn);
}
std::string DescribeDomainAverageResponseTimeRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainAverageResponseTimeRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeDomainAverageResponseTimeRequest::getIspNameEn()const
{
return ispNameEn_;
}
void DescribeDomainAverageResponseTimeRequest::setIspNameEn(const std::string& ispNameEn)
{
ispNameEn_ = ispNameEn;
setParameter("IspNameEn", ispNameEn);
}
std::string DescribeDomainAverageResponseTimeRequest::getProxy_original_source_ip()const
{
return proxy_original_source_ip_;
}
void DescribeDomainAverageResponseTimeRequest::setProxy_original_source_ip(const std::string& proxy_original_source_ip)
{
proxy_original_source_ip_ = proxy_original_source_ip;
setParameter("Proxy_original_source_ip", proxy_original_source_ip);
}
std::string DescribeDomainAverageResponseTimeRequest::getOwnerIdLoginEmail()const
{
return ownerIdLoginEmail_;
}
void DescribeDomainAverageResponseTimeRequest::setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail)
{
ownerIdLoginEmail_ = ownerIdLoginEmail;
setParameter("OwnerIdLoginEmail", ownerIdLoginEmail);
}
std::string DescribeDomainAverageResponseTimeRequest::getCallerType()const
{
return callerType_;
}
void DescribeDomainAverageResponseTimeRequest::setCallerType(const std::string& callerType)
{
callerType_ = callerType;
setParameter("CallerType", callerType);
}
std::string DescribeDomainAverageResponseTimeRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeDomainAverageResponseTimeRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeDomainAverageResponseTimeRequest::getDomainType()const
{
return domainType_;
}
void DescribeDomainAverageResponseTimeRequest::setDomainType(const std::string& domainType)
{
domainType_ = domainType;
setParameter("DomainType", domainType);
}
std::string DescribeDomainAverageResponseTimeRequest::getSecurityToken()const
{
return securityToken_;
@@ -36,6 +146,83 @@ void DescribeDomainAverageResponseTimeRequest::setSecurityToken(const std::strin
setParameter("SecurityToken", securityToken);
}
std::string DescribeDomainAverageResponseTimeRequest::getRequestContent()const
{
return requestContent_;
}
void DescribeDomainAverageResponseTimeRequest::setRequestContent(const std::string& requestContent)
{
requestContent_ = requestContent;
setParameter("RequestContent", requestContent);
}
std::string DescribeDomainAverageResponseTimeRequest::getCallerBidEmail()const
{
return callerBidEmail_;
}
void DescribeDomainAverageResponseTimeRequest::setCallerBidEmail(const std::string& callerBidEmail)
{
callerBidEmail_ = callerBidEmail;
setParameter("CallerBidEmail", callerBidEmail);
}
std::string DescribeDomainAverageResponseTimeRequest::getCallerUidEmail()const
{
return callerUidEmail_;
}
void DescribeDomainAverageResponseTimeRequest::setCallerUidEmail(const std::string& callerUidEmail)
{
callerUidEmail_ = callerUidEmail;
setParameter("CallerUidEmail", callerUidEmail);
}
long DescribeDomainAverageResponseTimeRequest::getCallerUid()const
{
return callerUid_;
}
void DescribeDomainAverageResponseTimeRequest::setCallerUid(long callerUid)
{
callerUid_ = callerUid;
setParameter("CallerUid", std::to_string(callerUid));
}
std::string DescribeDomainAverageResponseTimeRequest::getApp_ip()const
{
return app_ip_;
}
void DescribeDomainAverageResponseTimeRequest::setApp_ip(const std::string& app_ip)
{
app_ip_ = app_ip;
setParameter("App_ip", app_ip);
}
std::string DescribeDomainAverageResponseTimeRequest::getPopProduct()const
{
return popProduct_;
}
void DescribeDomainAverageResponseTimeRequest::setPopProduct(const std::string& popProduct)
{
popProduct_ = popProduct;
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainAverageResponseTimeRequest::getOutString()const
{
return outString_;
}
void DescribeDomainAverageResponseTimeRequest::setOutString(const std::string& outString)
{
outString_ = outString;
setParameter("OutString", outString);
}
std::string DescribeDomainAverageResponseTimeRequest::getTimeMerge()const
{
return timeMerge_;
@@ -69,26 +256,15 @@ void DescribeDomainAverageResponseTimeRequest::setEndTime(const std::string& end
setParameter("EndTime", endTime);
}
std::string DescribeDomainAverageResponseTimeRequest::getInterval()const
std::string DescribeDomainAverageResponseTimeRequest::getCallerBid()const
{
return interval_;
return callerBid_;
}
void DescribeDomainAverageResponseTimeRequest::setInterval(const std::string& interval)
void DescribeDomainAverageResponseTimeRequest::setCallerBid(const std::string& callerBid)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainAverageResponseTimeRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainAverageResponseTimeRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
callerBid_ = callerBid;
setParameter("CallerBid", callerBid);
}
long DescribeDomainAverageResponseTimeRequest::getOwnerId()const
@@ -102,14 +278,80 @@ void DescribeDomainAverageResponseTimeRequest::setOwnerId(long ownerId)
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeDomainAverageResponseTimeRequest::getAccessKeyId()const
std::string DescribeDomainAverageResponseTimeRequest::getVersion()const
{
return accessKeyId_;
return version_;
}
void DescribeDomainAverageResponseTimeRequest::setAccessKeyId(const std::string& accessKeyId)
void DescribeDomainAverageResponseTimeRequest::setVersion(const std::string& version)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
version_ = version;
setParameter("Version", version);
}
bool DescribeDomainAverageResponseTimeRequest::getProxy_trust_transport_info()const
{
return proxy_trust_transport_info_;
}
void DescribeDomainAverageResponseTimeRequest::setProxy_trust_transport_info(bool proxy_trust_transport_info)
{
proxy_trust_transport_info_ = proxy_trust_transport_info;
setParameter("Proxy_trust_transport_info", std::to_string(proxy_trust_transport_info));
}
bool DescribeDomainAverageResponseTimeRequest::getAk_mfa_present()const
{
return ak_mfa_present_;
}
void DescribeDomainAverageResponseTimeRequest::setAk_mfa_present(bool ak_mfa_present)
{
ak_mfa_present_ = ak_mfa_present;
setParameter("Ak_mfa_present", std::to_string(ak_mfa_present));
}
bool DescribeDomainAverageResponseTimeRequest::getSecurity_transport()const
{
return security_transport_;
}
void DescribeDomainAverageResponseTimeRequest::setSecurity_transport(bool security_transport)
{
security_transport_ = security_transport;
setParameter("Security_transport", std::to_string(security_transport));
}
std::string DescribeDomainAverageResponseTimeRequest::getRequestId()const
{
return requestId_;
}
void DescribeDomainAverageResponseTimeRequest::setRequestId(const std::string& requestId)
{
requestId_ = requestId;
setParameter("RequestId", requestId);
}
std::string DescribeDomainAverageResponseTimeRequest::getInterval()const
{
return interval_;
}
void DescribeDomainAverageResponseTimeRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainAverageResponseTimeRequest::getFields()const
{
return fields_;
}
void DescribeDomainAverageResponseTimeRequest::setFields(const std::string& fields)
{
fields_ = fields;
setParameter("Fields", fields);
}

View File

@@ -52,12 +52,20 @@ void DescribeDomainAverageResponseTimeResult::parse(const std::string &payload)
}
if(!value["DomainName"].isNull())
domainName_ = value["DomainName"].asString();
if(!value["DataInterval"].isNull())
dataInterval_ = value["DataInterval"].asString();
if(!value["StartTime"].isNull())
startTime_ = value["StartTime"].asString();
if(!value["EndTime"].isNull())
endTime_ = value["EndTime"].asString();
if(!value["LocationNameEn"].isNull())
locationNameEn_ = value["LocationNameEn"].asString();
if(!value["IspNameEn"].isNull())
ispNameEn_ = value["IspNameEn"].asString();
if(!value["LocationName"].isNull())
locationName_ = value["LocationName"].asString();
if(!value["IspName"].isNull())
ispName_ = value["IspName"].asString();
if(!value["DataInterval"].isNull())
dataInterval_ = value["DataInterval"].asString();
}
@@ -66,6 +74,16 @@ std::vector<DescribeDomainAverageResponseTimeResult::DataModule> DescribeDomainA
return avgRTPerInterval_;
}
std::string DescribeDomainAverageResponseTimeResult::getIspNameEn()const
{
return ispNameEn_;
}
std::string DescribeDomainAverageResponseTimeResult::getIspName()const
{
return ispName_;
}
std::string DescribeDomainAverageResponseTimeResult::getEndTime()const
{
return endTime_;
@@ -76,9 +94,9 @@ std::string DescribeDomainAverageResponseTimeResult::getDomainName()const
return domainName_;
}
std::string DescribeDomainAverageResponseTimeResult::getDataInterval()const
std::string DescribeDomainAverageResponseTimeResult::getLocationNameEn()const
{
return dataInterval_;
return locationNameEn_;
}
std::string DescribeDomainAverageResponseTimeResult::getStartTime()const
@@ -86,3 +104,13 @@ std::string DescribeDomainAverageResponseTimeResult::getStartTime()const
return startTime_;
}
std::string DescribeDomainAverageResponseTimeResult::getDataInterval()const
{
return dataInterval_;
}
std::string DescribeDomainAverageResponseTimeResult::getLocationName()const
{
return locationName_;
}

View File

@@ -25,6 +25,83 @@ DescribeDomainHitRateDataRequest::DescribeDomainHitRateDataRequest() :
DescribeDomainHitRateDataRequest::~DescribeDomainHitRateDataRequest()
{}
long DescribeDomainHitRateDataRequest::getCallerParentId()const
{
return callerParentId_;
}
void DescribeDomainHitRateDataRequest::setCallerParentId(long callerParentId)
{
callerParentId_ = callerParentId;
setParameter("CallerParentId", std::to_string(callerParentId));
}
bool DescribeDomainHitRateDataRequest::getProxy_original_security_transport()const
{
return proxy_original_security_transport_;
}
void DescribeDomainHitRateDataRequest::setProxy_original_security_transport(bool proxy_original_security_transport)
{
proxy_original_security_transport_ = proxy_original_security_transport;
setParameter("Proxy_original_security_transport", std::to_string(proxy_original_security_transport));
}
std::string DescribeDomainHitRateDataRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainHitRateDataRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeDomainHitRateDataRequest::getProxy_original_source_ip()const
{
return proxy_original_source_ip_;
}
void DescribeDomainHitRateDataRequest::setProxy_original_source_ip(const std::string& proxy_original_source_ip)
{
proxy_original_source_ip_ = proxy_original_source_ip;
setParameter("Proxy_original_source_ip", proxy_original_source_ip);
}
std::string DescribeDomainHitRateDataRequest::getOwnerIdLoginEmail()const
{
return ownerIdLoginEmail_;
}
void DescribeDomainHitRateDataRequest::setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail)
{
ownerIdLoginEmail_ = ownerIdLoginEmail;
setParameter("OwnerIdLoginEmail", ownerIdLoginEmail);
}
std::string DescribeDomainHitRateDataRequest::getCallerType()const
{
return callerType_;
}
void DescribeDomainHitRateDataRequest::setCallerType(const std::string& callerType)
{
callerType_ = callerType;
setParameter("CallerType", callerType);
}
std::string DescribeDomainHitRateDataRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeDomainHitRateDataRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeDomainHitRateDataRequest::getSecurityToken()const
{
return securityToken_;
@@ -36,15 +113,81 @@ void DescribeDomainHitRateDataRequest::setSecurityToken(const std::string& secur
setParameter("SecurityToken", securityToken);
}
std::string DescribeDomainHitRateDataRequest::getTimeMerge()const
std::string DescribeDomainHitRateDataRequest::getRequestContent()const
{
return timeMerge_;
return requestContent_;
}
void DescribeDomainHitRateDataRequest::setTimeMerge(const std::string& timeMerge)
void DescribeDomainHitRateDataRequest::setRequestContent(const std::string& requestContent)
{
timeMerge_ = timeMerge;
setParameter("TimeMerge", timeMerge);
requestContent_ = requestContent;
setParameter("RequestContent", requestContent);
}
std::string DescribeDomainHitRateDataRequest::getCallerBidEmail()const
{
return callerBidEmail_;
}
void DescribeDomainHitRateDataRequest::setCallerBidEmail(const std::string& callerBidEmail)
{
callerBidEmail_ = callerBidEmail;
setParameter("CallerBidEmail", callerBidEmail);
}
std::string DescribeDomainHitRateDataRequest::getCallerUidEmail()const
{
return callerUidEmail_;
}
void DescribeDomainHitRateDataRequest::setCallerUidEmail(const std::string& callerUidEmail)
{
callerUidEmail_ = callerUidEmail;
setParameter("CallerUidEmail", callerUidEmail);
}
long DescribeDomainHitRateDataRequest::getCallerUid()const
{
return callerUid_;
}
void DescribeDomainHitRateDataRequest::setCallerUid(long callerUid)
{
callerUid_ = callerUid;
setParameter("CallerUid", std::to_string(callerUid));
}
std::string DescribeDomainHitRateDataRequest::getApp_ip()const
{
return app_ip_;
}
void DescribeDomainHitRateDataRequest::setApp_ip(const std::string& app_ip)
{
app_ip_ = app_ip;
setParameter("App_ip", app_ip);
}
std::string DescribeDomainHitRateDataRequest::getPopProduct()const
{
return popProduct_;
}
void DescribeDomainHitRateDataRequest::setPopProduct(const std::string& popProduct)
{
popProduct_ = popProduct;
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainHitRateDataRequest::getOutString()const
{
return outString_;
}
void DescribeDomainHitRateDataRequest::setOutString(const std::string& outString)
{
outString_ = outString;
setParameter("OutString", outString);
}
std::string DescribeDomainHitRateDataRequest::getDomainName()const
@@ -69,48 +212,15 @@ void DescribeDomainHitRateDataRequest::setEndTime(const std::string& endTime)
setParameter("EndTime", endTime);
}
std::string DescribeDomainHitRateDataRequest::getLocationNameEn()const
std::string DescribeDomainHitRateDataRequest::getCallerBid()const
{
return locationNameEn_;
return callerBid_;
}
void DescribeDomainHitRateDataRequest::setLocationNameEn(const std::string& locationNameEn)
void DescribeDomainHitRateDataRequest::setCallerBid(const std::string& callerBid)
{
locationNameEn_ = locationNameEn;
setParameter("LocationNameEn", locationNameEn);
}
std::string DescribeDomainHitRateDataRequest::getInterval()const
{
return interval_;
}
void DescribeDomainHitRateDataRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainHitRateDataRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainHitRateDataRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeDomainHitRateDataRequest::getIspNameEn()const
{
return ispNameEn_;
}
void DescribeDomainHitRateDataRequest::setIspNameEn(const std::string& ispNameEn)
{
ispNameEn_ = ispNameEn;
setParameter("IspNameEn", ispNameEn);
callerBid_ = callerBid;
setParameter("CallerBid", callerBid);
}
long DescribeDomainHitRateDataRequest::getOwnerId()const
@@ -124,14 +234,80 @@ void DescribeDomainHitRateDataRequest::setOwnerId(long ownerId)
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeDomainHitRateDataRequest::getAccessKeyId()const
std::string DescribeDomainHitRateDataRequest::getVersion()const
{
return accessKeyId_;
return version_;
}
void DescribeDomainHitRateDataRequest::setAccessKeyId(const std::string& accessKeyId)
void DescribeDomainHitRateDataRequest::setVersion(const std::string& version)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
version_ = version;
setParameter("Version", version);
}
bool DescribeDomainHitRateDataRequest::getProxy_trust_transport_info()const
{
return proxy_trust_transport_info_;
}
void DescribeDomainHitRateDataRequest::setProxy_trust_transport_info(bool proxy_trust_transport_info)
{
proxy_trust_transport_info_ = proxy_trust_transport_info;
setParameter("Proxy_trust_transport_info", std::to_string(proxy_trust_transport_info));
}
bool DescribeDomainHitRateDataRequest::getAk_mfa_present()const
{
return ak_mfa_present_;
}
void DescribeDomainHitRateDataRequest::setAk_mfa_present(bool ak_mfa_present)
{
ak_mfa_present_ = ak_mfa_present;
setParameter("Ak_mfa_present", std::to_string(ak_mfa_present));
}
bool DescribeDomainHitRateDataRequest::getSecurity_transport()const
{
return security_transport_;
}
void DescribeDomainHitRateDataRequest::setSecurity_transport(bool security_transport)
{
security_transport_ = security_transport;
setParameter("Security_transport", std::to_string(security_transport));
}
std::string DescribeDomainHitRateDataRequest::getRequestId()const
{
return requestId_;
}
void DescribeDomainHitRateDataRequest::setRequestId(const std::string& requestId)
{
requestId_ = requestId;
setParameter("RequestId", requestId);
}
std::string DescribeDomainHitRateDataRequest::getInterval()const
{
return interval_;
}
void DescribeDomainHitRateDataRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainHitRateDataRequest::getFields()const
{
return fields_;
}
void DescribeDomainHitRateDataRequest::setFields(const std::string& fields)
{
fields_ = fields;
setParameter("Fields", fields);
}

View File

@@ -52,12 +52,12 @@ void DescribeDomainHitRateDataResult::parse(const std::string &payload)
}
if(!value["DomainName"].isNull())
domainName_ = value["DomainName"].asString();
if(!value["DataInterval"].isNull())
dataInterval_ = value["DataInterval"].asString();
if(!value["StartTime"].isNull())
startTime_ = value["StartTime"].asString();
if(!value["EndTime"].isNull())
endTime_ = value["EndTime"].asString();
if(!value["DataInterval"].isNull())
dataInterval_ = value["DataInterval"].asString();
}
@@ -76,13 +76,13 @@ std::string DescribeDomainHitRateDataResult::getDomainName()const
return domainName_;
}
std::string DescribeDomainHitRateDataResult::getDataInterval()const
{
return dataInterval_;
}
std::string DescribeDomainHitRateDataResult::getStartTime()const
{
return startTime_;
}
std::string DescribeDomainHitRateDataResult::getDataInterval()const
{
return dataInterval_;
}

View File

@@ -25,6 +25,105 @@ DescribeDomainHttpCodeDataRequest::DescribeDomainHttpCodeDataRequest() :
DescribeDomainHttpCodeDataRequest::~DescribeDomainHttpCodeDataRequest()
{}
long DescribeDomainHttpCodeDataRequest::getCallerParentId()const
{
return callerParentId_;
}
void DescribeDomainHttpCodeDataRequest::setCallerParentId(long callerParentId)
{
callerParentId_ = callerParentId;
setParameter("CallerParentId", std::to_string(callerParentId));
}
bool DescribeDomainHttpCodeDataRequest::getProxy_original_security_transport()const
{
return proxy_original_security_transport_;
}
void DescribeDomainHttpCodeDataRequest::setProxy_original_security_transport(bool proxy_original_security_transport)
{
proxy_original_security_transport_ = proxy_original_security_transport;
setParameter("Proxy_original_security_transport", std::to_string(proxy_original_security_transport));
}
std::string DescribeDomainHttpCodeDataRequest::getLocationNameEn()const
{
return locationNameEn_;
}
void DescribeDomainHttpCodeDataRequest::setLocationNameEn(const std::string& locationNameEn)
{
locationNameEn_ = locationNameEn;
setParameter("LocationNameEn", locationNameEn);
}
std::string DescribeDomainHttpCodeDataRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainHttpCodeDataRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeDomainHttpCodeDataRequest::getIspNameEn()const
{
return ispNameEn_;
}
void DescribeDomainHttpCodeDataRequest::setIspNameEn(const std::string& ispNameEn)
{
ispNameEn_ = ispNameEn;
setParameter("IspNameEn", ispNameEn);
}
std::string DescribeDomainHttpCodeDataRequest::getProxy_original_source_ip()const
{
return proxy_original_source_ip_;
}
void DescribeDomainHttpCodeDataRequest::setProxy_original_source_ip(const std::string& proxy_original_source_ip)
{
proxy_original_source_ip_ = proxy_original_source_ip;
setParameter("Proxy_original_source_ip", proxy_original_source_ip);
}
std::string DescribeDomainHttpCodeDataRequest::getOwnerIdLoginEmail()const
{
return ownerIdLoginEmail_;
}
void DescribeDomainHttpCodeDataRequest::setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail)
{
ownerIdLoginEmail_ = ownerIdLoginEmail;
setParameter("OwnerIdLoginEmail", ownerIdLoginEmail);
}
std::string DescribeDomainHttpCodeDataRequest::getCallerType()const
{
return callerType_;
}
void DescribeDomainHttpCodeDataRequest::setCallerType(const std::string& callerType)
{
callerType_ = callerType;
setParameter("CallerType", callerType);
}
std::string DescribeDomainHttpCodeDataRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeDomainHttpCodeDataRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeDomainHttpCodeDataRequest::getSecurityToken()const
{
return securityToken_;
@@ -36,6 +135,83 @@ void DescribeDomainHttpCodeDataRequest::setSecurityToken(const std::string& secu
setParameter("SecurityToken", securityToken);
}
std::string DescribeDomainHttpCodeDataRequest::getRequestContent()const
{
return requestContent_;
}
void DescribeDomainHttpCodeDataRequest::setRequestContent(const std::string& requestContent)
{
requestContent_ = requestContent;
setParameter("RequestContent", requestContent);
}
std::string DescribeDomainHttpCodeDataRequest::getCallerBidEmail()const
{
return callerBidEmail_;
}
void DescribeDomainHttpCodeDataRequest::setCallerBidEmail(const std::string& callerBidEmail)
{
callerBidEmail_ = callerBidEmail;
setParameter("CallerBidEmail", callerBidEmail);
}
std::string DescribeDomainHttpCodeDataRequest::getCallerUidEmail()const
{
return callerUidEmail_;
}
void DescribeDomainHttpCodeDataRequest::setCallerUidEmail(const std::string& callerUidEmail)
{
callerUidEmail_ = callerUidEmail;
setParameter("CallerUidEmail", callerUidEmail);
}
long DescribeDomainHttpCodeDataRequest::getCallerUid()const
{
return callerUid_;
}
void DescribeDomainHttpCodeDataRequest::setCallerUid(long callerUid)
{
callerUid_ = callerUid;
setParameter("CallerUid", std::to_string(callerUid));
}
std::string DescribeDomainHttpCodeDataRequest::getApp_ip()const
{
return app_ip_;
}
void DescribeDomainHttpCodeDataRequest::setApp_ip(const std::string& app_ip)
{
app_ip_ = app_ip;
setParameter("App_ip", app_ip);
}
std::string DescribeDomainHttpCodeDataRequest::getPopProduct()const
{
return popProduct_;
}
void DescribeDomainHttpCodeDataRequest::setPopProduct(const std::string& popProduct)
{
popProduct_ = popProduct;
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainHttpCodeDataRequest::getOutString()const
{
return outString_;
}
void DescribeDomainHttpCodeDataRequest::setOutString(const std::string& outString)
{
outString_ = outString;
setParameter("OutString", outString);
}
std::string DescribeDomainHttpCodeDataRequest::getTimeMerge()const
{
return timeMerge_;
@@ -69,48 +245,15 @@ void DescribeDomainHttpCodeDataRequest::setEndTime(const std::string& endTime)
setParameter("EndTime", endTime);
}
std::string DescribeDomainHttpCodeDataRequest::getLocationNameEn()const
std::string DescribeDomainHttpCodeDataRequest::getCallerBid()const
{
return locationNameEn_;
return callerBid_;
}
void DescribeDomainHttpCodeDataRequest::setLocationNameEn(const std::string& locationNameEn)
void DescribeDomainHttpCodeDataRequest::setCallerBid(const std::string& callerBid)
{
locationNameEn_ = locationNameEn;
setParameter("LocationNameEn", locationNameEn);
}
std::string DescribeDomainHttpCodeDataRequest::getInterval()const
{
return interval_;
}
void DescribeDomainHttpCodeDataRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainHttpCodeDataRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainHttpCodeDataRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeDomainHttpCodeDataRequest::getIspNameEn()const
{
return ispNameEn_;
}
void DescribeDomainHttpCodeDataRequest::setIspNameEn(const std::string& ispNameEn)
{
ispNameEn_ = ispNameEn;
setParameter("IspNameEn", ispNameEn);
callerBid_ = callerBid;
setParameter("CallerBid", callerBid);
}
long DescribeDomainHttpCodeDataRequest::getOwnerId()const
@@ -124,14 +267,80 @@ void DescribeDomainHttpCodeDataRequest::setOwnerId(long ownerId)
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeDomainHttpCodeDataRequest::getAccessKeyId()const
std::string DescribeDomainHttpCodeDataRequest::getVersion()const
{
return accessKeyId_;
return version_;
}
void DescribeDomainHttpCodeDataRequest::setAccessKeyId(const std::string& accessKeyId)
void DescribeDomainHttpCodeDataRequest::setVersion(const std::string& version)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
version_ = version;
setParameter("Version", version);
}
bool DescribeDomainHttpCodeDataRequest::getProxy_trust_transport_info()const
{
return proxy_trust_transport_info_;
}
void DescribeDomainHttpCodeDataRequest::setProxy_trust_transport_info(bool proxy_trust_transport_info)
{
proxy_trust_transport_info_ = proxy_trust_transport_info;
setParameter("Proxy_trust_transport_info", std::to_string(proxy_trust_transport_info));
}
bool DescribeDomainHttpCodeDataRequest::getAk_mfa_present()const
{
return ak_mfa_present_;
}
void DescribeDomainHttpCodeDataRequest::setAk_mfa_present(bool ak_mfa_present)
{
ak_mfa_present_ = ak_mfa_present;
setParameter("Ak_mfa_present", std::to_string(ak_mfa_present));
}
bool DescribeDomainHttpCodeDataRequest::getSecurity_transport()const
{
return security_transport_;
}
void DescribeDomainHttpCodeDataRequest::setSecurity_transport(bool security_transport)
{
security_transport_ = security_transport;
setParameter("Security_transport", std::to_string(security_transport));
}
std::string DescribeDomainHttpCodeDataRequest::getRequestId()const
{
return requestId_;
}
void DescribeDomainHttpCodeDataRequest::setRequestId(const std::string& requestId)
{
requestId_ = requestId;
setParameter("RequestId", requestId);
}
std::string DescribeDomainHttpCodeDataRequest::getInterval()const
{
return interval_;
}
void DescribeDomainHttpCodeDataRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainHttpCodeDataRequest::getFields()const
{
return fields_;
}
void DescribeDomainHttpCodeDataRequest::setFields(const std::string& fields)
{
fields_ = fields;
setParameter("Fields", fields);
}

View File

@@ -62,12 +62,12 @@ void DescribeDomainHttpCodeDataResult::parse(const std::string &payload)
}
if(!value["DomainName"].isNull())
domainName_ = value["DomainName"].asString();
if(!value["DataInterval"].isNull())
dataInterval_ = value["DataInterval"].asString();
if(!value["StartTime"].isNull())
startTime_ = value["StartTime"].asString();
if(!value["EndTime"].isNull())
endTime_ = value["EndTime"].asString();
if(!value["DataInterval"].isNull())
dataInterval_ = value["DataInterval"].asString();
}
@@ -81,16 +81,16 @@ std::string DescribeDomainHttpCodeDataResult::getDomainName()const
return domainName_;
}
std::string DescribeDomainHttpCodeDataResult::getDataInterval()const
{
return dataInterval_;
}
std::string DescribeDomainHttpCodeDataResult::getStartTime()const
{
return startTime_;
}
std::string DescribeDomainHttpCodeDataResult::getDataInterval()const
{
return dataInterval_;
}
std::vector<DescribeDomainHttpCodeDataResult::UsageData> DescribeDomainHttpCodeDataResult::getHttpCodeData()const
{
return httpCodeData_;

View File

@@ -25,6 +25,83 @@ DescribeDomainISPDataRequest::DescribeDomainISPDataRequest() :
DescribeDomainISPDataRequest::~DescribeDomainISPDataRequest()
{}
long DescribeDomainISPDataRequest::getCallerParentId()const
{
return callerParentId_;
}
void DescribeDomainISPDataRequest::setCallerParentId(long callerParentId)
{
callerParentId_ = callerParentId;
setParameter("CallerParentId", std::to_string(callerParentId));
}
bool DescribeDomainISPDataRequest::getProxy_original_security_transport()const
{
return proxy_original_security_transport_;
}
void DescribeDomainISPDataRequest::setProxy_original_security_transport(bool proxy_original_security_transport)
{
proxy_original_security_transport_ = proxy_original_security_transport;
setParameter("Proxy_original_security_transport", std::to_string(proxy_original_security_transport));
}
std::string DescribeDomainISPDataRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainISPDataRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeDomainISPDataRequest::getProxy_original_source_ip()const
{
return proxy_original_source_ip_;
}
void DescribeDomainISPDataRequest::setProxy_original_source_ip(const std::string& proxy_original_source_ip)
{
proxy_original_source_ip_ = proxy_original_source_ip;
setParameter("Proxy_original_source_ip", proxy_original_source_ip);
}
std::string DescribeDomainISPDataRequest::getOwnerIdLoginEmail()const
{
return ownerIdLoginEmail_;
}
void DescribeDomainISPDataRequest::setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail)
{
ownerIdLoginEmail_ = ownerIdLoginEmail;
setParameter("OwnerIdLoginEmail", ownerIdLoginEmail);
}
std::string DescribeDomainISPDataRequest::getCallerType()const
{
return callerType_;
}
void DescribeDomainISPDataRequest::setCallerType(const std::string& callerType)
{
callerType_ = callerType;
setParameter("CallerType", callerType);
}
std::string DescribeDomainISPDataRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeDomainISPDataRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeDomainISPDataRequest::getSecurityToken()const
{
return securityToken_;
@@ -36,6 +113,94 @@ void DescribeDomainISPDataRequest::setSecurityToken(const std::string& securityT
setParameter("SecurityToken", securityToken);
}
std::string DescribeDomainISPDataRequest::getRequestContent()const
{
return requestContent_;
}
void DescribeDomainISPDataRequest::setRequestContent(const std::string& requestContent)
{
requestContent_ = requestContent;
setParameter("RequestContent", requestContent);
}
std::string DescribeDomainISPDataRequest::getCallerBidEmail()const
{
return callerBidEmail_;
}
void DescribeDomainISPDataRequest::setCallerBidEmail(const std::string& callerBidEmail)
{
callerBidEmail_ = callerBidEmail;
setParameter("CallerBidEmail", callerBidEmail);
}
std::string DescribeDomainISPDataRequest::getCallerUidEmail()const
{
return callerUidEmail_;
}
void DescribeDomainISPDataRequest::setCallerUidEmail(const std::string& callerUidEmail)
{
callerUidEmail_ = callerUidEmail;
setParameter("CallerUidEmail", callerUidEmail);
}
long DescribeDomainISPDataRequest::getCallerUid()const
{
return callerUid_;
}
void DescribeDomainISPDataRequest::setCallerUid(long callerUid)
{
callerUid_ = callerUid;
setParameter("CallerUid", std::to_string(callerUid));
}
std::string DescribeDomainISPDataRequest::getApp_ip()const
{
return app_ip_;
}
void DescribeDomainISPDataRequest::setApp_ip(const std::string& app_ip)
{
app_ip_ = app_ip;
setParameter("App_ip", app_ip);
}
std::string DescribeDomainISPDataRequest::getPopProduct()const
{
return popProduct_;
}
void DescribeDomainISPDataRequest::setPopProduct(const std::string& popProduct)
{
popProduct_ = popProduct;
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainISPDataRequest::getProduct()const
{
return product_;
}
void DescribeDomainISPDataRequest::setProduct(const std::string& product)
{
product_ = product;
setParameter("Product", product);
}
std::string DescribeDomainISPDataRequest::getOutString()const
{
return outString_;
}
void DescribeDomainISPDataRequest::setOutString(const std::string& outString)
{
outString_ = outString;
setParameter("OutString", outString);
}
std::string DescribeDomainISPDataRequest::getDomainName()const
{
return domainName_;
@@ -58,15 +223,15 @@ void DescribeDomainISPDataRequest::setEndTime(const std::string& endTime)
setParameter("EndTime", endTime);
}
std::string DescribeDomainISPDataRequest::getStartTime()const
std::string DescribeDomainISPDataRequest::getCallerBid()const
{
return startTime_;
return callerBid_;
}
void DescribeDomainISPDataRequest::setStartTime(const std::string& startTime)
void DescribeDomainISPDataRequest::setCallerBid(const std::string& callerBid)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
callerBid_ = callerBid;
setParameter("CallerBid", callerBid);
}
long DescribeDomainISPDataRequest::getOwnerId()const
@@ -80,14 +245,58 @@ void DescribeDomainISPDataRequest::setOwnerId(long ownerId)
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeDomainISPDataRequest::getAccessKeyId()const
std::string DescribeDomainISPDataRequest::getVersion()const
{
return accessKeyId_;
return version_;
}
void DescribeDomainISPDataRequest::setAccessKeyId(const std::string& accessKeyId)
void DescribeDomainISPDataRequest::setVersion(const std::string& version)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
version_ = version;
setParameter("Version", version);
}
bool DescribeDomainISPDataRequest::getProxy_trust_transport_info()const
{
return proxy_trust_transport_info_;
}
void DescribeDomainISPDataRequest::setProxy_trust_transport_info(bool proxy_trust_transport_info)
{
proxy_trust_transport_info_ = proxy_trust_transport_info;
setParameter("Proxy_trust_transport_info", std::to_string(proxy_trust_transport_info));
}
bool DescribeDomainISPDataRequest::getAk_mfa_present()const
{
return ak_mfa_present_;
}
void DescribeDomainISPDataRequest::setAk_mfa_present(bool ak_mfa_present)
{
ak_mfa_present_ = ak_mfa_present;
setParameter("Ak_mfa_present", std::to_string(ak_mfa_present));
}
bool DescribeDomainISPDataRequest::getSecurity_transport()const
{
return security_transport_;
}
void DescribeDomainISPDataRequest::setSecurity_transport(bool security_transport)
{
security_transport_ = security_transport;
setParameter("Security_transport", std::to_string(security_transport));
}
std::string DescribeDomainISPDataRequest::getRequestId()const
{
return requestId_;
}
void DescribeDomainISPDataRequest::setRequestId(const std::string& requestId)
{
requestId_ = requestId;
setParameter("RequestId", requestId);
}

View File

@@ -56,16 +56,16 @@ void DescribeDomainISPDataResult::parse(const std::string &payload)
valueObject.avgResponseTime = value["AvgResponseTime"].asString();
if(!value["Bps"].isNull())
valueObject.bps = value["Bps"].asString();
if(!value["ByteHitRate"].isNull())
valueObject.byteHitRate = value["ByteHitRate"].asString();
if(!value["Qps"].isNull())
valueObject.qps = value["Qps"].asString();
if(!value["ReqErrRate"].isNull())
valueObject.reqErrRate = value["ReqErrRate"].asString();
if(!value["ReqHitRate"].isNull())
valueObject.reqHitRate = value["ReqHitRate"].asString();
if(!value["AvgResponseRate"].isNull())
valueObject.avgResponseRate = value["AvgResponseRate"].asString();
if(!value["ByteHitRate"].isNull())
valueObject.byteHitRate = value["ByteHitRate"].asString();
if(!value["ReqHitRate"].isNull())
valueObject.reqHitRate = value["ReqHitRate"].asString();
if(!value["ReqErrRate"].isNull())
valueObject.reqErrRate = value["ReqErrRate"].asString();
if(!value["TotalBytes"].isNull())
valueObject.totalBytes = value["TotalBytes"].asString();
if(!value["BytesProportion"].isNull())

View File

@@ -201,17 +201,6 @@ void DescribeDomainRealTimeBpsDataRequest::setPopProduct(const std::string& popP
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainRealTimeBpsDataRequest::getProduct()const
{
return product_;
}
void DescribeDomainRealTimeBpsDataRequest::setProduct(const std::string& product)
{
product_ = product;
setParameter("Product", product);
}
std::string DescribeDomainRealTimeBpsDataRequest::getDomainName()const
{
return domainName_;
@@ -311,3 +300,25 @@ void DescribeDomainRealTimeBpsDataRequest::setRequestId(const std::string& reque
setParameter("RequestId", requestId);
}
std::string DescribeDomainRealTimeBpsDataRequest::getInterval()const
{
return interval_;
}
void DescribeDomainRealTimeBpsDataRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainRealTimeBpsDataRequest::getFields()const
{
return fields_;
}
void DescribeDomainRealTimeBpsDataRequest::setFields(const std::string& fields)
{
fields_ = fields;
setParameter("Fields", fields);
}

View File

@@ -179,17 +179,6 @@ void DescribeDomainRealTimeByteHitRateDataRequest::setPopProduct(const std::stri
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainRealTimeByteHitRateDataRequest::getProduct()const
{
return product_;
}
void DescribeDomainRealTimeByteHitRateDataRequest::setProduct(const std::string& product)
{
product_ = product;
setParameter("Product", product);
}
std::string DescribeDomainRealTimeByteHitRateDataRequest::getDomainName()const
{
return domainName_;
@@ -289,3 +278,25 @@ void DescribeDomainRealTimeByteHitRateDataRequest::setRequestId(const std::strin
setParameter("RequestId", requestId);
}
std::string DescribeDomainRealTimeByteHitRateDataRequest::getInterval()const
{
return interval_;
}
void DescribeDomainRealTimeByteHitRateDataRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainRealTimeByteHitRateDataRequest::getFields()const
{
return fields_;
}
void DescribeDomainRealTimeByteHitRateDataRequest::setFields(const std::string& fields)
{
fields_ = fields;
setParameter("Fields", fields);
}

View File

@@ -201,17 +201,6 @@ void DescribeDomainRealTimeQpsDataRequest::setPopProduct(const std::string& popP
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainRealTimeQpsDataRequest::getProduct()const
{
return product_;
}
void DescribeDomainRealTimeQpsDataRequest::setProduct(const std::string& product)
{
product_ = product;
setParameter("Product", product);
}
std::string DescribeDomainRealTimeQpsDataRequest::getDomainName()const
{
return domainName_;
@@ -311,3 +300,25 @@ void DescribeDomainRealTimeQpsDataRequest::setRequestId(const std::string& reque
setParameter("RequestId", requestId);
}
std::string DescribeDomainRealTimeQpsDataRequest::getInterval()const
{
return interval_;
}
void DescribeDomainRealTimeQpsDataRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainRealTimeQpsDataRequest::getFields()const
{
return fields_;
}
void DescribeDomainRealTimeQpsDataRequest::setFields(const std::string& fields)
{
fields_ = fields;
setParameter("Fields", fields);
}

View File

@@ -179,17 +179,6 @@ void DescribeDomainRealTimeReqHitRateDataRequest::setPopProduct(const std::strin
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainRealTimeReqHitRateDataRequest::getProduct()const
{
return product_;
}
void DescribeDomainRealTimeReqHitRateDataRequest::setProduct(const std::string& product)
{
product_ = product;
setParameter("Product", product);
}
std::string DescribeDomainRealTimeReqHitRateDataRequest::getDomainName()const
{
return domainName_;
@@ -289,3 +278,25 @@ void DescribeDomainRealTimeReqHitRateDataRequest::setRequestId(const std::string
setParameter("RequestId", requestId);
}
std::string DescribeDomainRealTimeReqHitRateDataRequest::getInterval()const
{
return interval_;
}
void DescribeDomainRealTimeReqHitRateDataRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainRealTimeReqHitRateDataRequest::getFields()const
{
return fields_;
}
void DescribeDomainRealTimeReqHitRateDataRequest::setFields(const std::string& fields)
{
fields_ = fields;
setParameter("Fields", fields);
}

View File

@@ -25,6 +25,83 @@ DescribeDomainRegionDataRequest::DescribeDomainRegionDataRequest() :
DescribeDomainRegionDataRequest::~DescribeDomainRegionDataRequest()
{}
long DescribeDomainRegionDataRequest::getCallerParentId()const
{
return callerParentId_;
}
void DescribeDomainRegionDataRequest::setCallerParentId(long callerParentId)
{
callerParentId_ = callerParentId;
setParameter("CallerParentId", std::to_string(callerParentId));
}
bool DescribeDomainRegionDataRequest::getProxy_original_security_transport()const
{
return proxy_original_security_transport_;
}
void DescribeDomainRegionDataRequest::setProxy_original_security_transport(bool proxy_original_security_transport)
{
proxy_original_security_transport_ = proxy_original_security_transport;
setParameter("Proxy_original_security_transport", std::to_string(proxy_original_security_transport));
}
std::string DescribeDomainRegionDataRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainRegionDataRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeDomainRegionDataRequest::getProxy_original_source_ip()const
{
return proxy_original_source_ip_;
}
void DescribeDomainRegionDataRequest::setProxy_original_source_ip(const std::string& proxy_original_source_ip)
{
proxy_original_source_ip_ = proxy_original_source_ip;
setParameter("Proxy_original_source_ip", proxy_original_source_ip);
}
std::string DescribeDomainRegionDataRequest::getOwnerIdLoginEmail()const
{
return ownerIdLoginEmail_;
}
void DescribeDomainRegionDataRequest::setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail)
{
ownerIdLoginEmail_ = ownerIdLoginEmail;
setParameter("OwnerIdLoginEmail", ownerIdLoginEmail);
}
std::string DescribeDomainRegionDataRequest::getCallerType()const
{
return callerType_;
}
void DescribeDomainRegionDataRequest::setCallerType(const std::string& callerType)
{
callerType_ = callerType;
setParameter("CallerType", callerType);
}
std::string DescribeDomainRegionDataRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeDomainRegionDataRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeDomainRegionDataRequest::getSecurityToken()const
{
return securityToken_;
@@ -36,6 +113,94 @@ void DescribeDomainRegionDataRequest::setSecurityToken(const std::string& securi
setParameter("SecurityToken", securityToken);
}
std::string DescribeDomainRegionDataRequest::getRequestContent()const
{
return requestContent_;
}
void DescribeDomainRegionDataRequest::setRequestContent(const std::string& requestContent)
{
requestContent_ = requestContent;
setParameter("RequestContent", requestContent);
}
std::string DescribeDomainRegionDataRequest::getCallerBidEmail()const
{
return callerBidEmail_;
}
void DescribeDomainRegionDataRequest::setCallerBidEmail(const std::string& callerBidEmail)
{
callerBidEmail_ = callerBidEmail;
setParameter("CallerBidEmail", callerBidEmail);
}
std::string DescribeDomainRegionDataRequest::getCallerUidEmail()const
{
return callerUidEmail_;
}
void DescribeDomainRegionDataRequest::setCallerUidEmail(const std::string& callerUidEmail)
{
callerUidEmail_ = callerUidEmail;
setParameter("CallerUidEmail", callerUidEmail);
}
long DescribeDomainRegionDataRequest::getCallerUid()const
{
return callerUid_;
}
void DescribeDomainRegionDataRequest::setCallerUid(long callerUid)
{
callerUid_ = callerUid;
setParameter("CallerUid", std::to_string(callerUid));
}
std::string DescribeDomainRegionDataRequest::getApp_ip()const
{
return app_ip_;
}
void DescribeDomainRegionDataRequest::setApp_ip(const std::string& app_ip)
{
app_ip_ = app_ip;
setParameter("App_ip", app_ip);
}
std::string DescribeDomainRegionDataRequest::getPopProduct()const
{
return popProduct_;
}
void DescribeDomainRegionDataRequest::setPopProduct(const std::string& popProduct)
{
popProduct_ = popProduct;
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainRegionDataRequest::getProduct()const
{
return product_;
}
void DescribeDomainRegionDataRequest::setProduct(const std::string& product)
{
product_ = product;
setParameter("Product", product);
}
std::string DescribeDomainRegionDataRequest::getOutString()const
{
return outString_;
}
void DescribeDomainRegionDataRequest::setOutString(const std::string& outString)
{
outString_ = outString;
setParameter("OutString", outString);
}
std::string DescribeDomainRegionDataRequest::getDomainName()const
{
return domainName_;
@@ -58,15 +223,15 @@ void DescribeDomainRegionDataRequest::setEndTime(const std::string& endTime)
setParameter("EndTime", endTime);
}
std::string DescribeDomainRegionDataRequest::getStartTime()const
std::string DescribeDomainRegionDataRequest::getCallerBid()const
{
return startTime_;
return callerBid_;
}
void DescribeDomainRegionDataRequest::setStartTime(const std::string& startTime)
void DescribeDomainRegionDataRequest::setCallerBid(const std::string& callerBid)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
callerBid_ = callerBid;
setParameter("CallerBid", callerBid);
}
long DescribeDomainRegionDataRequest::getOwnerId()const
@@ -80,14 +245,58 @@ void DescribeDomainRegionDataRequest::setOwnerId(long ownerId)
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeDomainRegionDataRequest::getAccessKeyId()const
std::string DescribeDomainRegionDataRequest::getVersion()const
{
return accessKeyId_;
return version_;
}
void DescribeDomainRegionDataRequest::setAccessKeyId(const std::string& accessKeyId)
void DescribeDomainRegionDataRequest::setVersion(const std::string& version)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
version_ = version;
setParameter("Version", version);
}
bool DescribeDomainRegionDataRequest::getProxy_trust_transport_info()const
{
return proxy_trust_transport_info_;
}
void DescribeDomainRegionDataRequest::setProxy_trust_transport_info(bool proxy_trust_transport_info)
{
proxy_trust_transport_info_ = proxy_trust_transport_info;
setParameter("Proxy_trust_transport_info", std::to_string(proxy_trust_transport_info));
}
bool DescribeDomainRegionDataRequest::getAk_mfa_present()const
{
return ak_mfa_present_;
}
void DescribeDomainRegionDataRequest::setAk_mfa_present(bool ak_mfa_present)
{
ak_mfa_present_ = ak_mfa_present;
setParameter("Ak_mfa_present", std::to_string(ak_mfa_present));
}
bool DescribeDomainRegionDataRequest::getSecurity_transport()const
{
return security_transport_;
}
void DescribeDomainRegionDataRequest::setSecurity_transport(bool security_transport)
{
security_transport_ = security_transport;
setParameter("Security_transport", std::to_string(security_transport));
}
std::string DescribeDomainRegionDataRequest::getRequestId()const
{
return requestId_;
}
void DescribeDomainRegionDataRequest::setRequestId(const std::string& requestId)
{
requestId_ = requestId;
setParameter("RequestId", requestId);
}

View File

@@ -56,16 +56,16 @@ void DescribeDomainRegionDataResult::parse(const std::string &payload)
valueObject.avgResponseTime = value["AvgResponseTime"].asString();
if(!value["Bps"].isNull())
valueObject.bps = value["Bps"].asString();
if(!value["ByteHitRate"].isNull())
valueObject.byteHitRate = value["ByteHitRate"].asString();
if(!value["Qps"].isNull())
valueObject.qps = value["Qps"].asString();
if(!value["ReqErrRate"].isNull())
valueObject.reqErrRate = value["ReqErrRate"].asString();
if(!value["ReqHitRate"].isNull())
valueObject.reqHitRate = value["ReqHitRate"].asString();
if(!value["AvgResponseRate"].isNull())
valueObject.avgResponseRate = value["AvgResponseRate"].asString();
if(!value["ByteHitRate"].isNull())
valueObject.byteHitRate = value["ByteHitRate"].asString();
if(!value["ReqHitRate"].isNull())
valueObject.reqHitRate = value["ReqHitRate"].asString();
if(!value["ReqErrRate"].isNull())
valueObject.reqErrRate = value["ReqErrRate"].asString();
if(!value["TotalBytes"].isNull())
valueObject.totalBytes = value["TotalBytes"].asString();
if(!value["BytesProportion"].isNull())

View File

@@ -25,6 +25,83 @@ DescribeDomainReqHitRateDataRequest::DescribeDomainReqHitRateDataRequest() :
DescribeDomainReqHitRateDataRequest::~DescribeDomainReqHitRateDataRequest()
{}
long DescribeDomainReqHitRateDataRequest::getCallerParentId()const
{
return callerParentId_;
}
void DescribeDomainReqHitRateDataRequest::setCallerParentId(long callerParentId)
{
callerParentId_ = callerParentId;
setParameter("CallerParentId", std::to_string(callerParentId));
}
bool DescribeDomainReqHitRateDataRequest::getProxy_original_security_transport()const
{
return proxy_original_security_transport_;
}
void DescribeDomainReqHitRateDataRequest::setProxy_original_security_transport(bool proxy_original_security_transport)
{
proxy_original_security_transport_ = proxy_original_security_transport;
setParameter("Proxy_original_security_transport", std::to_string(proxy_original_security_transport));
}
std::string DescribeDomainReqHitRateDataRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainReqHitRateDataRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeDomainReqHitRateDataRequest::getProxy_original_source_ip()const
{
return proxy_original_source_ip_;
}
void DescribeDomainReqHitRateDataRequest::setProxy_original_source_ip(const std::string& proxy_original_source_ip)
{
proxy_original_source_ip_ = proxy_original_source_ip;
setParameter("Proxy_original_source_ip", proxy_original_source_ip);
}
std::string DescribeDomainReqHitRateDataRequest::getOwnerIdLoginEmail()const
{
return ownerIdLoginEmail_;
}
void DescribeDomainReqHitRateDataRequest::setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail)
{
ownerIdLoginEmail_ = ownerIdLoginEmail;
setParameter("OwnerIdLoginEmail", ownerIdLoginEmail);
}
std::string DescribeDomainReqHitRateDataRequest::getCallerType()const
{
return callerType_;
}
void DescribeDomainReqHitRateDataRequest::setCallerType(const std::string& callerType)
{
callerType_ = callerType;
setParameter("CallerType", callerType);
}
std::string DescribeDomainReqHitRateDataRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeDomainReqHitRateDataRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeDomainReqHitRateDataRequest::getSecurityToken()const
{
return securityToken_;
@@ -36,6 +113,83 @@ void DescribeDomainReqHitRateDataRequest::setSecurityToken(const std::string& se
setParameter("SecurityToken", securityToken);
}
std::string DescribeDomainReqHitRateDataRequest::getRequestContent()const
{
return requestContent_;
}
void DescribeDomainReqHitRateDataRequest::setRequestContent(const std::string& requestContent)
{
requestContent_ = requestContent;
setParameter("RequestContent", requestContent);
}
std::string DescribeDomainReqHitRateDataRequest::getCallerBidEmail()const
{
return callerBidEmail_;
}
void DescribeDomainReqHitRateDataRequest::setCallerBidEmail(const std::string& callerBidEmail)
{
callerBidEmail_ = callerBidEmail;
setParameter("CallerBidEmail", callerBidEmail);
}
std::string DescribeDomainReqHitRateDataRequest::getCallerUidEmail()const
{
return callerUidEmail_;
}
void DescribeDomainReqHitRateDataRequest::setCallerUidEmail(const std::string& callerUidEmail)
{
callerUidEmail_ = callerUidEmail;
setParameter("CallerUidEmail", callerUidEmail);
}
long DescribeDomainReqHitRateDataRequest::getCallerUid()const
{
return callerUid_;
}
void DescribeDomainReqHitRateDataRequest::setCallerUid(long callerUid)
{
callerUid_ = callerUid;
setParameter("CallerUid", std::to_string(callerUid));
}
std::string DescribeDomainReqHitRateDataRequest::getApp_ip()const
{
return app_ip_;
}
void DescribeDomainReqHitRateDataRequest::setApp_ip(const std::string& app_ip)
{
app_ip_ = app_ip;
setParameter("App_ip", app_ip);
}
std::string DescribeDomainReqHitRateDataRequest::getPopProduct()const
{
return popProduct_;
}
void DescribeDomainReqHitRateDataRequest::setPopProduct(const std::string& popProduct)
{
popProduct_ = popProduct;
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainReqHitRateDataRequest::getOutString()const
{
return outString_;
}
void DescribeDomainReqHitRateDataRequest::setOutString(const std::string& outString)
{
outString_ = outString;
setParameter("OutString", outString);
}
std::string DescribeDomainReqHitRateDataRequest::getDomainName()const
{
return domainName_;
@@ -58,26 +212,15 @@ void DescribeDomainReqHitRateDataRequest::setEndTime(const std::string& endTime)
setParameter("EndTime", endTime);
}
std::string DescribeDomainReqHitRateDataRequest::getInterval()const
std::string DescribeDomainReqHitRateDataRequest::getCallerBid()const
{
return interval_;
return callerBid_;
}
void DescribeDomainReqHitRateDataRequest::setInterval(const std::string& interval)
void DescribeDomainReqHitRateDataRequest::setCallerBid(const std::string& callerBid)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainReqHitRateDataRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainReqHitRateDataRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
callerBid_ = callerBid;
setParameter("CallerBid", callerBid);
}
long DescribeDomainReqHitRateDataRequest::getOwnerId()const
@@ -91,14 +234,80 @@ void DescribeDomainReqHitRateDataRequest::setOwnerId(long ownerId)
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeDomainReqHitRateDataRequest::getAccessKeyId()const
std::string DescribeDomainReqHitRateDataRequest::getVersion()const
{
return accessKeyId_;
return version_;
}
void DescribeDomainReqHitRateDataRequest::setAccessKeyId(const std::string& accessKeyId)
void DescribeDomainReqHitRateDataRequest::setVersion(const std::string& version)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
version_ = version;
setParameter("Version", version);
}
bool DescribeDomainReqHitRateDataRequest::getProxy_trust_transport_info()const
{
return proxy_trust_transport_info_;
}
void DescribeDomainReqHitRateDataRequest::setProxy_trust_transport_info(bool proxy_trust_transport_info)
{
proxy_trust_transport_info_ = proxy_trust_transport_info;
setParameter("Proxy_trust_transport_info", std::to_string(proxy_trust_transport_info));
}
bool DescribeDomainReqHitRateDataRequest::getAk_mfa_present()const
{
return ak_mfa_present_;
}
void DescribeDomainReqHitRateDataRequest::setAk_mfa_present(bool ak_mfa_present)
{
ak_mfa_present_ = ak_mfa_present;
setParameter("Ak_mfa_present", std::to_string(ak_mfa_present));
}
bool DescribeDomainReqHitRateDataRequest::getSecurity_transport()const
{
return security_transport_;
}
void DescribeDomainReqHitRateDataRequest::setSecurity_transport(bool security_transport)
{
security_transport_ = security_transport;
setParameter("Security_transport", std::to_string(security_transport));
}
std::string DescribeDomainReqHitRateDataRequest::getRequestId()const
{
return requestId_;
}
void DescribeDomainReqHitRateDataRequest::setRequestId(const std::string& requestId)
{
requestId_ = requestId;
setParameter("RequestId", requestId);
}
std::string DescribeDomainReqHitRateDataRequest::getInterval()const
{
return interval_;
}
void DescribeDomainReqHitRateDataRequest::setInterval(const std::string& interval)
{
interval_ = interval;
setParameter("Interval", interval);
}
std::string DescribeDomainReqHitRateDataRequest::getFields()const
{
return fields_;
}
void DescribeDomainReqHitRateDataRequest::setFields(const std::string& fields)
{
fields_ = fields;
setParameter("Fields", fields);
}

View File

@@ -52,12 +52,12 @@ void DescribeDomainReqHitRateDataResult::parse(const std::string &payload)
}
if(!value["DomainName"].isNull())
domainName_ = value["DomainName"].asString();
if(!value["DataInterval"].isNull())
dataInterval_ = value["DataInterval"].asString();
if(!value["StartTime"].isNull())
startTime_ = value["StartTime"].asString();
if(!value["EndTime"].isNull())
endTime_ = value["EndTime"].asString();
if(!value["DataInterval"].isNull())
dataInterval_ = value["DataInterval"].asString();
}
@@ -76,13 +76,13 @@ std::string DescribeDomainReqHitRateDataResult::getDomainName()const
return domainName_;
}
std::string DescribeDomainReqHitRateDataResult::getDataInterval()const
{
return dataInterval_;
}
std::string DescribeDomainReqHitRateDataResult::getStartTime()const
{
return startTime_;
}
std::string DescribeDomainReqHitRateDataResult::getDataInterval()const
{
return dataInterval_;
}

View File

@@ -25,6 +25,83 @@ DescribeDomainsUsageByDayRequest::DescribeDomainsUsageByDayRequest() :
DescribeDomainsUsageByDayRequest::~DescribeDomainsUsageByDayRequest()
{}
long DescribeDomainsUsageByDayRequest::getCallerParentId()const
{
return callerParentId_;
}
void DescribeDomainsUsageByDayRequest::setCallerParentId(long callerParentId)
{
callerParentId_ = callerParentId;
setParameter("CallerParentId", std::to_string(callerParentId));
}
bool DescribeDomainsUsageByDayRequest::getProxy_original_security_transport()const
{
return proxy_original_security_transport_;
}
void DescribeDomainsUsageByDayRequest::setProxy_original_security_transport(bool proxy_original_security_transport)
{
proxy_original_security_transport_ = proxy_original_security_transport;
setParameter("Proxy_original_security_transport", std::to_string(proxy_original_security_transport));
}
std::string DescribeDomainsUsageByDayRequest::getStartTime()const
{
return startTime_;
}
void DescribeDomainsUsageByDayRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeDomainsUsageByDayRequest::getProxy_original_source_ip()const
{
return proxy_original_source_ip_;
}
void DescribeDomainsUsageByDayRequest::setProxy_original_source_ip(const std::string& proxy_original_source_ip)
{
proxy_original_source_ip_ = proxy_original_source_ip;
setParameter("Proxy_original_source_ip", proxy_original_source_ip);
}
std::string DescribeDomainsUsageByDayRequest::getOwnerIdLoginEmail()const
{
return ownerIdLoginEmail_;
}
void DescribeDomainsUsageByDayRequest::setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail)
{
ownerIdLoginEmail_ = ownerIdLoginEmail;
setParameter("OwnerIdLoginEmail", ownerIdLoginEmail);
}
std::string DescribeDomainsUsageByDayRequest::getCallerType()const
{
return callerType_;
}
void DescribeDomainsUsageByDayRequest::setCallerType(const std::string& callerType)
{
callerType_ = callerType;
setParameter("CallerType", callerType);
}
std::string DescribeDomainsUsageByDayRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeDomainsUsageByDayRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeDomainsUsageByDayRequest::getSecurityToken()const
{
return securityToken_;
@@ -36,6 +113,94 @@ void DescribeDomainsUsageByDayRequest::setSecurityToken(const std::string& secur
setParameter("SecurityToken", securityToken);
}
std::string DescribeDomainsUsageByDayRequest::getRequestContent()const
{
return requestContent_;
}
void DescribeDomainsUsageByDayRequest::setRequestContent(const std::string& requestContent)
{
requestContent_ = requestContent;
setParameter("RequestContent", requestContent);
}
std::string DescribeDomainsUsageByDayRequest::getCallerBidEmail()const
{
return callerBidEmail_;
}
void DescribeDomainsUsageByDayRequest::setCallerBidEmail(const std::string& callerBidEmail)
{
callerBidEmail_ = callerBidEmail;
setParameter("CallerBidEmail", callerBidEmail);
}
std::string DescribeDomainsUsageByDayRequest::getCallerUidEmail()const
{
return callerUidEmail_;
}
void DescribeDomainsUsageByDayRequest::setCallerUidEmail(const std::string& callerUidEmail)
{
callerUidEmail_ = callerUidEmail;
setParameter("CallerUidEmail", callerUidEmail);
}
long DescribeDomainsUsageByDayRequest::getCallerUid()const
{
return callerUid_;
}
void DescribeDomainsUsageByDayRequest::setCallerUid(long callerUid)
{
callerUid_ = callerUid;
setParameter("CallerUid", std::to_string(callerUid));
}
std::string DescribeDomainsUsageByDayRequest::getApp_ip()const
{
return app_ip_;
}
void DescribeDomainsUsageByDayRequest::setApp_ip(const std::string& app_ip)
{
app_ip_ = app_ip;
setParameter("App_ip", app_ip);
}
std::string DescribeDomainsUsageByDayRequest::getPopProduct()const
{
return popProduct_;
}
void DescribeDomainsUsageByDayRequest::setPopProduct(const std::string& popProduct)
{
popProduct_ = popProduct;
setParameter("PopProduct", popProduct);
}
std::string DescribeDomainsUsageByDayRequest::getProduct()const
{
return product_;
}
void DescribeDomainsUsageByDayRequest::setProduct(const std::string& product)
{
product_ = product;
setParameter("Product", product);
}
std::string DescribeDomainsUsageByDayRequest::getOutString()const
{
return outString_;
}
void DescribeDomainsUsageByDayRequest::setOutString(const std::string& outString)
{
outString_ = outString;
setParameter("OutString", outString);
}
std::string DescribeDomainsUsageByDayRequest::getDomainName()const
{
return domainName_;
@@ -58,15 +223,15 @@ void DescribeDomainsUsageByDayRequest::setEndTime(const std::string& endTime)
setParameter("EndTime", endTime);
}
std::string DescribeDomainsUsageByDayRequest::getStartTime()const
std::string DescribeDomainsUsageByDayRequest::getCallerBid()const
{
return startTime_;
return callerBid_;
}
void DescribeDomainsUsageByDayRequest::setStartTime(const std::string& startTime)
void DescribeDomainsUsageByDayRequest::setCallerBid(const std::string& callerBid)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
callerBid_ = callerBid;
setParameter("CallerBid", callerBid);
}
long DescribeDomainsUsageByDayRequest::getOwnerId()const
@@ -80,14 +245,58 @@ void DescribeDomainsUsageByDayRequest::setOwnerId(long ownerId)
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeDomainsUsageByDayRequest::getAccessKeyId()const
std::string DescribeDomainsUsageByDayRequest::getVersion()const
{
return accessKeyId_;
return version_;
}
void DescribeDomainsUsageByDayRequest::setAccessKeyId(const std::string& accessKeyId)
void DescribeDomainsUsageByDayRequest::setVersion(const std::string& version)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
version_ = version;
setParameter("Version", version);
}
bool DescribeDomainsUsageByDayRequest::getProxy_trust_transport_info()const
{
return proxy_trust_transport_info_;
}
void DescribeDomainsUsageByDayRequest::setProxy_trust_transport_info(bool proxy_trust_transport_info)
{
proxy_trust_transport_info_ = proxy_trust_transport_info;
setParameter("Proxy_trust_transport_info", std::to_string(proxy_trust_transport_info));
}
bool DescribeDomainsUsageByDayRequest::getAk_mfa_present()const
{
return ak_mfa_present_;
}
void DescribeDomainsUsageByDayRequest::setAk_mfa_present(bool ak_mfa_present)
{
ak_mfa_present_ = ak_mfa_present;
setParameter("Ak_mfa_present", std::to_string(ak_mfa_present));
}
bool DescribeDomainsUsageByDayRequest::getSecurity_transport()const
{
return security_transport_;
}
void DescribeDomainsUsageByDayRequest::setSecurity_transport(bool security_transport)
{
security_transport_ = security_transport;
setParameter("Security_transport", std::to_string(security_transport));
}
std::string DescribeDomainsUsageByDayRequest::getRequestId()const
{
return requestId_;
}
void DescribeDomainsUsageByDayRequest::setRequestId(const std::string& requestId)
{
requestId_ = requestId;
setParameter("RequestId", requestId);
}

View File

@@ -25,37 +25,26 @@ DescribeTopDomainsByFlowRequest::DescribeTopDomainsByFlowRequest() :
DescribeTopDomainsByFlowRequest::~DescribeTopDomainsByFlowRequest()
{}
std::string DescribeTopDomainsByFlowRequest::getSecurityToken()const
long DescribeTopDomainsByFlowRequest::getCallerParentId()const
{
return securityToken_;
return callerParentId_;
}
void DescribeTopDomainsByFlowRequest::setSecurityToken(const std::string& securityToken)
void DescribeTopDomainsByFlowRequest::setCallerParentId(long callerParentId)
{
securityToken_ = securityToken;
setParameter("SecurityToken", securityToken);
callerParentId_ = callerParentId;
setParameter("CallerParentId", std::to_string(callerParentId));
}
long DescribeTopDomainsByFlowRequest::getLimit()const
bool DescribeTopDomainsByFlowRequest::getProxy_original_security_transport()const
{
return limit_;
return proxy_original_security_transport_;
}
void DescribeTopDomainsByFlowRequest::setLimit(long limit)
void DescribeTopDomainsByFlowRequest::setProxy_original_security_transport(bool proxy_original_security_transport)
{
limit_ = limit;
setParameter("Limit", std::to_string(limit));
}
std::string DescribeTopDomainsByFlowRequest::getEndTime()const
{
return endTime_;
}
void DescribeTopDomainsByFlowRequest::setEndTime(const std::string& endTime)
{
endTime_ = endTime;
setParameter("EndTime", endTime);
proxy_original_security_transport_ = proxy_original_security_transport;
setParameter("Proxy_original_security_transport", std::to_string(proxy_original_security_transport));
}
std::string DescribeTopDomainsByFlowRequest::getStartTime()const
@@ -69,15 +58,37 @@ void DescribeTopDomainsByFlowRequest::setStartTime(const std::string& startTime)
setParameter("StartTime", startTime);
}
long DescribeTopDomainsByFlowRequest::getOwnerId()const
std::string DescribeTopDomainsByFlowRequest::getProxy_original_source_ip()const
{
return ownerId_;
return proxy_original_source_ip_;
}
void DescribeTopDomainsByFlowRequest::setOwnerId(long ownerId)
void DescribeTopDomainsByFlowRequest::setProxy_original_source_ip(const std::string& proxy_original_source_ip)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
proxy_original_source_ip_ = proxy_original_source_ip;
setParameter("Proxy_original_source_ip", proxy_original_source_ip);
}
std::string DescribeTopDomainsByFlowRequest::getOwnerIdLoginEmail()const
{
return ownerIdLoginEmail_;
}
void DescribeTopDomainsByFlowRequest::setOwnerIdLoginEmail(const std::string& ownerIdLoginEmail)
{
ownerIdLoginEmail_ = ownerIdLoginEmail;
setParameter("OwnerIdLoginEmail", ownerIdLoginEmail);
}
std::string DescribeTopDomainsByFlowRequest::getCallerType()const
{
return callerType_;
}
void DescribeTopDomainsByFlowRequest::setCallerType(const std::string& callerType)
{
callerType_ = callerType;
setParameter("CallerType", callerType);
}
std::string DescribeTopDomainsByFlowRequest::getAccessKeyId()const
@@ -91,3 +102,190 @@ void DescribeTopDomainsByFlowRequest::setAccessKeyId(const std::string& accessKe
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeTopDomainsByFlowRequest::getSecurityToken()const
{
return securityToken_;
}
void DescribeTopDomainsByFlowRequest::setSecurityToken(const std::string& securityToken)
{
securityToken_ = securityToken;
setParameter("SecurityToken", securityToken);
}
std::string DescribeTopDomainsByFlowRequest::getRequestContent()const
{
return requestContent_;
}
void DescribeTopDomainsByFlowRequest::setRequestContent(const std::string& requestContent)
{
requestContent_ = requestContent;
setParameter("RequestContent", requestContent);
}
long DescribeTopDomainsByFlowRequest::getLimit()const
{
return limit_;
}
void DescribeTopDomainsByFlowRequest::setLimit(long limit)
{
limit_ = limit;
setParameter("Limit", std::to_string(limit));
}
std::string DescribeTopDomainsByFlowRequest::getCallerBidEmail()const
{
return callerBidEmail_;
}
void DescribeTopDomainsByFlowRequest::setCallerBidEmail(const std::string& callerBidEmail)
{
callerBidEmail_ = callerBidEmail;
setParameter("CallerBidEmail", callerBidEmail);
}
std::string DescribeTopDomainsByFlowRequest::getCallerUidEmail()const
{
return callerUidEmail_;
}
void DescribeTopDomainsByFlowRequest::setCallerUidEmail(const std::string& callerUidEmail)
{
callerUidEmail_ = callerUidEmail;
setParameter("CallerUidEmail", callerUidEmail);
}
long DescribeTopDomainsByFlowRequest::getCallerUid()const
{
return callerUid_;
}
void DescribeTopDomainsByFlowRequest::setCallerUid(long callerUid)
{
callerUid_ = callerUid;
setParameter("CallerUid", std::to_string(callerUid));
}
std::string DescribeTopDomainsByFlowRequest::getApp_ip()const
{
return app_ip_;
}
void DescribeTopDomainsByFlowRequest::setApp_ip(const std::string& app_ip)
{
app_ip_ = app_ip;
setParameter("App_ip", app_ip);
}
std::string DescribeTopDomainsByFlowRequest::getPopProduct()const
{
return popProduct_;
}
void DescribeTopDomainsByFlowRequest::setPopProduct(const std::string& popProduct)
{
popProduct_ = popProduct;
setParameter("PopProduct", popProduct);
}
std::string DescribeTopDomainsByFlowRequest::getProduct()const
{
return product_;
}
void DescribeTopDomainsByFlowRequest::setProduct(const std::string& product)
{
product_ = product;
setParameter("Product", product);
}
std::string DescribeTopDomainsByFlowRequest::getEndTime()const
{
return endTime_;
}
void DescribeTopDomainsByFlowRequest::setEndTime(const std::string& endTime)
{
endTime_ = endTime;
setParameter("EndTime", endTime);
}
std::string DescribeTopDomainsByFlowRequest::getCallerBid()const
{
return callerBid_;
}
void DescribeTopDomainsByFlowRequest::setCallerBid(const std::string& callerBid)
{
callerBid_ = callerBid;
setParameter("CallerBid", callerBid);
}
long DescribeTopDomainsByFlowRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeTopDomainsByFlowRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeTopDomainsByFlowRequest::getVersion()const
{
return version_;
}
void DescribeTopDomainsByFlowRequest::setVersion(const std::string& version)
{
version_ = version;
setParameter("Version", version);
}
bool DescribeTopDomainsByFlowRequest::getProxy_trust_transport_info()const
{
return proxy_trust_transport_info_;
}
void DescribeTopDomainsByFlowRequest::setProxy_trust_transport_info(bool proxy_trust_transport_info)
{
proxy_trust_transport_info_ = proxy_trust_transport_info;
setParameter("Proxy_trust_transport_info", std::to_string(proxy_trust_transport_info));
}
bool DescribeTopDomainsByFlowRequest::getAk_mfa_present()const
{
return ak_mfa_present_;
}
void DescribeTopDomainsByFlowRequest::setAk_mfa_present(bool ak_mfa_present)
{
ak_mfa_present_ = ak_mfa_present;
setParameter("Ak_mfa_present", std::to_string(ak_mfa_present));
}
bool DescribeTopDomainsByFlowRequest::getSecurity_transport()const
{
return security_transport_;
}
void DescribeTopDomainsByFlowRequest::setSecurity_transport(bool security_transport)
{
security_transport_ = security_transport;
setParameter("Security_transport", std::to_string(security_transport));
}
std::string DescribeTopDomainsByFlowRequest::getRequestId()const
{
return requestId_;
}
void DescribeTopDomainsByFlowRequest::setRequestId(const std::string& requestId)
{
requestId_ = requestId;
setParameter("RequestId", requestId);
}

View File

@@ -51,6 +51,10 @@ void DescribeUserUsageDataExportTaskResult::parse(const std::string &payload)
for (auto value : allData)
{
UsageDataPerPage::DataItem dataItemObject;
if(!value["TaskName"].isNull())
dataItemObject.taskName = value["TaskName"].asString();
if(!value["TaskId"].isNull())
dataItemObject.taskId = value["TaskId"].asString();
if(!value["CreateTime"].isNull())
dataItemObject.createTime = value["CreateTime"].asString();
if(!value["UpdateTime"].isNull())

View File

@@ -19,7 +19,7 @@
using AlibabaCloud::Cdn::Model::SetDomainGreenManagerConfigRequest;
SetDomainGreenManagerConfigRequest::SetDomainGreenManagerConfigRequest() :
RpcServiceRequest("cdn", "2014-11-11", "SetDomainGreenManagerConfig")
RpcServiceRequest("cdn", "2018-05-10", "SetDomainGreenManagerConfig")
{}
SetDomainGreenManagerConfigRequest::~SetDomainGreenManagerConfigRequest()

View File

@@ -36,6 +36,17 @@ void SetDomainServerCertificateRequest::setPrivateKey(const std::string& private
setParameter("PrivateKey", privateKey);
}
std::string SetDomainServerCertificateRequest::getForceSet()const
{
return forceSet_;
}
void SetDomainServerCertificateRequest::setForceSet(const std::string& forceSet)
{
forceSet_ = forceSet;
setParameter("ForceSet", forceSet);
}
std::string SetDomainServerCertificateRequest::getServerCertificateStatus()const
{
return serverCertificateStatus_;

View File

@@ -1,25 +0,0 @@
add_executable(core-tests
main.cc
httpmessage.cc
signer.cc
url.cc )
set_target_properties(core-tests
PROPERTIES
OUTPUT_NAME ${TARGET_OUTPUT_NAME_PREFIX}core-tests
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
target_link_libraries(core-tests
core
)
ExternalProject_Get_Property(catch INSTALL_DIR)
set(catch_install_dir ${INSTALL_DIR})
add_dependencies(core-tests catch)
target_include_directories(core-tests
PRIVATE ${catch_install_dir}
${CMAKE_SOURCE_DIR}/core/include
)
add_test(NAME core-tests COMMAND core-tests)

View File

@@ -1,33 +0,0 @@
/*
* 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 <catch.hpp>
#include <alibabacloud/core/HttpRequest.h>
using namespace AlibabaCloud;
TEST_CASE("testHttpMessage")
{
const std::string data = "Thu, 19 Oct 2017 04:38:27 GMT";
HttpRequest r;
r.setHeader("accept", "application/xml");
r.setHeader("Accept", "application/json");
r.setHeader("Date", data);
REQUIRE(r.headers().size() == 2);
REQUIRE(r.header("accept") == "application/json");
REQUIRE(r.header(HttpMessage::KnownHeader::Date) == data);
}

View File

@@ -1,18 +0,0 @@
/*
* 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.
*/
#define CATCH_CONFIG_MAIN
#include <catch.hpp>

View File

@@ -1,31 +0,0 @@
/*
* 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 <catch.hpp>
#include <alibabacloud/core/HmacSha1Signer.h>
using namespace AlibabaCloud;
TEST_CASE("testHmacSha1Signer")
{
HmacSha1Signer sig;
std::string sign = sig.generate("GET&%2F&AccessKeyId%3Dtestid%26Action%3DDescribeRegions"
"%26Format%3DXML%26RegionId%3Dregion1%26SignatureMethod%3DHMAC-SHA1"
"%26SignatureNonce%3DNwDAxvLU6tFE0DVb%26SignatureVersion%3D1.0"
"%26TimeStamp%3D2012-12-26T10%253A33%253A56Z%26Version%3D2013-01-10",
"testsecret&");
REQUIRE("axE3FUHgDyfm9/+Iep0HpZXrRwE=" == sign);
}

View File

@@ -1,63 +0,0 @@
/*
* 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 <catch.hpp>
#include <alibabacloud/core/Url.h>
using namespace AlibabaCloud;
TEST_CASE("testUrl")
{
const std::string src = "abc://username:password@example.com:123/path/data?key=value&key2=value2#fragid1";
Url url;
url.setScheme("abc");
url.setUserName("username");
url.setPassword("password");
url.setHost("example.com");
url.setPath("/path/data");
url.setPort(123);
url.setQuery("key=value&key2=value2");
url.setFragment("fragid1");
REQUIRE(url.toString() == src);
url.clear();
url.fromString(src);
REQUIRE(url.scheme() == "abc");
REQUIRE(url.userName() == "username");
REQUIRE(url.password() == "password");
REQUIRE(url.host() == "example.com");
REQUIRE(url.path() == "/path/data");
REQUIRE(url.port() == 123);
REQUIRE(url.query() == "key=value&key2=value2");
REQUIRE(url.fragment() == "fragid1");
Url newurl = url;
REQUIRE(newurl == url);
}
TEST_CASE("testUrl2")
{
const std::string src = "http://oss.example.com";
Url url(src);
REQUIRE(url.scheme() == "http");
REQUIRE(url.userName() == "");
REQUIRE(url.password() == "");
REQUIRE(url.host() == "oss.example.com");
REQUIRE(url.path() == "/");
REQUIRE(url.port() == -1);
REQUIRE(url.query() == "");
REQUIRE(url.fragment() == "");
}

View File

@@ -1,12 +1,12 @@
#
# Copyright 2009-2017 Alibaba Cloud All rights reserved.
#
# Copyright 1999-2019 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.
@@ -14,6 +14,15 @@
# limitations under the License.
#
# coverage option
OPTION (ENABLE_COVERAGE "Use gcov" OFF)
MESSAGE(STATUS ENABLE_COVERAGE=${ENABLE_COVERAGE})
IF(ENABLE_COVERAGE)
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fprofile-arcs -ftest-coverage")
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fprofile-arcs -ftest-coverage")
# SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fprofile-arcs -ftest-coverage")
ENDIF()
configure_file(src/Config.h.in ${CMAKE_CURRENT_SOURCE_DIR}/include/alibabacloud/core/Config.h @ONLY)
set(core_public_header
@@ -120,7 +129,7 @@ set(core_src
src/sts/StsClient.cc
src/sts/StsRequest.cc
src/sts/model/AssumeRoleRequest.cc
src/sts/model/AssumeRoleResult.cc
src/sts/model/AssumeRoleResult.cc
src/sts/model/GetCallerIdentityRequest.cc
src/sts/model/GetCallerIdentityResult.cc
)

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,16 +14,15 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_ALIBABACLOUD_H_
#define ALIBABACLOUD_CORE_ALIBABACLOUD_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_ALIBABACLOUD_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_ALIBABACLOUD_H_
#include "CoreExport.h"
namespace AlibabaCloud
{
ALIBABACLOUD_CORE_EXPORT void InitializeSdk();
ALIBABACLOUD_CORE_EXPORT bool IsSdkInitialized();
ALIBABACLOUD_CORE_EXPORT void ShutdownSdk();
}
namespace AlibabaCloud {
ALIBABACLOUD_CORE_EXPORT void InitializeSdk();
ALIBABACLOUD_CORE_EXPORT bool IsSdkInitialized();
ALIBABACLOUD_CORE_EXPORT void ShutdownSdk();
} // namespace AlibabaCloud
#endif
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_ALIBABACLOUD_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,25 +14,24 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_ASYNCCALLERCONTEXT_H_
#define ALIBABACLOUD_CORE_ASYNCCALLERCONTEXT_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_ASYNCCALLERCONTEXT_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_ASYNCCALLERCONTEXT_H_
#include <string>
#include "CoreExport.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT AsyncCallerContext
{
public:
AsyncCallerContext();
explicit AsyncCallerContext(const std::string &uuid);
virtual ~AsyncCallerContext();
std::string uuid()const;
void setUuid(const std::string &uuid);
private:
std::string uuid_;
};
}
#endif
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT AsyncCallerContext {
public:
AsyncCallerContext();
explicit AsyncCallerContext(const std::string &uuid);
virtual ~AsyncCallerContext();
std::string uuid()const;
void setUuid(const std::string &uuid);
private:
std::string uuid_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_ASYNCCALLERCONTEXT_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,8 +14,8 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_CLIENTCONFIGURATION_H_
#define ALIBABACLOUD_CORE_CLIENTCONFIGURATION_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_CLIENTCONFIGURATION_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_CLIENTCONFIGURATION_H_
#include <memory>
#include <string>
@@ -24,26 +24,25 @@
#include "NetworkProxy.h"
#include "Signer.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT ClientConfiguration
{
public:
explicit ClientConfiguration(const std::string &regionId = "cn-hangzhou",
const NetworkProxy &proxy = NetworkProxy());
~ClientConfiguration();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT ClientConfiguration {
public:
explicit ClientConfiguration(const std::string &regionId = "cn-hangzhou",
const NetworkProxy &proxy = NetworkProxy());
~ClientConfiguration();
std::string endpoint()const;
NetworkProxy proxy()const;
std::string regionId()const;
void setEndpoint(const std::string &endpoint);
void setProxy(const NetworkProxy &proxy);
void setRegionId(const std::string &regionId);
private:
std::string endpoint_;
NetworkProxy proxy_;
std::string regionId_;
};
}
std::string endpoint()const;
NetworkProxy proxy()const;
std::string regionId()const;
void setEndpoint(const std::string &endpoint);
void setProxy(const NetworkProxy &proxy);
void setRegionId(const std::string &regionId);
#endif // !ALIBABACLOUD_CORE_CLIENTCONFIGURATION_H_
private:
std::string endpoint_;
NetworkProxy proxy_;
std::string regionId_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_CLIENTCONFIGURATION_H_

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
* Copyright 1999-2019 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.
@@ -14,10 +14,12 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_COMMONCLIENT_H_
#define ALIBABACLOUD_CORE_COMMONCLIENT_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_COMMONCLIENT_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_COMMONCLIENT_H_
#include <future>
#include <memory>
#include <string>
#include "AsyncCallerContext.h"
#include "ClientConfiguration.h"
#include "CoreExport.h"
@@ -26,38 +28,50 @@
#include "CommonResponse.h"
#include "CredentialsProvider.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT CommonClient : public CoreClient
{
public:
typedef Outcome<Error, CommonResponse> CommonResponseOutcome;
typedef std::future<CommonResponseOutcome> CommonResponseOutcomeCallable;
typedef std::function<void(const CommonClient*, const CommonRequest&, const CommonResponseOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CommonResponseAsyncHandler;
typedef Outcome<Error, std::string> JsonOutcome;
CommonClient(const Credentials &credentials, const ClientConfiguration &configuration);
CommonClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider, const ClientConfiguration &configuration);
CommonClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration);
~CommonClient();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT CommonClient : public CoreClient {
public:
typedef Outcome<Error, CommonResponse> CommonResponseOutcome;
typedef std::future<CommonResponseOutcome> CommonResponseOutcomeCallable;
typedef std::function<void(const CommonClient*, const CommonRequest&,
const CommonResponseOutcome&,
const std::shared_ptr<const AsyncCallerContext>&)>
CommonResponseAsyncHandler;
typedef Outcome<Error, std::string> JsonOutcome;
CommonResponseOutcome commonResponse(const CommonRequest &request)const;
void commonResponseAsync(const CommonRequest& request, const CommonResponseAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
CommonResponseOutcomeCallable commonResponseCallable(const CommonRequest& request) const;
CommonClient(const Credentials &credentials,
const ClientConfiguration &configuration);
CommonClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider,
const ClientConfiguration &configuration);
CommonClient(const std::string &accessKeyId,
const std::string &accessKeySecret,
const ClientConfiguration &configuration);
~CommonClient();
protected:
virtual HttpRequest buildHttpRequest(const std::string & endpoint, const ServiceRequest & msg, HttpRequest::Method method) const override;
HttpRequest buildHttpRequest(const std::string & endpoint, const CommonRequest &msg, HttpRequest::Method method) const;
HttpRequest buildRoaHttpRequest(const std::string & endpoint, const CommonRequest &msg, HttpRequest::Method method) const;
HttpRequest buildRpcHttpRequest(const std::string & endpoint, const CommonRequest &msg, HttpRequest::Method method) const;
JsonOutcome makeRequest(const std::string &endpoint, const CommonRequest &msg, HttpRequest::Method method = HttpRequest::Method::Get)const;
CommonResponseOutcome commonResponse(const CommonRequest &request) const;
void commonResponseAsync(const CommonRequest& request,
const CommonResponseAsyncHandler& handler,
const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
CommonResponseOutcomeCallable commonResponseCallable(
const CommonRequest& request) const;
private:
std::string canonicalizedQuery(const std::map <std::string, std::string> &params)const;
std::string canonicalizedHeaders(const HttpMessage::HeaderCollection &headers)const;
protected:
HttpRequest buildHttpRequest(const std::string & endpoint,
const ServiceRequest & msg, HttpRequest::Method method) const override;
HttpRequest buildHttpRequest(const std::string & endpoint,
const CommonRequest &msg, HttpRequest::Method method) const;
HttpRequest buildRoaHttpRequest(const std::string & endpoint,
const CommonRequest &msg, HttpRequest::Method method) const;
HttpRequest buildRpcHttpRequest(const std::string & endpoint,
const CommonRequest &msg, HttpRequest::Method method) const;
JsonOutcome makeRequest(const std::string &endpoint,
const CommonRequest &msg, HttpRequest::Method method =
HttpRequest::Method::Get) const;
using CoreClient::asyncExecute;
std::shared_ptr<CredentialsProvider> credentialsProvider_;
std::shared_ptr<Signer> signer_;
};
}
#endif // !ALIBABACLOUD_CORE_COMMONCLIENT_H_
private:
std::shared_ptr<CredentialsProvider> credentialsProvider_;
std::shared_ptr<Signer> signer_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_COMMONCLIENT_H_

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
* Copyright 1999-2019 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.
@@ -14,52 +14,53 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_COMMONREQUEST_H_
#define ALIBABACLOUD_CORE_COMMONREQUEST_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_COMMONREQUEST_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_COMMONREQUEST_H_
#include <string>
#include "CoreExport.h"
#include "ServiceRequest.h"
#include "HttpRequest.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT CommonRequest : public ServiceRequest
{
public:
enum RequestPattern
{
RpcPattern,
RoaPattern
};
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT CommonRequest : public ServiceRequest {
public:
enum RequestPattern {
RpcPattern,
RoaPattern
};
explicit CommonRequest(RequestPattern pattern = RpcPattern);
~CommonRequest();
explicit CommonRequest(RequestPattern pattern = RpcPattern);
~CommonRequest();
std::string domain()const;
ParameterValueType headerParameter(const ParameterNameType &name)const;
ParameterCollection headerParameters()const;
HttpRequest::Method httpMethod()const;
ParameterValueType queryParameter(const ParameterNameType &name)const;
ParameterCollection queryParameters()const;
using ServiceRequest::setContent;
void setDomain(const std::string &domain);
void setHeaderParameter(const ParameterNameType &name, const ParameterValueType &value);
void setHttpMethod(HttpRequest::Method method);
void setQueryParameter(const ParameterNameType &name, const ParameterValueType &value);
using ServiceRequest::setResourcePath;
void setRequestPattern(RequestPattern pattern);
using ServiceRequest::setVersion;
RequestPattern requestPattern()const;
protected:
using ServiceRequest::product;
std::string domain() const;
ParameterValueType headerParameter(const ParameterNameType &name) const;
ParameterCollection headerParameters() const;
HttpRequest::Method httpMethod() const;
ParameterValueType queryParameter(const ParameterNameType &name) const;
ParameterCollection queryParameters() const;
using ServiceRequest::setContent;
void setDomain(const std::string &domain);
void setHeaderParameter(const ParameterNameType &name,
const ParameterValueType &value);
void setHttpMethod(HttpRequest::Method method);
void setQueryParameter(const ParameterNameType &name,
const ParameterValueType &value);
using ServiceRequest::setResourcePath;
void setRequestPattern(RequestPattern pattern);
using ServiceRequest::setVersion;
using ServiceRequest::setScheme;
RequestPattern requestPattern() const;
private:
std::string domain_;
RequestPattern requestPattern_;
ParameterCollection queryParams_;
ParameterCollection headerParams_;
HttpRequest::Method httpMethod_;
};
}
#endif // !ALIBABACLOUD_CORE_COMMONREQUEST_H_
protected:
using ServiceRequest::product;
private:
std::string domain_;
RequestPattern requestPattern_;
ParameterCollection queryParams_;
ParameterCollection headerParams_;
HttpRequest::Method httpMethod_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_COMMONREQUEST_H_

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
* Copyright 1999-2019 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.
@@ -14,25 +14,23 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_COMMONRESPONSE_H_
#define ALIBABACLOUD_CORE_COMMONRESPONSE_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_COMMONRESPONSE_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_COMMONRESPONSE_H_
#include <string>
#include "CoreExport.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT CommonResponse
{
public:
CommonResponse();
explicit CommonResponse(const std::string &payload);
~CommonResponse();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT CommonResponse {
public:
CommonResponse();
explicit CommonResponse(const std::string &payload);
~CommonResponse();
std::string payload()const;
private:
std::string payload_;
std::string payload()const;
};
}
#endif // !ALIBABACLOUD_CORE_COMMONRESPONSE_H_
private:
std::string payload_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_COMMONRESPONSE_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,11 +14,12 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_CORECLIENT_H_
#define ALIBABACLOUD_CORE_CORECLIENT_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_CORECLIENT_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_CORECLIENT_H_
#include <functional>
#include <memory>
#include <string>
#include "ClientConfiguration.h"
#include "CoreExport.h"
#include "HttpClient.h"
@@ -28,27 +29,31 @@
#include "ServiceRequest.h"
#include "Runnable.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT CoreClient
{
public:
CoreClient(const std::string & servicename, const ClientConfiguration &configuration);
virtual ~CoreClient();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT CoreClient {
public:
CoreClient(const std::string & servicename,
const ClientConfiguration &configuration);
virtual ~CoreClient();
ClientConfiguration configuration()const;
std::string serviceName()const;
protected:
HttpClient::HttpResponseOutcome AttemptRequest(const std::string & endpoint, const ServiceRequest &request, HttpRequest::Method method)const;
Error buildCoreError(const HttpResponse &response)const;
bool hasResponseError(const HttpResponse &response)const;
virtual HttpRequest buildHttpRequest(const std::string & endpoint, const ServiceRequest &msg, HttpRequest::Method method)const = 0;
void asyncExecute(Runnable * r)const;
private:
std::string serviceName_;
ClientConfiguration configuration_;
std::shared_ptr<CredentialsProvider> credentialsProvider_;
HttpClient *httpClient_;
};
}
#endif
ClientConfiguration configuration() const;
std::string serviceName() const;
protected:
virtual HttpClient::HttpResponseOutcome AttemptRequest(
const std::string & endpoint,
const ServiceRequest &request, HttpRequest::Method method) const;
Error buildCoreError(const HttpResponse &response)const;
bool hasResponseError(const HttpResponse &response)const;
virtual HttpRequest buildHttpRequest(const std::string & endpoint,
const ServiceRequest &msg, HttpRequest::Method method) const = 0;
void asyncExecute(Runnable * r) const;
private:
std::string serviceName_;
ClientConfiguration configuration_;
std::shared_ptr<CredentialsProvider> credentialsProvider_;
HttpClient *httpClient_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_CORECLIENT_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,19 +14,19 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_COREEXPORT_H_
#define ALIBABACLOUD_CORE_COREEXPORT_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_COREEXPORT_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_COREEXPORT_H_
#include "Global.h"
#if defined(ALIBABACLOUD_SHARED)
# if defined(ALIBABACLOUD_CORE_LIBRARY)
# define ALIBABACLOUD_CORE_EXPORT ALIBABACLOUD_DECL_EXPORT
# else
# define ALIBABACLOUD_CORE_EXPORT ALIBABACLOUD_DECL_IMPORT
# endif
# if defined(ALIBABACLOUD_CORE_LIBRARY)
# define ALIBABACLOUD_CORE_EXPORT ALIBABACLOUD_DECL_EXPORT
# else
# define ALIBABACLOUD_CORE_EXPORT ALIBABACLOUD_DECL_IMPORT
# endif
#else
# define ALIBABACLOUD_CORE_EXPORT
# define ALIBABACLOUD_CORE_EXPORT
#endif
#endif // !ALIBABACLOUD_CORE_COREEXPORT_H_
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_COREEXPORT_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,34 +14,32 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_CREDENTIAL_H_
#define ALIBABACLOUD_CORE_CREDENTIAL_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_CREDENTIALS_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_CREDENTIALS_H_
#include <string>
#include "CoreExport.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT Credentials
{
public:
Credentials(const std::string &accessKeyId,
const std::string &accessKeySecret,
const std::string &sessionToken="");
~Credentials();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT Credentials {
public:
Credentials(const std::string &accessKeyId,
const std::string &accessKeySecret,
const std::string &sessionToken = "");
~Credentials();
std::string accessKeyId () const;
std::string accessKeySecret () const;
void setAccessKeyId(const std::string &accessKeyId);
void setAccessKeySecret(const std::string &accessKeySecret);
void setSessionToken (const std::string &sessionToken);
std::string sessionToken () const;
std::string accessKeyId() const;
std::string accessKeySecret() const;
void setAccessKeyId(const std::string &accessKeyId);
void setAccessKeySecret(const std::string &accessKeySecret);
void setSessionToken(const std::string &sessionToken);
std::string sessionToken() const;
private:
std::string accessKeyId_;
std::string accessKeySecret_;
std::string sessionToken_;
};
}
private:
std::string accessKeyId_;
std::string accessKeySecret_;
std::string sessionToken_;
};
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_CORE_CREDENTIAL_H_
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_CREDENTIALS_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,23 +14,20 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_CREDENTIALSPROVIDER_H_
#define ALIBABACLOUD_CORE_CREDENTIALSPROVIDER_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_CREDENTIALSPROVIDER_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_CREDENTIALSPROVIDER_H_
#include "CoreExport.h"
#include "Credentials.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT CredentialsProvider
{
public:
CredentialsProvider() = default;
virtual ~CredentialsProvider() = default;
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT CredentialsProvider {
public:
CredentialsProvider() = default;
virtual ~CredentialsProvider() = default;
virtual Credentials getCredentials() = 0;
virtual Credentials getCredentials() = 0;
private:
};
}
#endif
private:
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_CREDENTIALSPROVIDER_H_

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
* Copyright 1999-2019 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.
@@ -14,57 +14,58 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_ENDPOINTPROVIDER_H_
#define ALIBABACLOUD_CORE_ENDPOINTPROVIDER_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_ENDPOINTPROVIDER_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_ENDPOINTPROVIDER_H_
#include <alibabacloud/core/location/LocationClient.h>
#include <alibabacloud/core/CoreClient.h>
#include <string>
#include <chrono>
#include <list>
#include <map>
#include <memory>
#include <mutex>
#include <alibabacloud/core/location/LocationClient.h>
#include <alibabacloud/core/CoreClient.h>
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT EndpointProvider
{
public:
typedef Outcome<Error, std::string> EndpointOutcome;
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT EndpointProvider :
public Location::LocationClient {
public:
typedef Outcome<Error, std::string> EndpointOutcome;
EndpointProvider(const std::shared_ptr<Location::LocationClient>& locationClient,
const std::string regionId,
const std::string product,
const std::string serviceCode = std::string(),
int durationSeconds = 3600);
~EndpointProvider();
EndpointProvider(
const std::shared_ptr<Location::LocationClient>& locationClient,
const std::string regionId,
const std::string product,
const std::string serviceCode = std::string(),
int durationSeconds = 3600);
EndpointOutcome getEndpoint();
private:
struct Product
{
std::string code;
std::string locationServiceCode;
std::string documentId;
std::map<std::string, std::string> regionalEndpoints;
std::string globalEndpoint;
std::string regionalEndpointPattern;
};
EndpointProvider(
const Credentials &credentials,
const ClientConfiguration &configuration,
const std::string &regionId,
const std::string &product,
const std::string &serviceCode = std::string(),
int durationSeconds = 3600);
~EndpointProvider();
EndpointOutcome loadRemoteEndpoint();
bool checkExpiry()const;
bool loadInternalProductsInfo();
std::string internalEndpoint(const std::string regionId, const std::string product);
EndpointOutcome getEndpoint();
using LocationClient::describeEndpoints;
std::mutex cachedMutex_;
std::string cachedEndpoint_;
std::shared_ptr<Location::LocationClient> locationClient_;
int durationSeconds_;
std::chrono::system_clock::time_point expiry_;
std::string regionId_;
std::string product_;
std::string serviceCode_;
std::list<Product> internalProductsInfo_;
};
}
#endif
private:
EndpointOutcome loadRemoteEndpoint();
bool checkExpiry()const;
bool loadLocalProductsInfo();
std::string localEndpoint(const std::string regionId,
const std::string product);
std::mutex cachedMutex_;
std::string cachedEndpoint_;
int durationSeconds_;
std::chrono::system_clock::time_point expiry_;
std::string regionId_;
std::string product_;
std::string serviceCode_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_ENDPOINTPROVIDER_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,35 +14,37 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_ERROR_H_
#define ALIBABACLOUD_CORE_ERROR_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_ERROR_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_ERROR_H_
#include <string>
#include "CoreExport.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT Error
{
public:
Error() = default;
Error(std::string code, const std::string message);
~Error() = default;
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT Error {
public:
Error() = default;
Error(std::string code, const std::string message);
~Error() = default;
std::string errorCode()const;
std::string errorMessage() const;
std::string host() const;
std::string requestId() const;
void setErrorCode(const std::string &code);
void setErrorMessage(const std::string& message);
void setHost(const std::string& host);
void setRequestId(const std::string& request);
private:
std::string errorCode_;
std::string message_;
std::string host_;
std::string requestId_;
};
}
std::string errorCode() const;
std::string errorMessage() const;
std::string host() const;
std::string requestId() const;
std::string detail() const;
void setErrorCode(const std::string &code);
void setErrorMessage(const std::string& message);
void setHost(const std::string& host);
void setRequestId(const std::string& request);
void setDetail(const std::string& detail);
#endif // !ALIBABACLOUD_CORE_ERROR_H_
private:
std::string errorCode_;
std::string message_;
std::string host_;
std::string requestId_;
std::string detail_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_ERROR_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,28 +14,28 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_GLOBAL_H_
#define ALIBABACLOUD_CORE_GLOBAL_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_GLOBAL_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_GLOBAL_H_
#include "Config.h"
#if defined(_WIN32)
# ifdef _MSC_VER
# pragma warning(disable : 4251)
# endif // _MSC_VER
# define ALIBABACLOUD_DECL_EXPORT __declspec(dllexport)
# define ALIBABACLOUD_DECL_IMPORT __declspec(dllimport)
# ifdef _MSC_VER
# pragma warning(disable : 4251)
# endif // _MSC_VER
# define ALIBABACLOUD_DECL_EXPORT __declspec(dllexport)
# define ALIBABACLOUD_DECL_IMPORT __declspec(dllimport)
#elif defined(__linux__)
# define ALIBABACLOUD_DECL_EXPORT __attribute__((visibility("default")))
# define ALIBABACLOUD_DECL_IMPORT __attribute__((visibility("default")))
# define ALIBABACLOUD_DECL_EXPORT __attribute__((visibility("default")))
# define ALIBABACLOUD_DECL_IMPORT __attribute__((visibility("default")))
#endif
#if !defined(ALIBABACLOUD_DECL_EXPORT)
# define ALIBABACLOUD_DECL_EXPORT
# define ALIBABACLOUD_DECL_EXPORT
#endif
#if !defined(ALIBABACLOUD_DECL_IMPORT)
# define ALIBABACLOUD_DECL_IMPORT
# define ALIBABACLOUD_DECL_IMPORT
#endif
#endif // !ALIBABACLOUD_CORE_GLOBAL_H_
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_GLOBAL_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,21 +14,21 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_HMACSHA1SIGNER_H_
#define ALIBABACLOUD_CORE_HMACSHA1SIGNER_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_HMACSHA1SIGNER_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_HMACSHA1SIGNER_H_
#include "Signer.h"
#include <string>
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT HmacSha1Signer : public Signer
{
public:
HmacSha1Signer();
~HmacSha1Signer();
virtual std::string generate(const std::string &src, const std::string &secret)const override;
};
}
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT HmacSha1Signer : public Signer {
public:
HmacSha1Signer();
~HmacSha1Signer();
#endif // !ALIBABACLOUD_CORE_HMACSHA1SIGNER_H_
std::string generate(const std::string &src,
const std::string &secret) const override;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_HMACSHA1SIGNER_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,8 +14,8 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_HTTPCLIENT_H_
#define ALIBABACLOUD_CORE_HTTPCLIENT_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPCLIENT_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPCLIENT_H_
#include <alibabacloud/core/HttpRequest.h>
#include <alibabacloud/core/HttpResponse.h>
@@ -23,21 +23,20 @@
#include <alibabacloud/core/Outcome.h>
#include <alibabacloud/core/Error.h>
namespace AlibabaCloud
{
class HttpClient
{
public:
typedef Outcome<Error, HttpResponse> HttpResponseOutcome;
namespace AlibabaCloud {
class HttpClient {
public:
typedef Outcome<Error, HttpResponse> HttpResponseOutcome;
HttpClient();
virtual ~HttpClient();
HttpClient();
virtual ~HttpClient();
virtual HttpResponseOutcome makeRequest(const HttpRequest &request) = 0;
NetworkProxy proxy()const;
void setProxy(const NetworkProxy &proxy);
private:
NetworkProxy proxy_;
};
}
#endif
virtual HttpResponseOutcome makeRequest(const HttpRequest &request) = 0;
NetworkProxy proxy()const;
void setProxy(const NetworkProxy &proxy);
private:
NetworkProxy proxy_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPCLIENT_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,69 +14,69 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_HTTPMESSAGE_H_
#define ALIBABACLOUD_CORE_HTTPMESSAGE_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPMESSAGE_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPMESSAGE_H_
#include <map>
#include <string>
#include "CoreExport.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT HttpMessage
{
private:
struct ALIBABACLOUD_CORE_EXPORT nocaseLess
{
bool operator() (const std::string & s1, const std::string & s2) const;
};
public:
enum KnownHeader
{
Accept,
AcceptCharset,
AcceptEncoding,
AcceptLanguage,
Authorization,
Connection,
ContentLength,
ContentMD5,
ContentType,
Date,
Host,
Server,
UserAgent
};
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT HttpMessage {
private:
struct ALIBABACLOUD_CORE_EXPORT nocaseLess {
bool operator() (const std::string & s1, const std::string & s2) const;
};
typedef std::string HeaderNameType;
typedef std::string HeaderValueType;
typedef std::map<HeaderNameType, HeaderValueType, nocaseLess> HeaderCollection;
public:
enum KnownHeader {
Accept,
AcceptCharset,
AcceptEncoding,
AcceptLanguage,
Authorization,
Connection,
ContentLength,
ContentMD5,
ContentType,
Date,
Host,
Server,
UserAgent
};
HttpMessage(const HttpMessage &other);
HttpMessage(HttpMessage &&other);
HttpMessage& operator=(const HttpMessage &other);
HttpMessage& operator=(HttpMessage &&other);
virtual ~HttpMessage();
typedef std::string HeaderNameType;
typedef std::string HeaderValueType;
typedef std::map<HeaderNameType, HeaderValueType, nocaseLess>
HeaderCollection;
void addHeader(const HeaderNameType &name, const HeaderValueType &value);
void addHeader(KnownHeader header, const HeaderValueType &value);
const char* body()const;
size_t bodySize()const;
bool hasBody()const;
HeaderValueType header(const HeaderNameType &name)const;
HeaderValueType header(KnownHeader header)const;
HeaderCollection headers()const;
void removeHeader(const HeaderNameType &name);
void removeHeader(KnownHeader header);
void setBody(const char *data, size_t size);
void setHeader(const HeaderNameType &name, const HeaderValueType &value);
void setHeader(KnownHeader header, const std::string &value);
protected:
HttpMessage();
private:
char *body_;
size_t bodySize_;
HeaderCollection headers_;
};
}
#endif // !ALIBABACLOUD_CORE_HTTPMESSAGE_H_
HttpMessage(const HttpMessage &other);
HttpMessage(HttpMessage &&other);
HttpMessage& operator=(const HttpMessage &other);
HttpMessage& operator=(HttpMessage &&other);
virtual ~HttpMessage();
void addHeader(const HeaderNameType &name, const HeaderValueType &value);
void addHeader(KnownHeader header, const HeaderValueType &value);
const char* body()const;
size_t bodySize()const;
bool hasBody()const;
HeaderValueType header(const HeaderNameType &name) const;
HeaderValueType header(KnownHeader header) const;
HeaderCollection headers()const;
void removeHeader(const HeaderNameType &name);
void removeHeader(KnownHeader header);
void setBody(const char *data, size_t size);
void setHeader(const HeaderNameType &name, const HeaderValueType &value);
void setHeader(KnownHeader header, const std::string &value);
protected:
HttpMessage();
private:
char *body_;
size_t bodySize_;
HeaderCollection headers_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPMESSAGE_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,40 +14,38 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_HTTPREQUEST_H_
#define ALIBABACLOUD_CORE_HTTPREQUEST_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPREQUEST_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPREQUEST_H_
#include <string>
#include "HttpMessage.h"
#include "Url.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT HttpRequest : public HttpMessage
{
public:
enum Method
{
Get,
Head,
Post,
Put,
Delete,
Connect,
Options,
Patch,
Trace
};
explicit HttpRequest(const Url &url = Url(), Method method = Get);
~HttpRequest();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT HttpRequest : public HttpMessage {
public:
enum Method {
Get,
Head,
Post,
Put,
Delete,
Connect,
Options,
Patch,
Trace
};
explicit HttpRequest(const Url &url = Url(), Method method = Get);
~HttpRequest();
Method method()const;
void setMethod(Method method);
void setUrl(const Url &url);
Url url()const;
private:
Method method_;
Url url_;
};
}
#endif
Method method()const;
void setMethod(Method method);
void setUrl(const Url &url);
Url url()const;
private:
Method method_;
Url url_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPREQUEST_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,30 +14,29 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_HTTPRESPONSE_H_
#define ALIBABACLOUD_CORE_HTTPRESPONSE_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPRESPONSE_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPRESPONSE_H_
#include <string>
#include "CoreExport.h"
#include "HttpMessage.h"
#include "HttpRequest.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT HttpResponse : public HttpMessage
{
public:
HttpResponse();
explicit HttpResponse(const HttpRequest & request);
~HttpResponse();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT HttpResponse : public HttpMessage {
public:
HttpResponse();
explicit HttpResponse(const HttpRequest & request);
~HttpResponse();
HttpRequest request()const;
void setStatusCode(int code);
int statusCode()const;
private:
int statusCode_;
HttpRequest request_;
};
}
HttpRequest request()const;
void setStatusCode(int code);
int statusCode()const;
#endif // !ALIBABACLOUD_CORE_HTTPRESPONSE_H_
private:
int statusCode_;
HttpRequest request_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_HTTPRESPONSE_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,21 +14,18 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALS_H_
#define ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALS_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALS_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALS_H_
#include "BasicSessionCredentials.h"
namespace AlibabaCloud
{
class InstanceProfileCredentials : public BasicSessionCredentials
{
public:
InstanceProfileCredentials();
~InstanceProfileCredentials();
namespace AlibabaCloud {
class InstanceProfileCredentials : public BasicSessionCredentials {
public:
InstanceProfileCredentials();
~InstanceProfileCredentials();
private:
};
}
#endif // !ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALS_H_
private:
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALS_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,8 +14,8 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALSPROVIDER_H_
#define ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALSPROVIDER_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALSPROVIDER_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALSPROVIDER_H_
#include <chrono>
#include <mutex>
@@ -23,28 +23,30 @@
#include <string>
#include "CredentialsProvider.h"
#include "Credentials.h"
#include "../src/EcsMetadataFetcher.h"
namespace AlibabaCloud
{
class EcsMetadataFetcher;
class ALIBABACLOUD_CORE_EXPORT InstanceProfileCredentialsProvider : public CredentialsProvider
{
public:
InstanceProfileCredentialsProvider(const std::string &roleName, int durationSeconds = 3600);
~InstanceProfileCredentialsProvider();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT InstanceProfileCredentialsProvider :
public CredentialsProvider, public EcsMetadataFetcher {
public:
InstanceProfileCredentialsProvider(const std::string &roleName,
int durationSeconds = 3600);
~InstanceProfileCredentialsProvider();
std::string roleName()const;
virtual Credentials getCredentials() override;
std::string roleName()const;
Credentials getCredentials() override;
using EcsMetadataFetcher::roleName;
using EcsMetadataFetcher::setRoleName;
using EcsMetadataFetcher::getMetadata;
private:
void loadCredentials();
bool checkExpiry()const;
private:
void loadCredentials();
bool checkExpiry()const;
std::mutex cachedMutex_;
Credentials cachedCredentials_;
int durationSeconds_;
std::chrono::system_clock::time_point expiry_;
EcsMetadataFetcher *fetcher_;
};
}
#endif
std::mutex cachedMutex_;
Credentials cachedCredentials_;
int durationSeconds_;
std::chrono::system_clock::time_point expiry_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_INSTANCEPROFILECREDENTIALSPROVIDER_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,46 +14,44 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_NETWORKPROXY_H_
#define ALIBABACLOUD_CORE_NETWORKPROXY_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_NETWORKPROXY_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_NETWORKPROXY_H_
#include <string>
#include "CoreExport.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT NetworkProxy
{
public:
enum Type
{
None = 0,
Http,
Socks5
};
NetworkProxy(Type type = None,
const std::string &hostName = "",
uint16_t port = 0,
const std::string &user = "",
const std::string &password = "");
~NetworkProxy();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT NetworkProxy {
public:
enum Type {
None = 0,
Http,
Socks5
};
NetworkProxy(Type type = None,
const std::string &hostName = "",
uint16_t port = 0,
const std::string &user = "",
const std::string &password = "");
~NetworkProxy();
std::string hostName() const;
std::string password() const;
uint16_t port() const;
void setHostName(const std::string &hostName);
void setPassword(const std::string &password);
void setPort(uint16_t port);
void setType(Type type);
void setUser(const std::string &user);
Type type() const;
std::string user() const;
private:
std::string hostName_;
std::string password_;
uint16_t port_;
Type type_;
std::string user_;
};
}
#endif // !ALIBABACLOUD_CORE_NETWORKPROXY_H_
std::string hostName() const;
std::string password() const;
uint16_t port() const;
void setHostName(const std::string &hostName);
void setPassword(const std::string &password);
void setPort(uint16_t port);
void setType(Type type);
void setUser(const std::string &user);
Type type() const;
std::string user() const;
private:
std::string hostName_;
std::string password_;
uint16_t port_;
Type type_;
std::string user_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_NETWORKPROXY_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,59 +14,54 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_OUTCOME_H_
#define ALIBABACLOUD_CORE_OUTCOME_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_OUTCOME_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_OUTCOME_H_
#include <utility>
namespace AlibabaCloud
{
template<typename E, typename R>
class Outcome
{
public:
Outcome() :
success_(true), e_(), r_() { }
explicit Outcome(const E &e) :
e_(e), success_(false), r_() { }
explicit Outcome(const R &r) :
r_(r), success_(true), e_() { }
Outcome(const Outcome &other) :
success_(other.success_),
e_(other.e_),
r_(other.r_)
{ }
Outcome(Outcome &&other)
{
*this = std::move(other);
}
Outcome & operator=(const Outcome &other)
{
if (this != &other) {
success_ = other.success_;
e_ = other.e_;
r_ = other.r_;
}
return *this;
}
Outcome & operator=(Outcome &&other)
{
if (this != &other)
{
success_ = other.success_;
r_ = other.r_;
e_ = other.e_;
}
return *this;
}
namespace AlibabaCloud {
template<typename E, typename R>
class Outcome {
public:
Outcome() :
success_(true), e_(), r_() { }
explicit Outcome(const E &e) :
e_(e), success_(false), r_() { }
explicit Outcome(const R &r) :
r_(r), success_(true), e_() { }
Outcome(const Outcome &other) :
success_(other.success_),
e_(other.e_),
r_(other.r_)
{ }
Outcome(Outcome &&other) {
*this = std::move(other);
}
Outcome & operator=(const Outcome &other) {
if (this != &other) {
success_ = other.success_;
e_ = other.e_;
r_ = other.r_;
}
return *this;
}
Outcome & operator=(Outcome &&other) {
if (this != &other) {
success_ = other.success_;
r_ = other.r_;
e_ = other.e_;
}
return *this;
}
bool isSuccess()const { return success_; }
E error()const { return e_; }
R result()const { return r_; }
private:
bool success_;
E e_;
R r_;
};
}
#endif // !ALIBABACLOUD_CORE_OUTCOME_H_
bool isSuccess()const { return success_; }
E error()const { return e_; }
R result()const { return r_; }
private:
bool success_;
E e_;
R r_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_OUTCOME_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,8 +14,8 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_ROASERVICECLIENT_H_
#define ALIBABACLOUD_CORE_ROASERVICECLIENT_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_ROASERVICECLIENT_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_ROASERVICECLIENT_H_
#include <map>
#include <memory>
@@ -26,29 +26,31 @@
#include "HttpRequest.h"
#include "RoaServiceRequest.h"
namespace AlibabaCloud
{
class RoaErrorMarshaller;
class ALIBABACLOUD_CORE_EXPORT RoaServiceClient : public CoreClient
{
public:
typedef Outcome<Error, std::string> JsonOutcome;
namespace AlibabaCloud {
class RoaErrorMarshaller;
class ALIBABACLOUD_CORE_EXPORT RoaServiceClient : public CoreClient {
public:
typedef Outcome<Error, std::string> JsonOutcome;
RoaServiceClient(const std::string & servicename, const std::shared_ptr<CredentialsProvider> &credentialsProvider,
const ClientConfiguration &configuration,
const std::shared_ptr<Signer> &signer = std::make_shared<HmacSha1Signer>());
virtual ~RoaServiceClient();
RoaServiceClient(const std::string & servicename,
const std::shared_ptr<CredentialsProvider> &credentialsProvider,
const ClientConfiguration &configuration,
const std::shared_ptr<Signer> &signer =
std::make_shared<HmacSha1Signer>());
virtual ~RoaServiceClient();
protected:
JsonOutcome makeRequest(const std::string &endpoint, const RoaServiceRequest &msg, HttpRequest::Method method = HttpRequest::Method::Get)const;
virtual HttpRequest buildHttpRequest(const std::string & endpoint, const ServiceRequest &msg, HttpRequest::Method method)const override;
HttpRequest buildHttpRequest(const std::string & endpoint, const RoaServiceRequest &msg, HttpRequest::Method method)const;
private:
std::string canonicalizedHeaders(const HttpMessage::HeaderCollection &headers)const;
std::string canonicalizedResource(const std::string &path, std::map <std::string, std::string> &params)const;
std::shared_ptr<CredentialsProvider> credentialsProvider_;
std::shared_ptr<Signer> signer_;
};
}
#endif // !ALIBABACLOUD_CORE_ROASERVICECLIENT_H_
protected:
JsonOutcome makeRequest(const std::string &endpoint,
const RoaServiceRequest &msg, HttpRequest::Method method =
HttpRequest::Method::Get)const;
HttpRequest buildHttpRequest(const std::string & endpoint,
const ServiceRequest &msg, HttpRequest::Method method)const override;
HttpRequest buildHttpRequest(const std::string & endpoint,
const RoaServiceRequest &msg, HttpRequest::Method method)const;
private:
std::shared_ptr<CredentialsProvider> credentialsProvider_;
std::shared_ptr<Signer> signer_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_ROASERVICECLIENT_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,19 +14,21 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_ROASERVICEREQUEST_H_
#define ALIBABACLOUD_CORE_ROASERVICEREQUEST_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_ROASERVICEREQUEST_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_ROASERVICEREQUEST_H_
#include "ServiceRequest.h"
#include <string>
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT RoaServiceRequest : public ServiceRequest
{
public:
RoaServiceRequest(const std::string &product, const std::string &version);
virtual ~RoaServiceRequest();
};
}
#endif // !ALIBABACLOUD_CORE_ROASERVICEREQUEST_H_
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT RoaServiceRequest : public ServiceRequest {
public:
RoaServiceRequest(const std::string &product, const std::string &version);
virtual ~RoaServiceRequest();
using ServiceRequest::setParameter;
using ServiceRequest::setContent;
using ServiceRequest::parameter;
using ServiceRequest::setScheme;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_ROASERVICEREQUEST_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,8 +14,8 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_RPCSERVICECLIENT_H_
#define ALIBABACLOUD_CORE_RPCSERVICECLIENT_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_RPCSERVICECLIENT_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_RPCSERVICECLIENT_H_
#include <map>
#include <memory>
@@ -27,29 +27,38 @@
#include "RpcServiceRequest.h"
#include "Outcome.h"
namespace AlibabaCloud
{
class RpcErrorMarshaller;
class RpcServiceRequest;
class ALIBABACLOUD_CORE_EXPORT RpcServiceClient : public CoreClient
{
public:
typedef Outcome<Error, std::string> JsonOutcome;
namespace AlibabaCloud {
class RpcErrorMarshaller;
class RpcServiceRequest;
class ALIBABACLOUD_CORE_EXPORT RpcServiceClient : public CoreClient {
public:
typedef Outcome<Error, std::string> JsonOutcome;
RpcServiceClient(const std::string & servicename, const std::shared_ptr<CredentialsProvider> &credentialsProvider,
const ClientConfiguration &configuration,
const std::shared_ptr<Signer> &signer = std::make_shared<HmacSha1Signer>());
virtual ~RpcServiceClient();
protected:
JsonOutcome makeRequest(const std::string &endpoint, const RpcServiceRequest &msg, HttpRequest::Method method = HttpRequest::Method::Get)const;
virtual HttpRequest buildHttpRequest(const std::string & endpoint, const ServiceRequest &msg, HttpRequest::Method method)const override;
HttpRequest buildHttpRequest(const std::string & endpoint, const RpcServiceRequest &msg, HttpRequest::Method method)const;
private:
std::string canonicalizedQuery(const std::map <std::string, std::string> &params)const;
std::shared_ptr<CredentialsProvider> credentialsProvider_;
std::shared_ptr<Signer> signer_;
};
}
#endif // !ALIBABACLOUD_CORE_RPCSERVICECLIENT_H_
RpcServiceClient(const std::string & servicename,
const std::shared_ptr<CredentialsProvider> &credentialsProvider,
const ClientConfiguration &configuration,
const std::shared_ptr<Signer> &signer =
std::make_shared<HmacSha1Signer>());
virtual ~RpcServiceClient();
std::shared_ptr<CredentialsProvider> credentialsProvider() {
return credentialsProvider_;
}
using CoreClient::configuration;
using CoreClient::AttemptRequest;
protected:
virtual JsonOutcome makeRequest(const std::string &endpoint,
const RpcServiceRequest &msg, HttpRequest::Method method =
HttpRequest::Method::Get) const;
HttpRequest buildHttpRequest(const std::string & endpoint,
const ServiceRequest &msg, HttpRequest::Method method)const override;
HttpRequest buildHttpRequest(const std::string & endpoint,
const RpcServiceRequest &msg, HttpRequest::Method method)const;
private:
std::shared_ptr<CredentialsProvider> credentialsProvider_;
std::shared_ptr<Signer> signer_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_RPCSERVICECLIENT_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,23 +14,24 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_RPCSERVICEREQUEST_H_
#define ALIBABACLOUD_CORE_RPCSERVICEREQUEST_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_RPCSERVICEREQUEST_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_RPCSERVICEREQUEST_H_
#include "ServiceRequest.h"
#include <string>
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT RpcServiceRequest : public ServiceRequest
{
public:
RpcServiceRequest(const std::string &product, const std::string &version, const std::string & action);
virtual ~RpcServiceRequest();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT RpcServiceRequest : public ServiceRequest {
public:
RpcServiceRequest(const std::string &product, const std::string &version,
const std::string & action);
virtual ~RpcServiceRequest();
std::string actionName()const;
protected:
void setActionName(const std::string &name);
std::string actionName()const;
using ServiceRequest::setScheme;
};
}
#endif // !ALIBABACLOUD_CORE_RPCSERVICEREQUEST_H_
protected:
void setActionName(const std::string &name);
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_RPCSERVICEREQUEST_H_

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
* Copyright 1999-2019 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.
@@ -14,22 +14,20 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_RUNNABLE_H_
#define ALIBABACLOUD_CORE_RUNNABLE_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_RUNNABLE_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_RUNNABLE_H_
#include <functional>
#include "CoreExport.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT Runnable
{
public:
explicit Runnable(const std::function<void()> f);
void run()const;
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT Runnable {
public:
explicit Runnable(const std::function<void()> f);
void run()const;
private:
std::function<void()> f_;
};
}
#endif // !ALIBABACLOUD_CORE_RUNNABLE_H_
private:
std::function<void()> f_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_RUNNABLE_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,55 +14,61 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_SERVICEREQUEST_H_
#define ALIBABACLOUD_CORE_SERVICEREQUEST_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_SERVICEREQUEST_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_SERVICEREQUEST_H_
#include <map>
#include "CoreExport.h"
#include "Url.h"
#include <string>
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT ServiceRequest
{
public:
typedef std::string ParameterNameType;
typedef std::string ParameterValueType;
typedef std::map<ParameterNameType, ParameterValueType> ParameterCollection;
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT ServiceRequest {
public:
typedef std::string ParameterNameType;
typedef std::string ParameterValueType;
typedef std::map<ParameterNameType, ParameterValueType> ParameterCollection;
virtual ~ServiceRequest();
virtual ~ServiceRequest();
const char* content()const;
size_t contentSize()const;
bool hasContent()const;
ParameterCollection parameters()const;
std::string product()const;
std::string resourcePath()const;
std::string version()const;
protected:
ServiceRequest(const std::string &product, const std::string &version);
ServiceRequest(const ServiceRequest &other);
ServiceRequest(ServiceRequest &&other);
ServiceRequest& operator=(const ServiceRequest &other);
ServiceRequest& operator=(ServiceRequest &&other);
const char* content() const;
size_t contentSize() const;
bool hasContent() const;
ParameterCollection parameters() const;
std::string product() const;
std::string resourcePath() const;
std::string version() const;
std::string scheme() const;
void addParameter(const ParameterNameType &name, const ParameterValueType &value);
ParameterValueType parameter(const ParameterNameType &name)const;
void removeParameter(const ParameterNameType &name);
void setContent(const char *data, size_t size);
void setParameter(const ParameterNameType &name, const ParameterValueType &value);
void setParameters(const ParameterCollection &params);
void setResourcePath(const std::string &path);
void setProduct(const std::string &product);
void setVersion(const std::string &version);
private:
char *content_;
size_t contentSize_;
ParameterCollection params_;
std::string product_;
std::string resourcePath_;
std::string version_;
};
}
protected:
ServiceRequest(const std::string &product, const std::string &version);
ServiceRequest(const ServiceRequest &other);
ServiceRequest(ServiceRequest &&other);
ServiceRequest& operator=(const ServiceRequest &other);
ServiceRequest& operator=(ServiceRequest &&other);
#endif // !ALIBABACLOUD_CORE_SERVICEREQUEST_H_
void addParameter(const ParameterNameType &name,
const ParameterValueType &value);
ParameterValueType parameter(const ParameterNameType &name) const;
void removeParameter(const ParameterNameType &name);
void setContent(const char *data, size_t size);
void setParameter(const ParameterNameType &name,
const ParameterValueType &value);
void setParameters(const ParameterCollection &params);
void setResourcePath(const std::string &path);
void setProduct(const std::string &product);
void setVersion(const std::string &version);
void setScheme(const std::string scheme);
private:
char *content_;
size_t contentSize_;
ParameterCollection params_;
std::string product_;
std::string resourcePath_;
std::string version_;
std::string scheme_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_SERVICEREQUEST_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,27 +14,27 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_SERVICERESULT_H_
#define ALIBABACLOUD_CORE_SERVICERESULT_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_SERVICERESULT_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_SERVICERESULT_H_
#include <string>
#include "CoreExport.h"
namespace AlibabaCloud
{
class PayloadReader;
class ALIBABACLOUD_CORE_EXPORT ServiceResult
{
public:
ServiceResult();
virtual ~ServiceResult();
namespace AlibabaCloud {
class PayloadReader;
class ALIBABACLOUD_CORE_EXPORT ServiceResult {
public:
ServiceResult();
virtual ~ServiceResult();
std::string requestId()const;
protected:
void setRequestId(const std::string &requestId);
private:
std::string requestId_;
};
}
std::string requestId()const;
#endif // !ALIBABACLOUD_CORE_SERVICERESULT_H_
protected:
void setRequestId(const std::string &requestId);
private:
std::string requestId_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_SERVICERESULT_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,33 +14,34 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_SIGNER_H_
#define ALIBABACLOUD_CORE_SIGNER_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_SIGNER_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_SIGNER_H_
#include <string>
#include "CoreExport.h"
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT Signer
{
public:
enum Type
{
HmacSha1,
};
virtual ~Signer();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT Signer {
public:
enum Type {
HmacSha1,
};
virtual ~Signer();
virtual std::string generate(const std::string &src, const std::string &secret)const = 0;
std::string name()const;
Type type() const;
std::string version()const;
protected:
Signer(Type type, const std::string &name, const std::string &version = "1.0");
private:
std::string name_;
std::string version_;
Type type_;
};
}
#endif // !ALIBABACLOUD_CORE_SIGNER_H_
virtual std::string generate(const std::string &src,
const std::string &secret)const = 0;
std::string name()const;
Type type() const;
std::string version()const;
protected:
Signer(Type type, const std::string &name,
const std::string &version = "1.0");
private:
std::string name_;
std::string version_;
Type type_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_SIGNER_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,24 +14,25 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_SIMPLECREDENTIALSPROVIDER_H_
#define ALIBABACLOUD_CORE_SIMPLECREDENTIALSPROVIDER_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_SIMPLECREDENTIALSPROVIDER_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_SIMPLECREDENTIALSPROVIDER_H_
#include "CredentialsProvider.h"
#include <string>
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT SimpleCredentialsProvider : public CredentialsProvider
{
public:
SimpleCredentialsProvider(const Credentials &credentials);
SimpleCredentialsProvider(const std::string &accessKeyId,
const std::string &accessKeySecret);
~SimpleCredentialsProvider();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT SimpleCredentialsProvider
: public CredentialsProvider {
public:
explicit SimpleCredentialsProvider(const Credentials &credentials);
SimpleCredentialsProvider(const std::string &accessKeyId,
const std::string &accessKeySecret);
~SimpleCredentialsProvider();
virtual Credentials getCredentials() override;
private:
Credentials credentials_;
};
}
#endif // !ALIBABACLOUD_CORE_SIMPLECREDENTIALSPROVIDER_H_
Credentials getCredentials() override;
private:
Credentials credentials_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_SIMPLECREDENTIALSPROVIDER_H_

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
* Copyright 1999-2019 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.
@@ -14,39 +14,42 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_STS_STSASSUMEROLECREDENTIALSPROVIDER_H_
#define ALIBABACLOUD_STS_STSASSUMEROLECREDENTIALSPROVIDER_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_STSASSUMEROLECREDENTIALSPROVIDER_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_STSASSUMEROLECREDENTIALSPROVIDER_H_
#include <chrono>
#include <mutex>
#include <alibabacloud/core/CredentialsProvider.h>
#include <alibabacloud/core/sts/StsClient.h>
#include <chrono>
#include <mutex>
#include <string>
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT StsAssumeRoleCredentialsProvider : public CredentialsProvider
{
public:
StsAssumeRoleCredentialsProvider(const std::shared_ptr<Sts::StsClient>& stsClient,
const std::string &roleArn,
const std::string &roleSessionName,
const std::string &policy = "",
int durationSeconds = 3600);
~StsAssumeRoleCredentialsProvider();
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT StsAssumeRoleCredentialsProvider
: public CredentialsProvider, public Sts::StsClient {
public:
StsAssumeRoleCredentialsProvider(
const Credentials &credentials,
const ClientConfiguration &configuration,
const std::string &roleArn,
const std::string &roleSessionName,
const std::string &policy = "",
int durationSeconds = 3600);
~StsAssumeRoleCredentialsProvider();
virtual Credentials getCredentials() override;
private:
void loadCredentials();
bool checkExpiry()const;
Credentials getCredentials() override;
using StsClient::assumeRole;
std::mutex cachedMutex_;
Credentials cachedCredentials_;
std::shared_ptr<Sts::StsClient> stsClient_;
int durationSeconds_;
std::chrono::system_clock::time_point expiry_;
std::string policy_;
std::string roleArn_;
std::string roleSessionName_;
};
}
#endif // !ALIBABACLOUD_CORE_STSASSUMEROLECREDENTIALSPROVIDER_H_
private:
void loadCredentials();
bool checkExpiry()const;
std::mutex cachedMutex_;
Credentials cachedCredentials_;
int durationSeconds_;
std::chrono::system_clock::time_point expiry_;
std::string policy_;
std::string roleArn_;
std::string roleSessionName_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_STSASSUMEROLECREDENTIALSPROVIDER_H_

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Copyright 1999-2019 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.
@@ -14,62 +14,61 @@
* limitations under the License.
*/
#ifndef ALIBABACLOUD_CORE_URL_H_
#define ALIBABACLOUD_CORE_URL_H_
#ifndef CORE_INCLUDE_ALIBABACLOUD_CORE_URL_H_
#define CORE_INCLUDE_ALIBABACLOUD_CORE_URL_H_
#include <string>
#include "CoreExport.h"
#include <string>
namespace AlibabaCloud
{
class ALIBABACLOUD_CORE_EXPORT Url
{
public:
explicit Url(const std::string &url = "");
Url(const Url &other) = default;
Url(Url &&other) = default;
~Url();
Url & operator=(const Url &url) = default;
Url & operator=(Url &&other) = default;
bool operator==(const Url &url) const;
bool operator!=(const Url &url) const;
namespace AlibabaCloud {
class ALIBABACLOUD_CORE_EXPORT Url {
public:
explicit Url(const std::string &url = "");
Url(const Url &other) = default;
Url(Url &&other) = default;
~Url();
Url & operator=(const Url &url) = default;
Url & operator=(Url &&other) = default;
bool operator==(const Url &url) const;
bool operator!=(const Url &url) const;
std::string authority() const;
void clear();
std::string fragment() const;
void fromString(const std::string &url);
bool hasFragment() const;
bool hasQuery() const;
std::string host()const;
bool isEmpty() const;
bool isValid() const;
int port()const;
std::string password() const;
std::string path() const;
std::string query() const;
std::string scheme() const;
void setAuthority(const std::string &authority);
void setFragment(const std::string &fragment);
void setHost(const std::string &host);
void setPassword(const std::string &password);
void setPath(const std::string &path);
void setPort(int port);
void setQuery(const std::string &query);
void setScheme(const std::string &scheme);
void setUserInfo(const std::string &userInfo);
void setUserName(const std::string &userName);
std::string toString()const;
std::string userInfo() const;
std::string userName() const;
private:
std::string scheme_;
std::string userName_;
std::string password_;
std::string host_;
std::string path_;
int port_;
std::string query_;
std::string fragment_;
};
}
#endif // !ALIBABACLOUD_CORE_URL_H_
std::string authority() const;
void clear();
std::string fragment() const;
void fromString(const std::string &url);
bool hasFragment() const;
bool hasQuery() const;
std::string host()const;
bool isEmpty() const;
bool isValid() const;
int port()const;
std::string password() const;
std::string path() const;
std::string query() const;
std::string scheme() const;
void setAuthority(const std::string &authority);
void setFragment(const std::string &fragment);
void setHost(const std::string &host);
void setPassword(const std::string &password);
void setPath(const std::string &path);
void setPort(int port);
void setQuery(const std::string &query);
void setScheme(const std::string &scheme);
void setUserInfo(const std::string &userInfo);
void setUserName(const std::string &userName);
std::string toString() const;
std::string userInfo() const;
std::string userName() const;
private:
std::string scheme_;
std::string userName_;
std::string password_;
std::string host_;
std::string path_;
int port_;
std::string query_;
std::string fragment_;
};
} // namespace AlibabaCloud
#endif // CORE_INCLUDE_ALIBABACLOUD_CORE_URL_H_

Some files were not shown because too many files have changed in this diff Show More