Compare commits
267 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
055e9fa24d | ||
|
|
779a64ae99 | ||
|
|
689a48e2ef | ||
|
|
c32d539146 | ||
|
|
348726cb09 | ||
|
|
5edf5643a2 | ||
|
|
5cdab50afe | ||
|
|
cb3e058f3f | ||
|
|
e2c46d1143 | ||
|
|
3b852794f3 | ||
|
|
16d6566bf7 | ||
|
|
2758ad51c0 | ||
|
|
51939b77c4 | ||
|
|
3f0e3c3e9a | ||
|
|
c13c576175 | ||
|
|
ef4cdc8756 | ||
|
|
61a4b220eb | ||
|
|
183190fd14 | ||
|
|
a7841818f4 | ||
|
|
9c795d127b | ||
|
|
52c309ecd7 | ||
|
|
d00f8d0fb2 | ||
|
|
4393e6e44f | ||
|
|
e676e2e38f | ||
|
|
429d57cff4 | ||
|
|
179314c9fe | ||
|
|
f0133be6a9 | ||
|
|
bb7cab374e | ||
|
|
66cb681daa | ||
|
|
e2d298dba8 | ||
|
|
ce74411ad3 | ||
|
|
bb1c3193e8 | ||
|
|
ed4f7ee25b | ||
|
|
351c9e254f | ||
|
|
cfd6b2d640 | ||
|
|
ba5ab1093f | ||
|
|
4b90751575 | ||
|
|
a6e6fc3981 | ||
|
|
ac4e846136 | ||
|
|
b88765a938 | ||
|
|
776d68f0aa | ||
|
|
1f76e81f67 | ||
|
|
1c261b822a | ||
|
|
23eaeedb69 | ||
|
|
87f3f72876 | ||
|
|
44c9ab5768 | ||
|
|
ff4508956b | ||
|
|
0329dcee47 | ||
|
|
8f4a119a7e | ||
|
|
63bf0ee442 | ||
|
|
47cb3f0fcb | ||
|
|
776a55cf64 | ||
|
|
5fcbeb4782 | ||
|
|
ea1c1ae17e | ||
|
|
b91b263fdd | ||
|
|
e532f5fe74 | ||
|
|
c1c37ba49a | ||
|
|
7d74c183f6 | ||
|
|
1b9c5d6a42 | ||
|
|
e762c1d057 | ||
|
|
16843433e4 | ||
|
|
f80621c4a4 | ||
|
|
4985a32853 | ||
|
|
7f6b7dbfba | ||
|
|
18b7bafcd0 | ||
|
|
4b9242545b | ||
|
|
b3758c1857 | ||
|
|
40e28f2005 | ||
|
|
2e0f1478c6 | ||
|
|
8c7efaba0f | ||
|
|
fd5e85ebf9 | ||
|
|
ef538b5d54 | ||
|
|
4e92d5b648 | ||
|
|
befcff9add | ||
|
|
78426b2c35 | ||
|
|
1c37d47f07 | ||
|
|
afc1ac57c3 | ||
|
|
7ad42a297f | ||
|
|
b2cade322d | ||
|
|
5d8d514785 | ||
|
|
d4d30d5bb7 | ||
|
|
8c606d0357 | ||
|
|
4a7816979a | ||
|
|
ca3378ac03 | ||
|
|
0859b911b2 | ||
|
|
29b4bc0ce3 | ||
|
|
d37523f568 | ||
|
|
928fc975b9 | ||
|
|
6365b9f02d | ||
|
|
fbc3817ea1 | ||
|
|
db6a17b08c | ||
|
|
d80ca0d7e2 | ||
|
|
83f9047345 | ||
|
|
458e22b006 | ||
|
|
a375fa9d99 | ||
|
|
c8d90808f0 | ||
|
|
886cef155f | ||
|
|
051077c805 | ||
|
|
589d7c0177 | ||
|
|
22313c7d61 | ||
|
|
192ded93b1 | ||
|
|
dde68d8a28 | ||
|
|
b299d10992 | ||
|
|
5c871c6dcd | ||
|
|
3312e299ac | ||
|
|
60bb031e74 | ||
|
|
d74432d350 | ||
|
|
7ddae594ab | ||
|
|
3a727a7cb8 | ||
|
|
c0327a8b18 | ||
|
|
283dc6d360 | ||
|
|
212db1e32d | ||
|
|
d733a6db40 | ||
|
|
3177214fec | ||
|
|
805659acd5 | ||
|
|
0b54cf98a5 | ||
|
|
cbe97f842a | ||
|
|
ac7c0da065 | ||
|
|
b7792b239d | ||
|
|
e6bf769f7c | ||
|
|
a869263856 | ||
|
|
863030766c | ||
|
|
7a6b431ace | ||
|
|
c70caca128 | ||
|
|
09d6015e09 | ||
|
|
39478f1c33 | ||
|
|
e95083301e | ||
|
|
e98b3a0c80 | ||
|
|
6950861a84 | ||
|
|
92ffb966bd | ||
|
|
179726e2c2 | ||
|
|
0683d0188a | ||
|
|
2034a7ce61 | ||
|
|
46f59d340b | ||
|
|
fc0ca83c5e | ||
|
|
046fa0c8a7 | ||
|
|
6e394508b1 | ||
|
|
2cf2c1a693 | ||
|
|
2655b67ecf | ||
|
|
811dc06c78 | ||
|
|
062ac6c53a | ||
|
|
c5710477dc | ||
|
|
4970164a9f | ||
|
|
ae139aef77 | ||
|
|
06af2542bd | ||
|
|
150f012d41 | ||
|
|
b618f90905 | ||
|
|
005a84c9f4 | ||
|
|
5df7719b65 | ||
|
|
419d2ef5e8 | ||
|
|
04d98c2083 | ||
|
|
b3b1f59165 | ||
|
|
1308f2904e | ||
|
|
1c75989037 | ||
|
|
2d2d1e86d9 | ||
|
|
43b055ce70 | ||
|
|
6eb45b0747 | ||
|
|
1ff4eb0f4c | ||
|
|
0fa981b589 | ||
|
|
31b4d82c33 | ||
|
|
a6e305285a | ||
|
|
82e7652c01 | ||
|
|
c2475a651e | ||
|
|
a137d01a2d | ||
|
|
8c76154f4f | ||
|
|
1380c5890f | ||
|
|
ed952131e7 | ||
|
|
220fbacfa2 | ||
|
|
26ec339ba4 | ||
|
|
977bef47bf | ||
|
|
1f167df35d | ||
|
|
4b4f526887 | ||
|
|
784a67c71a | ||
|
|
1333c0ead7 | ||
|
|
4ec4f4488c | ||
|
|
34dd2572f1 | ||
|
|
6f8776cbe1 | ||
|
|
4ec1c844d0 | ||
|
|
ee2f3a43cf | ||
|
|
0d265770f7 | ||
|
|
e9cb30aad0 | ||
|
|
1db5817d99 | ||
|
|
c5a4e342b2 | ||
|
|
d3f6835294 | ||
|
|
26eb8b61f6 | ||
|
|
ecae0a8927 | ||
|
|
61a7ba5e1b | ||
|
|
377504fe8a | ||
|
|
1884db41cf | ||
|
|
2345df949e | ||
|
|
a635c9380f | ||
|
|
41d6a4f6e3 | ||
|
|
3eaac1a328 | ||
|
|
fe741d3fe9 | ||
|
|
6e83ebf540 | ||
|
|
175bcdf71a | ||
|
|
625c854f5d | ||
|
|
0755e147eb | ||
|
|
9b0be63347 | ||
|
|
e9e64ef7f1 | ||
|
|
0c9e78e25d | ||
|
|
144aaf2401 | ||
|
|
f9603e792e | ||
|
|
b8b197b741 | ||
|
|
2344a2c7cc | ||
|
|
217a9b18ed | ||
|
|
78f4dae59d | ||
|
|
55bf08e936 | ||
|
|
996847f7aa | ||
|
|
d24791dc62 | ||
|
|
1fa00fa025 | ||
|
|
d0b781c4c5 | ||
|
|
e922990dbc | ||
|
|
07d1480059 | ||
|
|
a0e90cc606 | ||
|
|
d93b632d3b | ||
|
|
6cbb9bf950 | ||
|
|
752399d8fa | ||
|
|
15f0e363ca | ||
|
|
1637cf567e | ||
|
|
28732a4b06 | ||
|
|
c94a2b34a1 | ||
|
|
436e293e96 | ||
|
|
518c2f8c75 | ||
|
|
d486290c14 | ||
|
|
2b84cadd9d | ||
|
|
879e8b9359 | ||
|
|
005ea30e5d | ||
|
|
fa259f93ff | ||
|
|
0f77f88873 | ||
|
|
cf3bbdf2ba | ||
|
|
708bcbb678 | ||
|
|
70dddee991 | ||
|
|
096bedd0df | ||
|
|
b6d2db14fe | ||
|
|
8fc9b8125b | ||
|
|
a16636b8bd | ||
|
|
2c0d297a8d | ||
|
|
f0d0ef6cd0 | ||
|
|
11136905db | ||
|
|
5c4cdd976d | ||
|
|
760426f29b | ||
|
|
99697bde91 | ||
|
|
1b19d44bc2 | ||
|
|
84ae3ef04e | ||
|
|
bb8790e63c | ||
|
|
d75a986e9f | ||
|
|
ef568baa30 | ||
|
|
2eae2fe5c9 | ||
|
|
a4995661a5 | ||
|
|
7eb4574903 | ||
|
|
5021fa7e0a | ||
|
|
71e4c1576e | ||
|
|
5550c66a4c | ||
|
|
9c47520d45 | ||
|
|
9b6827d238 | ||
|
|
2d60eb1a66 | ||
|
|
a3c08aa6f7 | ||
|
|
df9aacc5a5 | ||
|
|
d209714cb0 | ||
|
|
3cee194b0f | ||
|
|
c52c445fa1 | ||
|
|
4f8cf9d05f | ||
|
|
8d13c48cce | ||
|
|
be6c27326e | ||
|
|
197159f97b | ||
|
|
e788fcb800 |
21
.github/workflows/test.yaml
vendored
Normal file
21
.github/workflows/test.yaml
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
name: Test
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ master ]
|
||||
pull_request:
|
||||
branches: [ master ]
|
||||
|
||||
jobs:
|
||||
test:
|
||||
runs-on: ubuntu-latest
|
||||
name: CPP
|
||||
env:
|
||||
CPLUS_INCLUDE_PATH: "/usr/local/include/:/usr/include/jsoncpp/:/usr/local/opt/openssl/include/:/usr/lib/"
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- run: sudo apt-get install lcov libcurl4-openssl-dev libssl-dev uuid-dev libjson-c-dev libjsoncpp-dev nodejs npm
|
||||
- run: bash ./unit_test.sh
|
||||
- run: bash ./generate_code_cov.sh
|
||||
- run: bash ./function_test.sh
|
||||
- run: bash <(curl -s https://codecov.io/bash)
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -14,3 +14,4 @@ test/httpserver/nohup.out
|
||||
.idea
|
||||
build/
|
||||
cmake-build-debug/
|
||||
.DS_Store
|
||||
@@ -46,7 +46,7 @@ Alibaba Cloud SDK for C++ 让您不用复杂编程即可访问云服务器、负
|
||||
|
||||
```bash
|
||||
# use yum
|
||||
yum install jsoncpp-devel openssl-devel uuid-devel libcurl-devel
|
||||
yum install jsoncpp-devel openssl-devel libuuid-devel libcurl-devel
|
||||
|
||||
# use dnf
|
||||
sudo dnf install libcurl-devel openssl-devel libuuid-devel libjsoncpp-devel
|
||||
|
||||
@@ -47,7 +47,7 @@ If you have any problem while using Alibaba Cloud SDK for C++, please submit an
|
||||
|
||||
```bash
|
||||
# use yum
|
||||
yum install jsoncpp-devel openssl-devel uuid-devel libcurl-devel
|
||||
yum install jsoncpp-devel openssl-devel libuuid-devel libcurl-devel
|
||||
|
||||
# use dnf
|
||||
sudo dnf install libcurl-devel openssl-devel libuuid-devel libjsoncpp-devel
|
||||
|
||||
102
accountlabel/CMakeLists.txt
Normal file
102
accountlabel/CMakeLists.txt
Normal file
@@ -0,0 +1,102 @@
|
||||
#
|
||||
# Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
set(public_header_dir ${CMAKE_CURRENT_SOURCE_DIR}/../include)
|
||||
|
||||
set(accountlabel_public_header
|
||||
include/alibabacloud/accountlabel/AccountLabelClient.h
|
||||
include/alibabacloud/accountlabel/AccountLabelExport.h )
|
||||
|
||||
set(accountlabel_public_header_model
|
||||
include/alibabacloud/accountlabel/model/AddCustomerLabelRequest.h
|
||||
include/alibabacloud/accountlabel/model/AddCustomerLabelResult.h
|
||||
include/alibabacloud/accountlabel/model/BatchFetchAccountLabelRequest.h
|
||||
include/alibabacloud/accountlabel/model/BatchFetchAccountLabelResult.h
|
||||
include/alibabacloud/accountlabel/model/DeleteCustomerLabelRequest.h
|
||||
include/alibabacloud/accountlabel/model/DeleteCustomerLabelResult.h
|
||||
include/alibabacloud/accountlabel/model/QueryCustomerLabelRequest.h
|
||||
include/alibabacloud/accountlabel/model/QueryCustomerLabelResult.h
|
||||
include/alibabacloud/accountlabel/model/QueryCustomerLabelByConfigGroupRequest.h
|
||||
include/alibabacloud/accountlabel/model/QueryCustomerLabelByConfigGroupResult.h )
|
||||
|
||||
set(accountlabel_src
|
||||
src/AccountLabelClient.cc
|
||||
src/model/AddCustomerLabelRequest.cc
|
||||
src/model/AddCustomerLabelResult.cc
|
||||
src/model/BatchFetchAccountLabelRequest.cc
|
||||
src/model/BatchFetchAccountLabelResult.cc
|
||||
src/model/DeleteCustomerLabelRequest.cc
|
||||
src/model/DeleteCustomerLabelResult.cc
|
||||
src/model/QueryCustomerLabelRequest.cc
|
||||
src/model/QueryCustomerLabelResult.cc
|
||||
src/model/QueryCustomerLabelByConfigGroupRequest.cc
|
||||
src/model/QueryCustomerLabelByConfigGroupResult.cc )
|
||||
|
||||
add_library(accountlabel ${LIB_TYPE}
|
||||
${accountlabel_public_header}
|
||||
${accountlabel_public_header_model}
|
||||
${accountlabel_src})
|
||||
|
||||
set_target_properties(accountlabel
|
||||
PROPERTIES
|
||||
LINKER_LANGUAGE CXX
|
||||
ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
|
||||
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
|
||||
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
|
||||
OUTPUT_NAME ${TARGET_OUTPUT_NAME_PREFIX}accountlabel
|
||||
)
|
||||
|
||||
if(${LIB_TYPE} STREQUAL "SHARED")
|
||||
set_target_properties(accountlabel
|
||||
PROPERTIES
|
||||
DEFINE_SYMBOL ALIBABACLOUD_ACCOUNTLABEL_LIBRARY)
|
||||
endif()
|
||||
|
||||
target_include_directories(accountlabel
|
||||
PRIVATE include
|
||||
${CMAKE_SOURCE_DIR}/core/include
|
||||
)
|
||||
target_link_libraries(accountlabel
|
||||
core)
|
||||
|
||||
if(CMAKE_HOST_WIN32)
|
||||
ExternalProject_Get_Property(jsoncpp INSTALL_DIR)
|
||||
set(jsoncpp_install_dir ${INSTALL_DIR})
|
||||
add_dependencies(accountlabel
|
||||
jsoncpp)
|
||||
target_include_directories(accountlabel
|
||||
PRIVATE ${jsoncpp_install_dir}/include)
|
||||
target_link_libraries(accountlabel
|
||||
${jsoncpp_install_dir}/lib/jsoncpp.lib)
|
||||
set_target_properties(accountlabel
|
||||
PROPERTIES
|
||||
COMPILE_OPTIONS "/bigobj")
|
||||
else()
|
||||
target_include_directories(accountlabel
|
||||
PRIVATE /usr/include/jsoncpp)
|
||||
target_link_libraries(accountlabel
|
||||
jsoncpp)
|
||||
endif()
|
||||
|
||||
install(FILES ${accountlabel_public_header}
|
||||
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/accountlabel)
|
||||
install(FILES ${accountlabel_public_header_model}
|
||||
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/accountlabel/model)
|
||||
install(TARGETS accountlabel
|
||||
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
|
||||
)
|
||||
@@ -0,0 +1,86 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_ACCOUNTLABELCLIENT_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_ACCOUNTLABELCLIENT_H_
|
||||
|
||||
#include <future>
|
||||
#include <alibabacloud/core/AsyncCallerContext.h>
|
||||
#include <alibabacloud/core/EndpointProvider.h>
|
||||
#include <alibabacloud/core/RpcServiceClient.h>
|
||||
#include "AccountLabelExport.h"
|
||||
#include "model/AddCustomerLabelRequest.h"
|
||||
#include "model/AddCustomerLabelResult.h"
|
||||
#include "model/BatchFetchAccountLabelRequest.h"
|
||||
#include "model/BatchFetchAccountLabelResult.h"
|
||||
#include "model/DeleteCustomerLabelRequest.h"
|
||||
#include "model/DeleteCustomerLabelResult.h"
|
||||
#include "model/QueryCustomerLabelRequest.h"
|
||||
#include "model/QueryCustomerLabelResult.h"
|
||||
#include "model/QueryCustomerLabelByConfigGroupRequest.h"
|
||||
#include "model/QueryCustomerLabelByConfigGroupResult.h"
|
||||
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AccountLabel
|
||||
{
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT AccountLabelClient : public RpcServiceClient
|
||||
{
|
||||
public:
|
||||
typedef Outcome<Error, Model::AddCustomerLabelResult> AddCustomerLabelOutcome;
|
||||
typedef std::future<AddCustomerLabelOutcome> AddCustomerLabelOutcomeCallable;
|
||||
typedef std::function<void(const AccountLabelClient*, const Model::AddCustomerLabelRequest&, const AddCustomerLabelOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> AddCustomerLabelAsyncHandler;
|
||||
typedef Outcome<Error, Model::BatchFetchAccountLabelResult> BatchFetchAccountLabelOutcome;
|
||||
typedef std::future<BatchFetchAccountLabelOutcome> BatchFetchAccountLabelOutcomeCallable;
|
||||
typedef std::function<void(const AccountLabelClient*, const Model::BatchFetchAccountLabelRequest&, const BatchFetchAccountLabelOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> BatchFetchAccountLabelAsyncHandler;
|
||||
typedef Outcome<Error, Model::DeleteCustomerLabelResult> DeleteCustomerLabelOutcome;
|
||||
typedef std::future<DeleteCustomerLabelOutcome> DeleteCustomerLabelOutcomeCallable;
|
||||
typedef std::function<void(const AccountLabelClient*, const Model::DeleteCustomerLabelRequest&, const DeleteCustomerLabelOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DeleteCustomerLabelAsyncHandler;
|
||||
typedef Outcome<Error, Model::QueryCustomerLabelResult> QueryCustomerLabelOutcome;
|
||||
typedef std::future<QueryCustomerLabelOutcome> QueryCustomerLabelOutcomeCallable;
|
||||
typedef std::function<void(const AccountLabelClient*, const Model::QueryCustomerLabelRequest&, const QueryCustomerLabelOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryCustomerLabelAsyncHandler;
|
||||
typedef Outcome<Error, Model::QueryCustomerLabelByConfigGroupResult> QueryCustomerLabelByConfigGroupOutcome;
|
||||
typedef std::future<QueryCustomerLabelByConfigGroupOutcome> QueryCustomerLabelByConfigGroupOutcomeCallable;
|
||||
typedef std::function<void(const AccountLabelClient*, const Model::QueryCustomerLabelByConfigGroupRequest&, const QueryCustomerLabelByConfigGroupOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryCustomerLabelByConfigGroupAsyncHandler;
|
||||
|
||||
AccountLabelClient(const Credentials &credentials, const ClientConfiguration &configuration);
|
||||
AccountLabelClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider, const ClientConfiguration &configuration);
|
||||
AccountLabelClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration);
|
||||
~AccountLabelClient();
|
||||
AddCustomerLabelOutcome addCustomerLabel(const Model::AddCustomerLabelRequest &request)const;
|
||||
void addCustomerLabelAsync(const Model::AddCustomerLabelRequest& request, const AddCustomerLabelAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
AddCustomerLabelOutcomeCallable addCustomerLabelCallable(const Model::AddCustomerLabelRequest& request) const;
|
||||
BatchFetchAccountLabelOutcome batchFetchAccountLabel(const Model::BatchFetchAccountLabelRequest &request)const;
|
||||
void batchFetchAccountLabelAsync(const Model::BatchFetchAccountLabelRequest& request, const BatchFetchAccountLabelAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
BatchFetchAccountLabelOutcomeCallable batchFetchAccountLabelCallable(const Model::BatchFetchAccountLabelRequest& request) const;
|
||||
DeleteCustomerLabelOutcome deleteCustomerLabel(const Model::DeleteCustomerLabelRequest &request)const;
|
||||
void deleteCustomerLabelAsync(const Model::DeleteCustomerLabelRequest& request, const DeleteCustomerLabelAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DeleteCustomerLabelOutcomeCallable deleteCustomerLabelCallable(const Model::DeleteCustomerLabelRequest& request) const;
|
||||
QueryCustomerLabelOutcome queryCustomerLabel(const Model::QueryCustomerLabelRequest &request)const;
|
||||
void queryCustomerLabelAsync(const Model::QueryCustomerLabelRequest& request, const QueryCustomerLabelAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
QueryCustomerLabelOutcomeCallable queryCustomerLabelCallable(const Model::QueryCustomerLabelRequest& request) const;
|
||||
QueryCustomerLabelByConfigGroupOutcome queryCustomerLabelByConfigGroup(const Model::QueryCustomerLabelByConfigGroupRequest &request)const;
|
||||
void queryCustomerLabelByConfigGroupAsync(const Model::QueryCustomerLabelByConfigGroupRequest& request, const QueryCustomerLabelByConfigGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
QueryCustomerLabelByConfigGroupOutcomeCallable queryCustomerLabelByConfigGroupCallable(const Model::QueryCustomerLabelByConfigGroupRequest& request) const;
|
||||
|
||||
private:
|
||||
std::shared_ptr<EndpointProvider> endpointProvider_;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_ACCOUNTLABELCLIENT_H_
|
||||
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_ACCOUNTLABELEXPORT_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_ACCOUNTLABELEXPORT_H_
|
||||
|
||||
#include <alibabacloud/core/Global.h>
|
||||
|
||||
#if defined(ALIBABACLOUD_SHARED)
|
||||
# if defined(ALIBABACLOUD_ACCOUNTLABEL_LIBRARY)
|
||||
# define ALIBABACLOUD_ACCOUNTLABEL_EXPORT ALIBABACLOUD_DECL_EXPORT
|
||||
# else
|
||||
# define ALIBABACLOUD_ACCOUNTLABEL_EXPORT ALIBABACLOUD_DECL_IMPORT
|
||||
# endif
|
||||
#else
|
||||
# define ALIBABACLOUD_ACCOUNTLABEL_EXPORT
|
||||
#endif
|
||||
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_ACCOUNTLABELEXPORT_H_
|
||||
@@ -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_ACCOUNTLABEL_MODEL_ADDCUSTOMERLABELREQUEST_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_MODEL_ADDCUSTOMERLABELREQUEST_H_
|
||||
|
||||
#include <alibabacloud/accountlabel/AccountLabelExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AccountLabel {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT AddCustomerLabelRequest : public RpcServiceRequest {
|
||||
public:
|
||||
AddCustomerLabelRequest();
|
||||
~AddCustomerLabelRequest();
|
||||
std::string getLabelSeries() const;
|
||||
void setLabelSeries(const std::string &labelSeries);
|
||||
std::string getOrganization() const;
|
||||
void setOrganization(const std::string &organization);
|
||||
std::string getEndtime() const;
|
||||
void setEndtime(const std::string &endtime);
|
||||
long getPK() const;
|
||||
void setPK(long pK);
|
||||
std::string getStartTime() const;
|
||||
void setStartTime(const std::string &startTime);
|
||||
std::vector<std::string> getLabelTypes() const;
|
||||
void setLabelTypes(const std::vector<std::string> &labelTypes);
|
||||
std::string getUserName() const;
|
||||
void setUserName(const std::string &userName);
|
||||
std::string getToken() const;
|
||||
void setToken(const std::string &token);
|
||||
|
||||
private:
|
||||
std::string labelSeries_;
|
||||
std::string organization_;
|
||||
std::string endtime_;
|
||||
long pK_;
|
||||
std::string startTime_;
|
||||
std::vector<std::string> labelTypes_;
|
||||
std::string userName_;
|
||||
std::string token_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AccountLabel
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_MODEL_ADDCUSTOMERLABELREQUEST_H_
|
||||
@@ -0,0 +1,55 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_MODEL_ADDCUSTOMERLABELRESULT_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_MODEL_ADDCUSTOMERLABELRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/accountlabel/AccountLabelExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AccountLabel
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT AddCustomerLabelResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
AddCustomerLabelResult();
|
||||
explicit AddCustomerLabelResult(const std::string &payload);
|
||||
~AddCustomerLabelResult();
|
||||
std::string getMessage()const;
|
||||
std::string getCode()const;
|
||||
bool getSuccess()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
std::string code_;
|
||||
bool success_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_MODEL_ADDCUSTOMERLABELRESULT_H_
|
||||
@@ -0,0 +1,57 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_MODEL_BATCHFETCHACCOUNTLABELREQUEST_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_MODEL_BATCHFETCHACCOUNTLABELREQUEST_H_
|
||||
|
||||
#include <alibabacloud/accountlabel/AccountLabelExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AccountLabel {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT BatchFetchAccountLabelRequest : public RpcServiceRequest {
|
||||
public:
|
||||
BatchFetchAccountLabelRequest();
|
||||
~BatchFetchAccountLabelRequest();
|
||||
std::string getOrganization() const;
|
||||
void setOrganization(const std::string &organization);
|
||||
long getPk() const;
|
||||
void setPk(long pk);
|
||||
std::string getUserName() const;
|
||||
void setUserName(const std::string &userName);
|
||||
bool getInstant() const;
|
||||
void setInstant(bool instant);
|
||||
std::string getToken() const;
|
||||
void setToken(const std::string &token);
|
||||
std::vector<std::string> getLabelSeriesList() const;
|
||||
void setLabelSeriesList(const std::vector<std::string> &labelSeriesList);
|
||||
|
||||
private:
|
||||
std::string organization_;
|
||||
long pk_;
|
||||
std::string userName_;
|
||||
bool instant_;
|
||||
std::string token_;
|
||||
std::vector<std::string> labelSeriesList_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AccountLabel
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_MODEL_BATCHFETCHACCOUNTLABELREQUEST_H_
|
||||
@@ -0,0 +1,70 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_MODEL_BATCHFETCHACCOUNTLABELRESULT_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_MODEL_BATCHFETCHACCOUNTLABELRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/accountlabel/AccountLabelExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AccountLabel
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT BatchFetchAccountLabelResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct AccountLabelInfoDto
|
||||
{
|
||||
std::string labelSeries;
|
||||
long endTime;
|
||||
long kp;
|
||||
long gmtModified;
|
||||
std::string label;
|
||||
long startTime;
|
||||
std::string creator;
|
||||
long gmtCreated;
|
||||
};
|
||||
|
||||
|
||||
BatchFetchAccountLabelResult();
|
||||
explicit BatchFetchAccountLabelResult(const std::string &payload);
|
||||
~BatchFetchAccountLabelResult();
|
||||
std::string getMessage()const;
|
||||
std::vector<AccountLabelInfoDto> getData()const;
|
||||
long getCount()const;
|
||||
std::string getCode()const;
|
||||
bool getSuccess()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
std::vector<AccountLabelInfoDto> data_;
|
||||
long count_;
|
||||
std::string code_;
|
||||
bool success_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_MODEL_BATCHFETCHACCOUNTLABELRESULT_H_
|
||||
@@ -0,0 +1,57 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_MODEL_DELETECUSTOMERLABELREQUEST_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_MODEL_DELETECUSTOMERLABELREQUEST_H_
|
||||
|
||||
#include <alibabacloud/accountlabel/AccountLabelExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AccountLabel {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT DeleteCustomerLabelRequest : public RpcServiceRequest {
|
||||
public:
|
||||
DeleteCustomerLabelRequest();
|
||||
~DeleteCustomerLabelRequest();
|
||||
std::string getLabelSeries() const;
|
||||
void setLabelSeries(const std::string &labelSeries);
|
||||
std::string getOrganization() const;
|
||||
void setOrganization(const std::string &organization);
|
||||
long getPK() const;
|
||||
void setPK(long pK);
|
||||
std::vector<std::string> getLabelTypes() const;
|
||||
void setLabelTypes(const std::vector<std::string> &labelTypes);
|
||||
std::string getUserName() const;
|
||||
void setUserName(const std::string &userName);
|
||||
std::string getToken() const;
|
||||
void setToken(const std::string &token);
|
||||
|
||||
private:
|
||||
std::string labelSeries_;
|
||||
std::string organization_;
|
||||
long pK_;
|
||||
std::vector<std::string> labelTypes_;
|
||||
std::string userName_;
|
||||
std::string token_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AccountLabel
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_MODEL_DELETECUSTOMERLABELREQUEST_H_
|
||||
@@ -0,0 +1,55 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_MODEL_DELETECUSTOMERLABELRESULT_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_MODEL_DELETECUSTOMERLABELRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/accountlabel/AccountLabelExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AccountLabel
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT DeleteCustomerLabelResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
DeleteCustomerLabelResult();
|
||||
explicit DeleteCustomerLabelResult(const std::string &payload);
|
||||
~DeleteCustomerLabelResult();
|
||||
std::string getMessage()const;
|
||||
std::string getCode()const;
|
||||
bool getSuccess()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
std::string code_;
|
||||
bool success_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_MODEL_DELETECUSTOMERLABELRESULT_H_
|
||||
@@ -0,0 +1,48 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELBYCONFIGGROUPREQUEST_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELBYCONFIGGROUPREQUEST_H_
|
||||
|
||||
#include <alibabacloud/accountlabel/AccountLabelExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AccountLabel {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT QueryCustomerLabelByConfigGroupRequest : public RpcServiceRequest {
|
||||
public:
|
||||
QueryCustomerLabelByConfigGroupRequest();
|
||||
~QueryCustomerLabelByConfigGroupRequest();
|
||||
std::string getGroupType() const;
|
||||
void setGroupType(const std::string &groupType);
|
||||
long getPK() const;
|
||||
void setPK(long pK);
|
||||
std::string getToken() const;
|
||||
void setToken(const std::string &token);
|
||||
|
||||
private:
|
||||
std::string groupType_;
|
||||
long pK_;
|
||||
std::string token_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AccountLabel
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELBYCONFIGGROUPREQUEST_H_
|
||||
@@ -0,0 +1,62 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELBYCONFIGGROUPRESULT_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELBYCONFIGGROUPRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/accountlabel/AccountLabelExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AccountLabel
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT QueryCustomerLabelByConfigGroupResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct CustomerLabel
|
||||
{
|
||||
std::string labelSeries;
|
||||
std::string label;
|
||||
};
|
||||
|
||||
|
||||
QueryCustomerLabelByConfigGroupResult();
|
||||
explicit QueryCustomerLabelByConfigGroupResult(const std::string &payload);
|
||||
~QueryCustomerLabelByConfigGroupResult();
|
||||
std::string getMessage()const;
|
||||
std::vector<CustomerLabel> getData()const;
|
||||
std::string getCode()const;
|
||||
bool getSuccess()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
std::vector<CustomerLabel> data_;
|
||||
std::string code_;
|
||||
bool success_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELBYCONFIGGROUPRESULT_H_
|
||||
@@ -0,0 +1,51 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELREQUEST_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELREQUEST_H_
|
||||
|
||||
#include <alibabacloud/accountlabel/AccountLabelExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AccountLabel {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT QueryCustomerLabelRequest : public RpcServiceRequest {
|
||||
public:
|
||||
QueryCustomerLabelRequest();
|
||||
~QueryCustomerLabelRequest();
|
||||
std::string getLabelSeries() const;
|
||||
void setLabelSeries(const std::string &labelSeries);
|
||||
long getPK() const;
|
||||
void setPK(long pK);
|
||||
std::string getToken() const;
|
||||
void setToken(const std::string &token);
|
||||
bool getInstant() const;
|
||||
void setInstant(bool instant);
|
||||
|
||||
private:
|
||||
std::string labelSeries_;
|
||||
long pK_;
|
||||
std::string token_;
|
||||
bool instant_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AccountLabel
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELREQUEST_H_
|
||||
@@ -0,0 +1,62 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELRESULT_H_
|
||||
#define ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/accountlabel/AccountLabelExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AccountLabel
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ACCOUNTLABEL_EXPORT QueryCustomerLabelResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct CustomerLabel
|
||||
{
|
||||
std::string labelSeries;
|
||||
std::string label;
|
||||
};
|
||||
|
||||
|
||||
QueryCustomerLabelResult();
|
||||
explicit QueryCustomerLabelResult(const std::string &payload);
|
||||
~QueryCustomerLabelResult();
|
||||
std::string getMessage()const;
|
||||
std::vector<CustomerLabel> getData()const;
|
||||
std::string getCode()const;
|
||||
bool getSuccess()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
std::vector<CustomerLabel> data_;
|
||||
std::string code_;
|
||||
bool success_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ACCOUNTLABEL_MODEL_QUERYCUSTOMERLABELRESULT_H_
|
||||
233
accountlabel/src/AccountLabelClient.cc
Normal file
233
accountlabel/src/AccountLabelClient.cc
Normal file
@@ -0,0 +1,233 @@
|
||||
/*
|
||||
* 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/accountlabel/AccountLabelClient.h>
|
||||
#include <alibabacloud/core/SimpleCredentialsProvider.h>
|
||||
|
||||
using namespace AlibabaCloud;
|
||||
using namespace AlibabaCloud::Location;
|
||||
using namespace AlibabaCloud::AccountLabel;
|
||||
using namespace AlibabaCloud::AccountLabel::Model;
|
||||
|
||||
namespace
|
||||
{
|
||||
const std::string SERVICE_NAME = "AccountLabel";
|
||||
}
|
||||
|
||||
AccountLabelClient::AccountLabelClient(const Credentials &credentials, const ClientConfiguration &configuration) :
|
||||
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(credentials), configuration)
|
||||
{
|
||||
auto locationClient = std::make_shared<LocationClient>(credentials, configuration);
|
||||
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
|
||||
}
|
||||
|
||||
AccountLabelClient::AccountLabelClient(const std::shared_ptr<CredentialsProvider>& credentialsProvider, const ClientConfiguration & configuration) :
|
||||
RpcServiceClient(SERVICE_NAME, credentialsProvider, configuration)
|
||||
{
|
||||
auto locationClient = std::make_shared<LocationClient>(credentialsProvider, configuration);
|
||||
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
|
||||
}
|
||||
|
||||
AccountLabelClient::AccountLabelClient(const std::string & accessKeyId, const std::string & accessKeySecret, const ClientConfiguration & configuration) :
|
||||
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(accessKeyId, accessKeySecret), configuration)
|
||||
{
|
||||
auto locationClient = std::make_shared<LocationClient>(accessKeyId, accessKeySecret, configuration);
|
||||
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
|
||||
}
|
||||
|
||||
AccountLabelClient::~AccountLabelClient()
|
||||
{}
|
||||
|
||||
AccountLabelClient::AddCustomerLabelOutcome AccountLabelClient::addCustomerLabel(const AddCustomerLabelRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return AddCustomerLabelOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return AddCustomerLabelOutcome(AddCustomerLabelResult(outcome.result()));
|
||||
else
|
||||
return AddCustomerLabelOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AccountLabelClient::addCustomerLabelAsync(const AddCustomerLabelRequest& request, const AddCustomerLabelAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, addCustomerLabel(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AccountLabelClient::AddCustomerLabelOutcomeCallable AccountLabelClient::addCustomerLabelCallable(const AddCustomerLabelRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<AddCustomerLabelOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->addCustomerLabel(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AccountLabelClient::BatchFetchAccountLabelOutcome AccountLabelClient::batchFetchAccountLabel(const BatchFetchAccountLabelRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return BatchFetchAccountLabelOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return BatchFetchAccountLabelOutcome(BatchFetchAccountLabelResult(outcome.result()));
|
||||
else
|
||||
return BatchFetchAccountLabelOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AccountLabelClient::batchFetchAccountLabelAsync(const BatchFetchAccountLabelRequest& request, const BatchFetchAccountLabelAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, batchFetchAccountLabel(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AccountLabelClient::BatchFetchAccountLabelOutcomeCallable AccountLabelClient::batchFetchAccountLabelCallable(const BatchFetchAccountLabelRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<BatchFetchAccountLabelOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->batchFetchAccountLabel(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AccountLabelClient::DeleteCustomerLabelOutcome AccountLabelClient::deleteCustomerLabel(const DeleteCustomerLabelRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DeleteCustomerLabelOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DeleteCustomerLabelOutcome(DeleteCustomerLabelResult(outcome.result()));
|
||||
else
|
||||
return DeleteCustomerLabelOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AccountLabelClient::deleteCustomerLabelAsync(const DeleteCustomerLabelRequest& request, const DeleteCustomerLabelAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, deleteCustomerLabel(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AccountLabelClient::DeleteCustomerLabelOutcomeCallable AccountLabelClient::deleteCustomerLabelCallable(const DeleteCustomerLabelRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DeleteCustomerLabelOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->deleteCustomerLabel(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AccountLabelClient::QueryCustomerLabelOutcome AccountLabelClient::queryCustomerLabel(const QueryCustomerLabelRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return QueryCustomerLabelOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return QueryCustomerLabelOutcome(QueryCustomerLabelResult(outcome.result()));
|
||||
else
|
||||
return QueryCustomerLabelOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AccountLabelClient::queryCustomerLabelAsync(const QueryCustomerLabelRequest& request, const QueryCustomerLabelAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, queryCustomerLabel(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AccountLabelClient::QueryCustomerLabelOutcomeCallable AccountLabelClient::queryCustomerLabelCallable(const QueryCustomerLabelRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<QueryCustomerLabelOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->queryCustomerLabel(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AccountLabelClient::QueryCustomerLabelByConfigGroupOutcome AccountLabelClient::queryCustomerLabelByConfigGroup(const QueryCustomerLabelByConfigGroupRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return QueryCustomerLabelByConfigGroupOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return QueryCustomerLabelByConfigGroupOutcome(QueryCustomerLabelByConfigGroupResult(outcome.result()));
|
||||
else
|
||||
return QueryCustomerLabelByConfigGroupOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AccountLabelClient::queryCustomerLabelByConfigGroupAsync(const QueryCustomerLabelByConfigGroupRequest& request, const QueryCustomerLabelByConfigGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, queryCustomerLabelByConfigGroup(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AccountLabelClient::QueryCustomerLabelByConfigGroupOutcomeCallable AccountLabelClient::queryCustomerLabelByConfigGroupCallable(const QueryCustomerLabelByConfigGroupRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<QueryCustomerLabelByConfigGroupOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->queryCustomerLabelByConfigGroup(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
98
accountlabel/src/model/AddCustomerLabelRequest.cc
Normal file
98
accountlabel/src/model/AddCustomerLabelRequest.cc
Normal file
@@ -0,0 +1,98 @@
|
||||
/*
|
||||
* 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/accountlabel/model/AddCustomerLabelRequest.h>
|
||||
|
||||
using AlibabaCloud::AccountLabel::Model::AddCustomerLabelRequest;
|
||||
|
||||
AddCustomerLabelRequest::AddCustomerLabelRequest()
|
||||
: RpcServiceRequest("accountlabel", "2020-03-15", "AddCustomerLabel") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
AddCustomerLabelRequest::~AddCustomerLabelRequest() {}
|
||||
|
||||
std::string AddCustomerLabelRequest::getLabelSeries() const {
|
||||
return labelSeries_;
|
||||
}
|
||||
|
||||
void AddCustomerLabelRequest::setLabelSeries(const std::string &labelSeries) {
|
||||
labelSeries_ = labelSeries;
|
||||
setParameter(std::string("LabelSeries"), labelSeries);
|
||||
}
|
||||
|
||||
std::string AddCustomerLabelRequest::getOrganization() const {
|
||||
return organization_;
|
||||
}
|
||||
|
||||
void AddCustomerLabelRequest::setOrganization(const std::string &organization) {
|
||||
organization_ = organization;
|
||||
setParameter(std::string("Organization"), organization);
|
||||
}
|
||||
|
||||
std::string AddCustomerLabelRequest::getEndtime() const {
|
||||
return endtime_;
|
||||
}
|
||||
|
||||
void AddCustomerLabelRequest::setEndtime(const std::string &endtime) {
|
||||
endtime_ = endtime;
|
||||
setParameter(std::string("Endtime"), endtime);
|
||||
}
|
||||
|
||||
long AddCustomerLabelRequest::getPK() const {
|
||||
return pK_;
|
||||
}
|
||||
|
||||
void AddCustomerLabelRequest::setPK(long pK) {
|
||||
pK_ = pK;
|
||||
setParameter(std::string("PK"), std::to_string(pK));
|
||||
}
|
||||
|
||||
std::string AddCustomerLabelRequest::getStartTime() const {
|
||||
return startTime_;
|
||||
}
|
||||
|
||||
void AddCustomerLabelRequest::setStartTime(const std::string &startTime) {
|
||||
startTime_ = startTime;
|
||||
setParameter(std::string("StartTime"), startTime);
|
||||
}
|
||||
|
||||
std::vector<std::string> AddCustomerLabelRequest::getLabelTypes() const {
|
||||
return labelTypes_;
|
||||
}
|
||||
|
||||
void AddCustomerLabelRequest::setLabelTypes(const std::vector<std::string> &labelTypes) {
|
||||
labelTypes_ = labelTypes;
|
||||
}
|
||||
|
||||
std::string AddCustomerLabelRequest::getUserName() const {
|
||||
return userName_;
|
||||
}
|
||||
|
||||
void AddCustomerLabelRequest::setUserName(const std::string &userName) {
|
||||
userName_ = userName;
|
||||
setParameter(std::string("UserName"), userName);
|
||||
}
|
||||
|
||||
std::string AddCustomerLabelRequest::getToken() const {
|
||||
return token_;
|
||||
}
|
||||
|
||||
void AddCustomerLabelRequest::setToken(const std::string &token) {
|
||||
token_ = token;
|
||||
setParameter(std::string("Token"), token);
|
||||
}
|
||||
|
||||
65
accountlabel/src/model/AddCustomerLabelResult.cc
Normal file
65
accountlabel/src/model/AddCustomerLabelResult.cc
Normal file
@@ -0,0 +1,65 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/accountlabel/model/AddCustomerLabelResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AccountLabel;
|
||||
using namespace AlibabaCloud::AccountLabel::Model;
|
||||
|
||||
AddCustomerLabelResult::AddCustomerLabelResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
AddCustomerLabelResult::AddCustomerLabelResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
AddCustomerLabelResult::~AddCustomerLabelResult()
|
||||
{}
|
||||
|
||||
void AddCustomerLabelResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
if(!value["Code"].isNull())
|
||||
code_ = value["Code"].asString();
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
if(!value["Success"].isNull())
|
||||
success_ = value["Success"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
std::string AddCustomerLabelResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
std::string AddCustomerLabelResult::getCode()const
|
||||
{
|
||||
return code_;
|
||||
}
|
||||
|
||||
bool AddCustomerLabelResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
83
accountlabel/src/model/BatchFetchAccountLabelRequest.cc
Normal file
83
accountlabel/src/model/BatchFetchAccountLabelRequest.cc
Normal file
@@ -0,0 +1,83 @@
|
||||
/*
|
||||
* 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/accountlabel/model/BatchFetchAccountLabelRequest.h>
|
||||
|
||||
using AlibabaCloud::AccountLabel::Model::BatchFetchAccountLabelRequest;
|
||||
|
||||
BatchFetchAccountLabelRequest::BatchFetchAccountLabelRequest()
|
||||
: RpcServiceRequest("accountlabel", "2020-03-15", "BatchFetchAccountLabel") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
BatchFetchAccountLabelRequest::~BatchFetchAccountLabelRequest() {}
|
||||
|
||||
std::string BatchFetchAccountLabelRequest::getOrganization() const {
|
||||
return organization_;
|
||||
}
|
||||
|
||||
void BatchFetchAccountLabelRequest::setOrganization(const std::string &organization) {
|
||||
organization_ = organization;
|
||||
setParameter(std::string("Organization"), organization);
|
||||
}
|
||||
|
||||
long BatchFetchAccountLabelRequest::getPk() const {
|
||||
return pk_;
|
||||
}
|
||||
|
||||
void BatchFetchAccountLabelRequest::setPk(long pk) {
|
||||
pk_ = pk;
|
||||
setParameter(std::string("Pk"), std::to_string(pk));
|
||||
}
|
||||
|
||||
std::string BatchFetchAccountLabelRequest::getUserName() const {
|
||||
return userName_;
|
||||
}
|
||||
|
||||
void BatchFetchAccountLabelRequest::setUserName(const std::string &userName) {
|
||||
userName_ = userName;
|
||||
setParameter(std::string("UserName"), userName);
|
||||
}
|
||||
|
||||
bool BatchFetchAccountLabelRequest::getInstant() const {
|
||||
return instant_;
|
||||
}
|
||||
|
||||
void BatchFetchAccountLabelRequest::setInstant(bool instant) {
|
||||
instant_ = instant;
|
||||
setParameter(std::string("Instant"), instant ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string BatchFetchAccountLabelRequest::getToken() const {
|
||||
return token_;
|
||||
}
|
||||
|
||||
void BatchFetchAccountLabelRequest::setToken(const std::string &token) {
|
||||
token_ = token;
|
||||
setParameter(std::string("Token"), token);
|
||||
}
|
||||
|
||||
std::vector<BatchFetchAccountLabelRequest::std::string> BatchFetchAccountLabelRequest::getLabelSeriesList() const {
|
||||
return labelSeriesList_;
|
||||
}
|
||||
|
||||
void BatchFetchAccountLabelRequest::setLabelSeriesList(const std::vector<BatchFetchAccountLabelRequest::std::string> &labelSeriesList) {
|
||||
labelSeriesList_ = labelSeriesList;
|
||||
for(int dep1 = 0; dep1 != labelSeriesList.size(); dep1++) {
|
||||
setParameter(std::string("LabelSeriesList") + "." + std::to_string(dep1 + 1), labelSeriesList[dep1]);
|
||||
}
|
||||
}
|
||||
|
||||
99
accountlabel/src/model/BatchFetchAccountLabelResult.cc
Normal file
99
accountlabel/src/model/BatchFetchAccountLabelResult.cc
Normal file
@@ -0,0 +1,99 @@
|
||||
/*
|
||||
* 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/accountlabel/model/BatchFetchAccountLabelResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AccountLabel;
|
||||
using namespace AlibabaCloud::AccountLabel::Model;
|
||||
|
||||
BatchFetchAccountLabelResult::BatchFetchAccountLabelResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
BatchFetchAccountLabelResult::BatchFetchAccountLabelResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
BatchFetchAccountLabelResult::~BatchFetchAccountLabelResult()
|
||||
{}
|
||||
|
||||
void BatchFetchAccountLabelResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allDataNode = value["Data"]["AccountLabelInfoDto"];
|
||||
for (auto valueDataAccountLabelInfoDto : allDataNode)
|
||||
{
|
||||
AccountLabelInfoDto dataObject;
|
||||
if(!valueDataAccountLabelInfoDto["Creator"].isNull())
|
||||
dataObject.creator = valueDataAccountLabelInfoDto["Creator"].asString();
|
||||
if(!valueDataAccountLabelInfoDto["EndTime"].isNull())
|
||||
dataObject.endTime = std::stol(valueDataAccountLabelInfoDto["EndTime"].asString());
|
||||
if(!valueDataAccountLabelInfoDto["GmtCreated"].isNull())
|
||||
dataObject.gmtCreated = std::stol(valueDataAccountLabelInfoDto["GmtCreated"].asString());
|
||||
if(!valueDataAccountLabelInfoDto["GmtModified"].isNull())
|
||||
dataObject.gmtModified = std::stol(valueDataAccountLabelInfoDto["GmtModified"].asString());
|
||||
if(!valueDataAccountLabelInfoDto["Kp"].isNull())
|
||||
dataObject.kp = std::stol(valueDataAccountLabelInfoDto["Kp"].asString());
|
||||
if(!valueDataAccountLabelInfoDto["Label"].isNull())
|
||||
dataObject.label = valueDataAccountLabelInfoDto["Label"].asString();
|
||||
if(!valueDataAccountLabelInfoDto["LabelSeries"].isNull())
|
||||
dataObject.labelSeries = valueDataAccountLabelInfoDto["LabelSeries"].asString();
|
||||
if(!valueDataAccountLabelInfoDto["StartTime"].isNull())
|
||||
dataObject.startTime = std::stol(valueDataAccountLabelInfoDto["StartTime"].asString());
|
||||
data_.push_back(dataObject);
|
||||
}
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
if(!value["Count"].isNull())
|
||||
count_ = std::stol(value["Count"].asString());
|
||||
if(!value["Code"].isNull())
|
||||
code_ = value["Code"].asString();
|
||||
if(!value["Success"].isNull())
|
||||
success_ = value["Success"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
std::string BatchFetchAccountLabelResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
std::vector<BatchFetchAccountLabelResult::AccountLabelInfoDto> BatchFetchAccountLabelResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
long BatchFetchAccountLabelResult::getCount()const
|
||||
{
|
||||
return count_;
|
||||
}
|
||||
|
||||
std::string BatchFetchAccountLabelResult::getCode()const
|
||||
{
|
||||
return code_;
|
||||
}
|
||||
|
||||
bool BatchFetchAccountLabelResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
80
accountlabel/src/model/DeleteCustomerLabelRequest.cc
Normal file
80
accountlabel/src/model/DeleteCustomerLabelRequest.cc
Normal file
@@ -0,0 +1,80 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/accountlabel/model/DeleteCustomerLabelRequest.h>
|
||||
|
||||
using AlibabaCloud::AccountLabel::Model::DeleteCustomerLabelRequest;
|
||||
|
||||
DeleteCustomerLabelRequest::DeleteCustomerLabelRequest()
|
||||
: RpcServiceRequest("accountlabel", "2020-03-15", "DeleteCustomerLabel") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DeleteCustomerLabelRequest::~DeleteCustomerLabelRequest() {}
|
||||
|
||||
std::string DeleteCustomerLabelRequest::getLabelSeries() const {
|
||||
return labelSeries_;
|
||||
}
|
||||
|
||||
void DeleteCustomerLabelRequest::setLabelSeries(const std::string &labelSeries) {
|
||||
labelSeries_ = labelSeries;
|
||||
setParameter(std::string("LabelSeries"), labelSeries);
|
||||
}
|
||||
|
||||
std::string DeleteCustomerLabelRequest::getOrganization() const {
|
||||
return organization_;
|
||||
}
|
||||
|
||||
void DeleteCustomerLabelRequest::setOrganization(const std::string &organization) {
|
||||
organization_ = organization;
|
||||
setParameter(std::string("Organization"), organization);
|
||||
}
|
||||
|
||||
long DeleteCustomerLabelRequest::getPK() const {
|
||||
return pK_;
|
||||
}
|
||||
|
||||
void DeleteCustomerLabelRequest::setPK(long pK) {
|
||||
pK_ = pK;
|
||||
setParameter(std::string("PK"), std::to_string(pK));
|
||||
}
|
||||
|
||||
std::vector<std::string> DeleteCustomerLabelRequest::getLabelTypes() const {
|
||||
return labelTypes_;
|
||||
}
|
||||
|
||||
void DeleteCustomerLabelRequest::setLabelTypes(const std::vector<std::string> &labelTypes) {
|
||||
labelTypes_ = labelTypes;
|
||||
}
|
||||
|
||||
std::string DeleteCustomerLabelRequest::getUserName() const {
|
||||
return userName_;
|
||||
}
|
||||
|
||||
void DeleteCustomerLabelRequest::setUserName(const std::string &userName) {
|
||||
userName_ = userName;
|
||||
setParameter(std::string("UserName"), userName);
|
||||
}
|
||||
|
||||
std::string DeleteCustomerLabelRequest::getToken() const {
|
||||
return token_;
|
||||
}
|
||||
|
||||
void DeleteCustomerLabelRequest::setToken(const std::string &token) {
|
||||
token_ = token;
|
||||
setParameter(std::string("Token"), token);
|
||||
}
|
||||
|
||||
65
accountlabel/src/model/DeleteCustomerLabelResult.cc
Normal file
65
accountlabel/src/model/DeleteCustomerLabelResult.cc
Normal file
@@ -0,0 +1,65 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/accountlabel/model/DeleteCustomerLabelResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AccountLabel;
|
||||
using namespace AlibabaCloud::AccountLabel::Model;
|
||||
|
||||
DeleteCustomerLabelResult::DeleteCustomerLabelResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DeleteCustomerLabelResult::DeleteCustomerLabelResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DeleteCustomerLabelResult::~DeleteCustomerLabelResult()
|
||||
{}
|
||||
|
||||
void DeleteCustomerLabelResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
if(!value["Code"].isNull())
|
||||
code_ = value["Code"].asString();
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
if(!value["Success"].isNull())
|
||||
success_ = value["Success"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
std::string DeleteCustomerLabelResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
std::string DeleteCustomerLabelResult::getCode()const
|
||||
{
|
||||
return code_;
|
||||
}
|
||||
|
||||
bool DeleteCustomerLabelResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,54 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/accountlabel/model/QueryCustomerLabelByConfigGroupRequest.h>
|
||||
|
||||
using AlibabaCloud::AccountLabel::Model::QueryCustomerLabelByConfigGroupRequest;
|
||||
|
||||
QueryCustomerLabelByConfigGroupRequest::QueryCustomerLabelByConfigGroupRequest()
|
||||
: RpcServiceRequest("accountlabel", "2020-03-15", "QueryCustomerLabelByConfigGroup") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
QueryCustomerLabelByConfigGroupRequest::~QueryCustomerLabelByConfigGroupRequest() {}
|
||||
|
||||
std::string QueryCustomerLabelByConfigGroupRequest::getGroupType() const {
|
||||
return groupType_;
|
||||
}
|
||||
|
||||
void QueryCustomerLabelByConfigGroupRequest::setGroupType(const std::string &groupType) {
|
||||
groupType_ = groupType;
|
||||
setParameter(std::string("GroupType"), groupType);
|
||||
}
|
||||
|
||||
long QueryCustomerLabelByConfigGroupRequest::getPK() const {
|
||||
return pK_;
|
||||
}
|
||||
|
||||
void QueryCustomerLabelByConfigGroupRequest::setPK(long pK) {
|
||||
pK_ = pK;
|
||||
setParameter(std::string("PK"), std::to_string(pK));
|
||||
}
|
||||
|
||||
std::string QueryCustomerLabelByConfigGroupRequest::getToken() const {
|
||||
return token_;
|
||||
}
|
||||
|
||||
void QueryCustomerLabelByConfigGroupRequest::setToken(const std::string &token) {
|
||||
token_ = token;
|
||||
setParameter(std::string("Token"), token);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,80 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/accountlabel/model/QueryCustomerLabelByConfigGroupResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AccountLabel;
|
||||
using namespace AlibabaCloud::AccountLabel::Model;
|
||||
|
||||
QueryCustomerLabelByConfigGroupResult::QueryCustomerLabelByConfigGroupResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
QueryCustomerLabelByConfigGroupResult::QueryCustomerLabelByConfigGroupResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
QueryCustomerLabelByConfigGroupResult::~QueryCustomerLabelByConfigGroupResult()
|
||||
{}
|
||||
|
||||
void QueryCustomerLabelByConfigGroupResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allDataNode = value["Data"]["CustomerLabel"];
|
||||
for (auto valueDataCustomerLabel : allDataNode)
|
||||
{
|
||||
CustomerLabel dataObject;
|
||||
if(!valueDataCustomerLabel["Label"].isNull())
|
||||
dataObject.label = valueDataCustomerLabel["Label"].asString();
|
||||
if(!valueDataCustomerLabel["LabelSeries"].isNull())
|
||||
dataObject.labelSeries = valueDataCustomerLabel["LabelSeries"].asString();
|
||||
data_.push_back(dataObject);
|
||||
}
|
||||
if(!value["Code"].isNull())
|
||||
code_ = value["Code"].asString();
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
if(!value["Success"].isNull())
|
||||
success_ = value["Success"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
std::string QueryCustomerLabelByConfigGroupResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
std::vector<QueryCustomerLabelByConfigGroupResult::CustomerLabel> QueryCustomerLabelByConfigGroupResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string QueryCustomerLabelByConfigGroupResult::getCode()const
|
||||
{
|
||||
return code_;
|
||||
}
|
||||
|
||||
bool QueryCustomerLabelByConfigGroupResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
63
accountlabel/src/model/QueryCustomerLabelRequest.cc
Normal file
63
accountlabel/src/model/QueryCustomerLabelRequest.cc
Normal 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.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/accountlabel/model/QueryCustomerLabelRequest.h>
|
||||
|
||||
using AlibabaCloud::AccountLabel::Model::QueryCustomerLabelRequest;
|
||||
|
||||
QueryCustomerLabelRequest::QueryCustomerLabelRequest()
|
||||
: RpcServiceRequest("accountlabel", "2020-03-15", "QueryCustomerLabel") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
QueryCustomerLabelRequest::~QueryCustomerLabelRequest() {}
|
||||
|
||||
std::string QueryCustomerLabelRequest::getLabelSeries() const {
|
||||
return labelSeries_;
|
||||
}
|
||||
|
||||
void QueryCustomerLabelRequest::setLabelSeries(const std::string &labelSeries) {
|
||||
labelSeries_ = labelSeries;
|
||||
setParameter(std::string("LabelSeries"), labelSeries);
|
||||
}
|
||||
|
||||
long QueryCustomerLabelRequest::getPK() const {
|
||||
return pK_;
|
||||
}
|
||||
|
||||
void QueryCustomerLabelRequest::setPK(long pK) {
|
||||
pK_ = pK;
|
||||
setParameter(std::string("PK"), std::to_string(pK));
|
||||
}
|
||||
|
||||
std::string QueryCustomerLabelRequest::getToken() const {
|
||||
return token_;
|
||||
}
|
||||
|
||||
void QueryCustomerLabelRequest::setToken(const std::string &token) {
|
||||
token_ = token;
|
||||
setParameter(std::string("Token"), token);
|
||||
}
|
||||
|
||||
bool QueryCustomerLabelRequest::getInstant() const {
|
||||
return instant_;
|
||||
}
|
||||
|
||||
void QueryCustomerLabelRequest::setInstant(bool instant) {
|
||||
instant_ = instant;
|
||||
setParameter(std::string("Instant"), instant ? "true" : "false");
|
||||
}
|
||||
|
||||
80
accountlabel/src/model/QueryCustomerLabelResult.cc
Normal file
80
accountlabel/src/model/QueryCustomerLabelResult.cc
Normal file
@@ -0,0 +1,80 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/accountlabel/model/QueryCustomerLabelResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AccountLabel;
|
||||
using namespace AlibabaCloud::AccountLabel::Model;
|
||||
|
||||
QueryCustomerLabelResult::QueryCustomerLabelResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
QueryCustomerLabelResult::QueryCustomerLabelResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
QueryCustomerLabelResult::~QueryCustomerLabelResult()
|
||||
{}
|
||||
|
||||
void QueryCustomerLabelResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allDataNode = value["Data"]["CustomerLabel"];
|
||||
for (auto valueDataCustomerLabel : allDataNode)
|
||||
{
|
||||
CustomerLabel dataObject;
|
||||
if(!valueDataCustomerLabel["Label"].isNull())
|
||||
dataObject.label = valueDataCustomerLabel["Label"].asString();
|
||||
if(!valueDataCustomerLabel["LabelSeries"].isNull())
|
||||
dataObject.labelSeries = valueDataCustomerLabel["LabelSeries"].asString();
|
||||
data_.push_back(dataObject);
|
||||
}
|
||||
if(!value["Code"].isNull())
|
||||
code_ = value["Code"].asString();
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
if(!value["Success"].isNull())
|
||||
success_ = value["Success"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
std::string QueryCustomerLabelResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
std::vector<QueryCustomerLabelResult::CustomerLabel> QueryCustomerLabelResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string QueryCustomerLabelResult::getCode()const
|
||||
{
|
||||
return code_;
|
||||
}
|
||||
|
||||
bool QueryCustomerLabelResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
@@ -135,8 +135,6 @@ set(adb_public_header_model
|
||||
include/alibabacloud/adb/model/DescribeProcessListResult.h
|
||||
include/alibabacloud/adb/model/DescribeRegionsRequest.h
|
||||
include/alibabacloud/adb/model/DescribeRegionsResult.h
|
||||
include/alibabacloud/adb/model/DescribeSQLPatternAttributeRequest.h
|
||||
include/alibabacloud/adb/model/DescribeSQLPatternAttributeResult.h
|
||||
include/alibabacloud/adb/model/DescribeSQLPatternsRequest.h
|
||||
include/alibabacloud/adb/model/DescribeSQLPatternsResult.h
|
||||
include/alibabacloud/adb/model/DescribeSQLPlanRequest.h
|
||||
@@ -163,14 +161,14 @@ set(adb_public_header_model
|
||||
include/alibabacloud/adb/model/DescribeTablesResult.h
|
||||
include/alibabacloud/adb/model/DescribeTaskInfoRequest.h
|
||||
include/alibabacloud/adb/model/DescribeTaskInfoResult.h
|
||||
include/alibabacloud/adb/model/DescribeVSwitchesRequest.h
|
||||
include/alibabacloud/adb/model/DescribeVSwitchesResult.h
|
||||
include/alibabacloud/adb/model/DetachUserENIRequest.h
|
||||
include/alibabacloud/adb/model/DetachUserENIResult.h
|
||||
include/alibabacloud/adb/model/DisableAdviceServiceRequest.h
|
||||
include/alibabacloud/adb/model/DisableAdviceServiceResult.h
|
||||
include/alibabacloud/adb/model/DownloadDiagnosisRecordsRequest.h
|
||||
include/alibabacloud/adb/model/DownloadDiagnosisRecordsResult.h
|
||||
include/alibabacloud/adb/model/DryRunClusterRequest.h
|
||||
include/alibabacloud/adb/model/DryRunClusterResult.h
|
||||
include/alibabacloud/adb/model/EnableAdviceServiceRequest.h
|
||||
include/alibabacloud/adb/model/EnableAdviceServiceResult.h
|
||||
include/alibabacloud/adb/model/GrantOperatorPermissionRequest.h
|
||||
@@ -344,8 +342,6 @@ set(adb_src
|
||||
src/model/DescribeProcessListResult.cc
|
||||
src/model/DescribeRegionsRequest.cc
|
||||
src/model/DescribeRegionsResult.cc
|
||||
src/model/DescribeSQLPatternAttributeRequest.cc
|
||||
src/model/DescribeSQLPatternAttributeResult.cc
|
||||
src/model/DescribeSQLPatternsRequest.cc
|
||||
src/model/DescribeSQLPatternsResult.cc
|
||||
src/model/DescribeSQLPlanRequest.cc
|
||||
@@ -372,14 +368,14 @@ set(adb_src
|
||||
src/model/DescribeTablesResult.cc
|
||||
src/model/DescribeTaskInfoRequest.cc
|
||||
src/model/DescribeTaskInfoResult.cc
|
||||
src/model/DescribeVSwitchesRequest.cc
|
||||
src/model/DescribeVSwitchesResult.cc
|
||||
src/model/DetachUserENIRequest.cc
|
||||
src/model/DetachUserENIResult.cc
|
||||
src/model/DisableAdviceServiceRequest.cc
|
||||
src/model/DisableAdviceServiceResult.cc
|
||||
src/model/DownloadDiagnosisRecordsRequest.cc
|
||||
src/model/DownloadDiagnosisRecordsResult.cc
|
||||
src/model/DryRunClusterRequest.cc
|
||||
src/model/DryRunClusterResult.cc
|
||||
src/model/EnableAdviceServiceRequest.cc
|
||||
src/model/EnableAdviceServiceResult.cc
|
||||
src/model/GrantOperatorPermissionRequest.cc
|
||||
|
||||
@@ -136,8 +136,6 @@
|
||||
#include "model/DescribeProcessListResult.h"
|
||||
#include "model/DescribeRegionsRequest.h"
|
||||
#include "model/DescribeRegionsResult.h"
|
||||
#include "model/DescribeSQLPatternAttributeRequest.h"
|
||||
#include "model/DescribeSQLPatternAttributeResult.h"
|
||||
#include "model/DescribeSQLPatternsRequest.h"
|
||||
#include "model/DescribeSQLPatternsResult.h"
|
||||
#include "model/DescribeSQLPlanRequest.h"
|
||||
@@ -164,14 +162,14 @@
|
||||
#include "model/DescribeTablesResult.h"
|
||||
#include "model/DescribeTaskInfoRequest.h"
|
||||
#include "model/DescribeTaskInfoResult.h"
|
||||
#include "model/DescribeVSwitchesRequest.h"
|
||||
#include "model/DescribeVSwitchesResult.h"
|
||||
#include "model/DetachUserENIRequest.h"
|
||||
#include "model/DetachUserENIResult.h"
|
||||
#include "model/DisableAdviceServiceRequest.h"
|
||||
#include "model/DisableAdviceServiceResult.h"
|
||||
#include "model/DownloadDiagnosisRecordsRequest.h"
|
||||
#include "model/DownloadDiagnosisRecordsResult.h"
|
||||
#include "model/DryRunClusterRequest.h"
|
||||
#include "model/DryRunClusterResult.h"
|
||||
#include "model/EnableAdviceServiceRequest.h"
|
||||
#include "model/EnableAdviceServiceResult.h"
|
||||
#include "model/GrantOperatorPermissionRequest.h"
|
||||
@@ -408,9 +406,6 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::DescribeRegionsResult> DescribeRegionsOutcome;
|
||||
typedef std::future<DescribeRegionsOutcome> DescribeRegionsOutcomeCallable;
|
||||
typedef std::function<void(const AdbClient*, const Model::DescribeRegionsRequest&, const DescribeRegionsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeRegionsAsyncHandler;
|
||||
typedef Outcome<Error, Model::DescribeSQLPatternAttributeResult> DescribeSQLPatternAttributeOutcome;
|
||||
typedef std::future<DescribeSQLPatternAttributeOutcome> DescribeSQLPatternAttributeOutcomeCallable;
|
||||
typedef std::function<void(const AdbClient*, const Model::DescribeSQLPatternAttributeRequest&, const DescribeSQLPatternAttributeOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeSQLPatternAttributeAsyncHandler;
|
||||
typedef Outcome<Error, Model::DescribeSQLPatternsResult> DescribeSQLPatternsOutcome;
|
||||
typedef std::future<DescribeSQLPatternsOutcome> DescribeSQLPatternsOutcomeCallable;
|
||||
typedef std::function<void(const AdbClient*, const Model::DescribeSQLPatternsRequest&, const DescribeSQLPatternsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeSQLPatternsAsyncHandler;
|
||||
@@ -450,6 +445,9 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::DescribeTaskInfoResult> DescribeTaskInfoOutcome;
|
||||
typedef std::future<DescribeTaskInfoOutcome> DescribeTaskInfoOutcomeCallable;
|
||||
typedef std::function<void(const AdbClient*, const Model::DescribeTaskInfoRequest&, const DescribeTaskInfoOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeTaskInfoAsyncHandler;
|
||||
typedef Outcome<Error, Model::DescribeVSwitchesResult> DescribeVSwitchesOutcome;
|
||||
typedef std::future<DescribeVSwitchesOutcome> DescribeVSwitchesOutcomeCallable;
|
||||
typedef std::function<void(const AdbClient*, const Model::DescribeVSwitchesRequest&, const DescribeVSwitchesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeVSwitchesAsyncHandler;
|
||||
typedef Outcome<Error, Model::DetachUserENIResult> DetachUserENIOutcome;
|
||||
typedef std::future<DetachUserENIOutcome> DetachUserENIOutcomeCallable;
|
||||
typedef std::function<void(const AdbClient*, const Model::DetachUserENIRequest&, const DetachUserENIOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DetachUserENIAsyncHandler;
|
||||
@@ -459,9 +457,6 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::DownloadDiagnosisRecordsResult> DownloadDiagnosisRecordsOutcome;
|
||||
typedef std::future<DownloadDiagnosisRecordsOutcome> DownloadDiagnosisRecordsOutcomeCallable;
|
||||
typedef std::function<void(const AdbClient*, const Model::DownloadDiagnosisRecordsRequest&, const DownloadDiagnosisRecordsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DownloadDiagnosisRecordsAsyncHandler;
|
||||
typedef Outcome<Error, Model::DryRunClusterResult> DryRunClusterOutcome;
|
||||
typedef std::future<DryRunClusterOutcome> DryRunClusterOutcomeCallable;
|
||||
typedef std::function<void(const AdbClient*, const Model::DryRunClusterRequest&, const DryRunClusterOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DryRunClusterAsyncHandler;
|
||||
typedef Outcome<Error, Model::EnableAdviceServiceResult> EnableAdviceServiceOutcome;
|
||||
typedef std::future<EnableAdviceServiceOutcome> EnableAdviceServiceOutcomeCallable;
|
||||
typedef std::function<void(const AdbClient*, const Model::EnableAdviceServiceRequest&, const EnableAdviceServiceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> EnableAdviceServiceAsyncHandler;
|
||||
@@ -722,9 +717,6 @@ namespace AlibabaCloud
|
||||
DescribeRegionsOutcome describeRegions(const Model::DescribeRegionsRequest &request)const;
|
||||
void describeRegionsAsync(const Model::DescribeRegionsRequest& request, const DescribeRegionsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DescribeRegionsOutcomeCallable describeRegionsCallable(const Model::DescribeRegionsRequest& request) const;
|
||||
DescribeSQLPatternAttributeOutcome describeSQLPatternAttribute(const Model::DescribeSQLPatternAttributeRequest &request)const;
|
||||
void describeSQLPatternAttributeAsync(const Model::DescribeSQLPatternAttributeRequest& request, const DescribeSQLPatternAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DescribeSQLPatternAttributeOutcomeCallable describeSQLPatternAttributeCallable(const Model::DescribeSQLPatternAttributeRequest& request) const;
|
||||
DescribeSQLPatternsOutcome describeSQLPatterns(const Model::DescribeSQLPatternsRequest &request)const;
|
||||
void describeSQLPatternsAsync(const Model::DescribeSQLPatternsRequest& request, const DescribeSQLPatternsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DescribeSQLPatternsOutcomeCallable describeSQLPatternsCallable(const Model::DescribeSQLPatternsRequest& request) const;
|
||||
@@ -764,6 +756,9 @@ namespace AlibabaCloud
|
||||
DescribeTaskInfoOutcome describeTaskInfo(const Model::DescribeTaskInfoRequest &request)const;
|
||||
void describeTaskInfoAsync(const Model::DescribeTaskInfoRequest& request, const DescribeTaskInfoAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DescribeTaskInfoOutcomeCallable describeTaskInfoCallable(const Model::DescribeTaskInfoRequest& request) const;
|
||||
DescribeVSwitchesOutcome describeVSwitches(const Model::DescribeVSwitchesRequest &request)const;
|
||||
void describeVSwitchesAsync(const Model::DescribeVSwitchesRequest& request, const DescribeVSwitchesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DescribeVSwitchesOutcomeCallable describeVSwitchesCallable(const Model::DescribeVSwitchesRequest& request) const;
|
||||
DetachUserENIOutcome detachUserENI(const Model::DetachUserENIRequest &request)const;
|
||||
void detachUserENIAsync(const Model::DetachUserENIRequest& request, const DetachUserENIAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DetachUserENIOutcomeCallable detachUserENICallable(const Model::DetachUserENIRequest& request) const;
|
||||
@@ -773,9 +768,6 @@ namespace AlibabaCloud
|
||||
DownloadDiagnosisRecordsOutcome downloadDiagnosisRecords(const Model::DownloadDiagnosisRecordsRequest &request)const;
|
||||
void downloadDiagnosisRecordsAsync(const Model::DownloadDiagnosisRecordsRequest& request, const DownloadDiagnosisRecordsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DownloadDiagnosisRecordsOutcomeCallable downloadDiagnosisRecordsCallable(const Model::DownloadDiagnosisRecordsRequest& request) const;
|
||||
DryRunClusterOutcome dryRunCluster(const Model::DryRunClusterRequest &request)const;
|
||||
void dryRunClusterAsync(const Model::DryRunClusterRequest& request, const DryRunClusterAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DryRunClusterOutcomeCallable dryRunClusterCallable(const Model::DryRunClusterRequest& request) const;
|
||||
EnableAdviceServiceOutcome enableAdviceService(const Model::EnableAdviceServiceRequest &request)const;
|
||||
void enableAdviceServiceAsync(const Model::EnableAdviceServiceRequest& request, const EnableAdviceServiceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
EnableAdviceServiceOutcomeCallable enableAdviceServiceCallable(const Model::EnableAdviceServiceRequest& request) const;
|
||||
|
||||
@@ -32,12 +32,6 @@ public:
|
||||
~DescribeDBClusterPerformanceRequest();
|
||||
long getResourceOwnerId() const;
|
||||
void setResourceOwnerId(long resourceOwnerId);
|
||||
std::string getStartTime() const;
|
||||
void setStartTime(const std::string &startTime);
|
||||
std::string getAccessKeyId() const;
|
||||
void setAccessKeyId(const std::string &accessKeyId);
|
||||
std::string getKey() const;
|
||||
void setKey(const std::string &key);
|
||||
std::string getResourceOwnerAccount() const;
|
||||
void setResourceOwnerAccount(const std::string &resourceOwnerAccount);
|
||||
std::string getDBClusterId() const;
|
||||
@@ -46,19 +40,31 @@ public:
|
||||
void setOwnerAccount(const std::string &ownerAccount);
|
||||
std::string getEndTime() const;
|
||||
void setEndTime(const std::string &endTime);
|
||||
std::string getStartTime() const;
|
||||
void setStartTime(const std::string &startTime);
|
||||
long getOwnerId() const;
|
||||
void setOwnerId(long ownerId);
|
||||
std::string getAccessKeyId() const;
|
||||
void setAccessKeyId(const std::string &accessKeyId);
|
||||
std::string getRegionId() const;
|
||||
void setRegionId(const std::string ®ionId);
|
||||
std::string getResourcePools() const;
|
||||
void setResourcePools(const std::string &resourcePools);
|
||||
std::string getKey() const;
|
||||
void setKey(const std::string &key);
|
||||
|
||||
private:
|
||||
long resourceOwnerId_;
|
||||
std::string startTime_;
|
||||
std::string accessKeyId_;
|
||||
std::string key_;
|
||||
std::string resourceOwnerAccount_;
|
||||
std::string dBClusterId_;
|
||||
std::string ownerAccount_;
|
||||
std::string endTime_;
|
||||
std::string startTime_;
|
||||
long ownerId_;
|
||||
std::string accessKeyId_;
|
||||
std::string regionId_;
|
||||
std::string resourcePools_;
|
||||
std::string key_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Adb
|
||||
|
||||
@@ -37,6 +37,7 @@ namespace AlibabaCloud
|
||||
struct SeriesItem
|
||||
{
|
||||
std::vector<std::string> values;
|
||||
std::string tags;
|
||||
std::string name;
|
||||
};
|
||||
std::vector<PerformanceItem::SeriesItem> series;
|
||||
|
||||
@@ -1,57 +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.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ADB_MODEL_DESCRIBESQLPATTERNATTRIBUTEREQUEST_H_
|
||||
#define ALIBABACLOUD_ADB_MODEL_DESCRIBESQLPATTERNATTRIBUTEREQUEST_H_
|
||||
|
||||
#include <alibabacloud/adb/AdbExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Adb {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_ADB_EXPORT DescribeSQLPatternAttributeRequest : public RpcServiceRequest {
|
||||
public:
|
||||
DescribeSQLPatternAttributeRequest();
|
||||
~DescribeSQLPatternAttributeRequest();
|
||||
std::string getDBClusterId() const;
|
||||
void setDBClusterId(const std::string &dBClusterId);
|
||||
long getPatternId() const;
|
||||
void setPatternId(long patternId);
|
||||
std::string getEndTime() const;
|
||||
void setEndTime(const std::string &endTime);
|
||||
std::string getStartTime() const;
|
||||
void setStartTime(const std::string &startTime);
|
||||
std::string getRegionId() const;
|
||||
void setRegionId(const std::string ®ionId);
|
||||
std::string getLang() const;
|
||||
void setLang(const std::string &lang);
|
||||
|
||||
private:
|
||||
std::string dBClusterId_;
|
||||
long patternId_;
|
||||
std::string endTime_;
|
||||
std::string startTime_;
|
||||
std::string regionId_;
|
||||
std::string lang_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Adb
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_ADB_MODEL_DESCRIBESQLPATTERNATTRIBUTEREQUEST_H_
|
||||
@@ -1,59 +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.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ADB_MODEL_DESCRIBESQLPATTERNATTRIBUTERESULT_H_
|
||||
#define ALIBABACLOUD_ADB_MODEL_DESCRIBESQLPATTERNATTRIBUTERESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/adb/AdbExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Adb
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ADB_EXPORT DescribeSQLPatternAttributeResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct PatternDetail
|
||||
{
|
||||
std::string sQLPattern;
|
||||
std::string totalQueryTime;
|
||||
std::string averageMemory;
|
||||
long queryCount;
|
||||
std::string averageQueryTime;
|
||||
};
|
||||
|
||||
|
||||
DescribeSQLPatternAttributeResult();
|
||||
explicit DescribeSQLPatternAttributeResult(const std::string &payload);
|
||||
~DescribeSQLPatternAttributeResult();
|
||||
PatternDetail getPatternDetail()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
PatternDetail patternDetail_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ADB_MODEL_DESCRIBESQLPATTERNATTRIBUTERESULT_H_
|
||||
@@ -0,0 +1,69 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ADB_MODEL_DESCRIBEVSWITCHESREQUEST_H_
|
||||
#define ALIBABACLOUD_ADB_MODEL_DESCRIBEVSWITCHESREQUEST_H_
|
||||
|
||||
#include <alibabacloud/adb/AdbExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Adb {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_ADB_EXPORT DescribeVSwitchesRequest : public RpcServiceRequest {
|
||||
public:
|
||||
DescribeVSwitchesRequest();
|
||||
~DescribeVSwitchesRequest();
|
||||
std::string getVswId() const;
|
||||
void setVswId(const std::string &vswId);
|
||||
long getResourceOwnerId() const;
|
||||
void setResourceOwnerId(long resourceOwnerId);
|
||||
std::string getAccessKeyId() const;
|
||||
void setAccessKeyId(const std::string &accessKeyId);
|
||||
std::string getSecurityToken() const;
|
||||
void setSecurityToken(const std::string &securityToken);
|
||||
std::string getRegionId() const;
|
||||
void setRegionId(const std::string ®ionId);
|
||||
std::string getResourceOwnerAccount() const;
|
||||
void setResourceOwnerAccount(const std::string &resourceOwnerAccount);
|
||||
std::string getOwnerAccount() const;
|
||||
void setOwnerAccount(const std::string &ownerAccount);
|
||||
long getOwnerId() const;
|
||||
void setOwnerId(long ownerId);
|
||||
std::string getVpcId() const;
|
||||
void setVpcId(const std::string &vpcId);
|
||||
std::string getZoneId() const;
|
||||
void setZoneId(const std::string &zoneId);
|
||||
|
||||
private:
|
||||
std::string vswId_;
|
||||
long resourceOwnerId_;
|
||||
std::string accessKeyId_;
|
||||
std::string securityToken_;
|
||||
std::string regionId_;
|
||||
std::string resourceOwnerAccount_;
|
||||
std::string ownerAccount_;
|
||||
long ownerId_;
|
||||
std::string vpcId_;
|
||||
std::string zoneId_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Adb
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_ADB_MODEL_DESCRIBEVSWITCHESREQUEST_H_
|
||||
69
adb/include/alibabacloud/adb/model/DescribeVSwitchesResult.h
Normal file
69
adb/include/alibabacloud/adb/model/DescribeVSwitchesResult.h
Normal file
@@ -0,0 +1,69 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ADB_MODEL_DESCRIBEVSWITCHESRESULT_H_
|
||||
#define ALIBABACLOUD_ADB_MODEL_DESCRIBEVSWITCHESRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/adb/AdbExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Adb
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ADB_EXPORT DescribeVSwitchesResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct VSwitches
|
||||
{
|
||||
struct VSwitchItem
|
||||
{
|
||||
std::string status;
|
||||
bool isDefault;
|
||||
std::string regionNo;
|
||||
std::string izNo;
|
||||
std::string gmtCreate;
|
||||
std::string vSwitchId;
|
||||
std::string gmtModified;
|
||||
std::string cidrBlock;
|
||||
std::string vSwitchName;
|
||||
std::string bid;
|
||||
std::string aliUid;
|
||||
};
|
||||
std::vector<VSwitchItem> vSwitch;
|
||||
};
|
||||
|
||||
|
||||
DescribeVSwitchesResult();
|
||||
explicit DescribeVSwitchesResult(const std::string &payload);
|
||||
~DescribeVSwitchesResult();
|
||||
VSwitches getVSwitches()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
VSwitches vSwitches_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ADB_MODEL_DESCRIBEVSWITCHESRESULT_H_
|
||||
@@ -1,87 +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.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ADB_MODEL_DRYRUNCLUSTERREQUEST_H_
|
||||
#define ALIBABACLOUD_ADB_MODEL_DRYRUNCLUSTERREQUEST_H_
|
||||
|
||||
#include <alibabacloud/adb/AdbExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Adb {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_ADB_EXPORT DryRunClusterRequest : public RpcServiceRequest {
|
||||
public:
|
||||
DryRunClusterRequest();
|
||||
~DryRunClusterRequest();
|
||||
std::string getDBClusterDescription() const;
|
||||
void setDBClusterDescription(const std::string &dBClusterDescription);
|
||||
bool getEnableDefaultResourcePool() const;
|
||||
void setEnableDefaultResourcePool(bool enableDefaultResourcePool);
|
||||
std::string getAccessKeyId() const;
|
||||
void setAccessKeyId(const std::string &accessKeyId);
|
||||
std::string getStorageResource() const;
|
||||
void setStorageResource(const std::string &storageResource);
|
||||
std::string getRegionId() const;
|
||||
void setRegionId(const std::string ®ionId);
|
||||
std::string getDBClusterNetworkType() const;
|
||||
void setDBClusterNetworkType(const std::string &dBClusterNetworkType);
|
||||
std::string getPeriod() const;
|
||||
void setPeriod(const std::string &period);
|
||||
std::string getDBClusterId() const;
|
||||
void setDBClusterId(const std::string &dBClusterId);
|
||||
std::string getDBClusterVersion() const;
|
||||
void setDBClusterVersion(const std::string &dBClusterVersion);
|
||||
std::string getUsedTime() const;
|
||||
void setUsedTime(const std::string &usedTime);
|
||||
std::string getVSwitchId() const;
|
||||
void setVSwitchId(const std::string &vSwitchId);
|
||||
std::string getVPCId() const;
|
||||
void setVPCId(const std::string &vPCId);
|
||||
std::string getZoneId() const;
|
||||
void setZoneId(const std::string &zoneId);
|
||||
std::string getComputeResource() const;
|
||||
void setComputeResource(const std::string &computeResource);
|
||||
std::string getPayType() const;
|
||||
void setPayType(const std::string &payType);
|
||||
std::string getOperation() const;
|
||||
void setOperation(const std::string &operation);
|
||||
|
||||
private:
|
||||
std::string dBClusterDescription_;
|
||||
bool enableDefaultResourcePool_;
|
||||
std::string accessKeyId_;
|
||||
std::string storageResource_;
|
||||
std::string regionId_;
|
||||
std::string dBClusterNetworkType_;
|
||||
std::string period_;
|
||||
std::string dBClusterId_;
|
||||
std::string dBClusterVersion_;
|
||||
std::string usedTime_;
|
||||
std::string vSwitchId_;
|
||||
std::string vPCId_;
|
||||
std::string zoneId_;
|
||||
std::string computeResource_;
|
||||
std::string payType_;
|
||||
std::string operation_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Adb
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_ADB_MODEL_DRYRUNCLUSTERREQUEST_H_
|
||||
@@ -1,51 +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.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ADB_MODEL_DRYRUNCLUSTERRESULT_H_
|
||||
#define ALIBABACLOUD_ADB_MODEL_DRYRUNCLUSTERRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/adb/AdbExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Adb
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ADB_EXPORT DryRunClusterResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
DryRunClusterResult();
|
||||
explicit DryRunClusterResult(const std::string &payload);
|
||||
~DryRunClusterResult();
|
||||
bool getSuccess()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
bool success_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ADB_MODEL_DRYRUNCLUSTERRESULT_H_
|
||||
@@ -2103,42 +2103,6 @@ AdbClient::DescribeRegionsOutcomeCallable AdbClient::describeRegionsCallable(con
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AdbClient::DescribeSQLPatternAttributeOutcome AdbClient::describeSQLPatternAttribute(const DescribeSQLPatternAttributeRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeSQLPatternAttributeOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeSQLPatternAttributeOutcome(DescribeSQLPatternAttributeResult(outcome.result()));
|
||||
else
|
||||
return DescribeSQLPatternAttributeOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AdbClient::describeSQLPatternAttributeAsync(const DescribeSQLPatternAttributeRequest& request, const DescribeSQLPatternAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeSQLPatternAttribute(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AdbClient::DescribeSQLPatternAttributeOutcomeCallable AdbClient::describeSQLPatternAttributeCallable(const DescribeSQLPatternAttributeRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeSQLPatternAttributeOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeSQLPatternAttribute(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AdbClient::DescribeSQLPatternsOutcome AdbClient::describeSQLPatterns(const DescribeSQLPatternsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -2607,6 +2571,42 @@ AdbClient::DescribeTaskInfoOutcomeCallable AdbClient::describeTaskInfoCallable(c
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AdbClient::DescribeVSwitchesOutcome AdbClient::describeVSwitches(const DescribeVSwitchesRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeVSwitchesOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeVSwitchesOutcome(DescribeVSwitchesResult(outcome.result()));
|
||||
else
|
||||
return DescribeVSwitchesOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AdbClient::describeVSwitchesAsync(const DescribeVSwitchesRequest& request, const DescribeVSwitchesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeVSwitches(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AdbClient::DescribeVSwitchesOutcomeCallable AdbClient::describeVSwitchesCallable(const DescribeVSwitchesRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeVSwitchesOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeVSwitches(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AdbClient::DetachUserENIOutcome AdbClient::detachUserENI(const DetachUserENIRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -2715,42 +2715,6 @@ AdbClient::DownloadDiagnosisRecordsOutcomeCallable AdbClient::downloadDiagnosisR
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AdbClient::DryRunClusterOutcome AdbClient::dryRunCluster(const DryRunClusterRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DryRunClusterOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DryRunClusterOutcome(DryRunClusterResult(outcome.result()));
|
||||
else
|
||||
return DryRunClusterOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AdbClient::dryRunClusterAsync(const DryRunClusterRequest& request, const DryRunClusterAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, dryRunCluster(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AdbClient::DryRunClusterOutcomeCallable AdbClient::dryRunClusterCallable(const DryRunClusterRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DryRunClusterOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->dryRunCluster(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AdbClient::EnableAdviceServiceOutcome AdbClient::enableAdviceService(const EnableAdviceServiceRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
|
||||
@@ -34,33 +34,6 @@ void DescribeDBClusterPerformanceRequest::setResourceOwnerId(long resourceOwnerI
|
||||
setParameter(std::string("ResourceOwnerId"), std::to_string(resourceOwnerId));
|
||||
}
|
||||
|
||||
std::string DescribeDBClusterPerformanceRequest::getStartTime() const {
|
||||
return startTime_;
|
||||
}
|
||||
|
||||
void DescribeDBClusterPerformanceRequest::setStartTime(const std::string &startTime) {
|
||||
startTime_ = startTime;
|
||||
setParameter(std::string("StartTime"), startTime);
|
||||
}
|
||||
|
||||
std::string DescribeDBClusterPerformanceRequest::getAccessKeyId() const {
|
||||
return accessKeyId_;
|
||||
}
|
||||
|
||||
void DescribeDBClusterPerformanceRequest::setAccessKeyId(const std::string &accessKeyId) {
|
||||
accessKeyId_ = accessKeyId;
|
||||
setParameter(std::string("AccessKeyId"), accessKeyId);
|
||||
}
|
||||
|
||||
std::string DescribeDBClusterPerformanceRequest::getKey() const {
|
||||
return key_;
|
||||
}
|
||||
|
||||
void DescribeDBClusterPerformanceRequest::setKey(const std::string &key) {
|
||||
key_ = key;
|
||||
setParameter(std::string("Key"), key);
|
||||
}
|
||||
|
||||
std::string DescribeDBClusterPerformanceRequest::getResourceOwnerAccount() const {
|
||||
return resourceOwnerAccount_;
|
||||
}
|
||||
@@ -97,6 +70,15 @@ void DescribeDBClusterPerformanceRequest::setEndTime(const std::string &endTime)
|
||||
setParameter(std::string("EndTime"), endTime);
|
||||
}
|
||||
|
||||
std::string DescribeDBClusterPerformanceRequest::getStartTime() const {
|
||||
return startTime_;
|
||||
}
|
||||
|
||||
void DescribeDBClusterPerformanceRequest::setStartTime(const std::string &startTime) {
|
||||
startTime_ = startTime;
|
||||
setParameter(std::string("StartTime"), startTime);
|
||||
}
|
||||
|
||||
long DescribeDBClusterPerformanceRequest::getOwnerId() const {
|
||||
return ownerId_;
|
||||
}
|
||||
@@ -106,3 +88,39 @@ void DescribeDBClusterPerformanceRequest::setOwnerId(long ownerId) {
|
||||
setParameter(std::string("OwnerId"), std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::string DescribeDBClusterPerformanceRequest::getAccessKeyId() const {
|
||||
return accessKeyId_;
|
||||
}
|
||||
|
||||
void DescribeDBClusterPerformanceRequest::setAccessKeyId(const std::string &accessKeyId) {
|
||||
accessKeyId_ = accessKeyId;
|
||||
setParameter(std::string("AccessKeyId"), accessKeyId);
|
||||
}
|
||||
|
||||
std::string DescribeDBClusterPerformanceRequest::getRegionId() const {
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void DescribeDBClusterPerformanceRequest::setRegionId(const std::string ®ionId) {
|
||||
regionId_ = regionId;
|
||||
setParameter(std::string("RegionId"), regionId);
|
||||
}
|
||||
|
||||
std::string DescribeDBClusterPerformanceRequest::getResourcePools() const {
|
||||
return resourcePools_;
|
||||
}
|
||||
|
||||
void DescribeDBClusterPerformanceRequest::setResourcePools(const std::string &resourcePools) {
|
||||
resourcePools_ = resourcePools;
|
||||
setParameter(std::string("ResourcePools"), resourcePools);
|
||||
}
|
||||
|
||||
std::string DescribeDBClusterPerformanceRequest::getKey() const {
|
||||
return key_;
|
||||
}
|
||||
|
||||
void DescribeDBClusterPerformanceRequest::setKey(const std::string &key) {
|
||||
key_ = key;
|
||||
setParameter(std::string("Key"), key);
|
||||
}
|
||||
|
||||
|
||||
@@ -53,6 +53,8 @@ void DescribeDBClusterPerformanceResult::parse(const std::string &payload)
|
||||
PerformanceItem::SeriesItem seriesObject;
|
||||
if(!valuePerformancesPerformanceItemSeriesSeriesItem["Name"].isNull())
|
||||
seriesObject.name = valuePerformancesPerformanceItemSeriesSeriesItem["Name"].asString();
|
||||
if(!valuePerformancesPerformanceItemSeriesSeriesItem["Tags"].isNull())
|
||||
seriesObject.tags = valuePerformancesPerformanceItemSeriesSeriesItem["Tags"].asString();
|
||||
auto allValues = value["Values"]["Values"];
|
||||
for (auto value : allValues)
|
||||
seriesObject.values.push_back(value.asString());
|
||||
|
||||
@@ -1,81 +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 <alibabacloud/adb/model/DescribeSQLPatternAttributeRequest.h>
|
||||
|
||||
using AlibabaCloud::Adb::Model::DescribeSQLPatternAttributeRequest;
|
||||
|
||||
DescribeSQLPatternAttributeRequest::DescribeSQLPatternAttributeRequest()
|
||||
: RpcServiceRequest("adb", "2019-03-15", "DescribeSQLPatternAttribute") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DescribeSQLPatternAttributeRequest::~DescribeSQLPatternAttributeRequest() {}
|
||||
|
||||
std::string DescribeSQLPatternAttributeRequest::getDBClusterId() const {
|
||||
return dBClusterId_;
|
||||
}
|
||||
|
||||
void DescribeSQLPatternAttributeRequest::setDBClusterId(const std::string &dBClusterId) {
|
||||
dBClusterId_ = dBClusterId;
|
||||
setParameter(std::string("DBClusterId"), dBClusterId);
|
||||
}
|
||||
|
||||
long DescribeSQLPatternAttributeRequest::getPatternId() const {
|
||||
return patternId_;
|
||||
}
|
||||
|
||||
void DescribeSQLPatternAttributeRequest::setPatternId(long patternId) {
|
||||
patternId_ = patternId;
|
||||
setParameter(std::string("PatternId"), std::to_string(patternId));
|
||||
}
|
||||
|
||||
std::string DescribeSQLPatternAttributeRequest::getEndTime() const {
|
||||
return endTime_;
|
||||
}
|
||||
|
||||
void DescribeSQLPatternAttributeRequest::setEndTime(const std::string &endTime) {
|
||||
endTime_ = endTime;
|
||||
setParameter(std::string("EndTime"), endTime);
|
||||
}
|
||||
|
||||
std::string DescribeSQLPatternAttributeRequest::getStartTime() const {
|
||||
return startTime_;
|
||||
}
|
||||
|
||||
void DescribeSQLPatternAttributeRequest::setStartTime(const std::string &startTime) {
|
||||
startTime_ = startTime;
|
||||
setParameter(std::string("StartTime"), startTime);
|
||||
}
|
||||
|
||||
std::string DescribeSQLPatternAttributeRequest::getRegionId() const {
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void DescribeSQLPatternAttributeRequest::setRegionId(const std::string ®ionId) {
|
||||
regionId_ = regionId;
|
||||
setParameter(std::string("RegionId"), regionId);
|
||||
}
|
||||
|
||||
std::string DescribeSQLPatternAttributeRequest::getLang() const {
|
||||
return lang_;
|
||||
}
|
||||
|
||||
void DescribeSQLPatternAttributeRequest::setLang(const std::string &lang) {
|
||||
lang_ = lang;
|
||||
setParameter(std::string("Lang"), lang);
|
||||
}
|
||||
|
||||
@@ -1,60 +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 <alibabacloud/adb/model/DescribeSQLPatternAttributeResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Adb;
|
||||
using namespace AlibabaCloud::Adb::Model;
|
||||
|
||||
DescribeSQLPatternAttributeResult::DescribeSQLPatternAttributeResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DescribeSQLPatternAttributeResult::DescribeSQLPatternAttributeResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DescribeSQLPatternAttributeResult::~DescribeSQLPatternAttributeResult()
|
||||
{}
|
||||
|
||||
void DescribeSQLPatternAttributeResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto patternDetailNode = value["PatternDetail"];
|
||||
if(!patternDetailNode["SQLPattern"].isNull())
|
||||
patternDetail_.sQLPattern = patternDetailNode["SQLPattern"].asString();
|
||||
if(!patternDetailNode["QueryCount"].isNull())
|
||||
patternDetail_.queryCount = std::stol(patternDetailNode["QueryCount"].asString());
|
||||
if(!patternDetailNode["TotalQueryTime"].isNull())
|
||||
patternDetail_.totalQueryTime = patternDetailNode["TotalQueryTime"].asString();
|
||||
if(!patternDetailNode["AverageQueryTime"].isNull())
|
||||
patternDetail_.averageQueryTime = patternDetailNode["AverageQueryTime"].asString();
|
||||
if(!patternDetailNode["AverageMemory"].isNull())
|
||||
patternDetail_.averageMemory = patternDetailNode["AverageMemory"].asString();
|
||||
|
||||
}
|
||||
|
||||
DescribeSQLPatternAttributeResult::PatternDetail DescribeSQLPatternAttributeResult::getPatternDetail()const
|
||||
{
|
||||
return patternDetail_;
|
||||
}
|
||||
|
||||
117
adb/src/model/DescribeVSwitchesRequest.cc
Normal file
117
adb/src/model/DescribeVSwitchesRequest.cc
Normal file
@@ -0,0 +1,117 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/adb/model/DescribeVSwitchesRequest.h>
|
||||
|
||||
using AlibabaCloud::Adb::Model::DescribeVSwitchesRequest;
|
||||
|
||||
DescribeVSwitchesRequest::DescribeVSwitchesRequest()
|
||||
: RpcServiceRequest("adb", "2019-03-15", "DescribeVSwitches") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DescribeVSwitchesRequest::~DescribeVSwitchesRequest() {}
|
||||
|
||||
std::string DescribeVSwitchesRequest::getVswId() const {
|
||||
return vswId_;
|
||||
}
|
||||
|
||||
void DescribeVSwitchesRequest::setVswId(const std::string &vswId) {
|
||||
vswId_ = vswId;
|
||||
setParameter(std::string("VswId"), vswId);
|
||||
}
|
||||
|
||||
long DescribeVSwitchesRequest::getResourceOwnerId() const {
|
||||
return resourceOwnerId_;
|
||||
}
|
||||
|
||||
void DescribeVSwitchesRequest::setResourceOwnerId(long resourceOwnerId) {
|
||||
resourceOwnerId_ = resourceOwnerId;
|
||||
setParameter(std::string("ResourceOwnerId"), std::to_string(resourceOwnerId));
|
||||
}
|
||||
|
||||
std::string DescribeVSwitchesRequest::getAccessKeyId() const {
|
||||
return accessKeyId_;
|
||||
}
|
||||
|
||||
void DescribeVSwitchesRequest::setAccessKeyId(const std::string &accessKeyId) {
|
||||
accessKeyId_ = accessKeyId;
|
||||
setParameter(std::string("AccessKeyId"), accessKeyId);
|
||||
}
|
||||
|
||||
std::string DescribeVSwitchesRequest::getSecurityToken() const {
|
||||
return securityToken_;
|
||||
}
|
||||
|
||||
void DescribeVSwitchesRequest::setSecurityToken(const std::string &securityToken) {
|
||||
securityToken_ = securityToken;
|
||||
setParameter(std::string("SecurityToken"), securityToken);
|
||||
}
|
||||
|
||||
std::string DescribeVSwitchesRequest::getRegionId() const {
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void DescribeVSwitchesRequest::setRegionId(const std::string ®ionId) {
|
||||
regionId_ = regionId;
|
||||
setParameter(std::string("RegionId"), regionId);
|
||||
}
|
||||
|
||||
std::string DescribeVSwitchesRequest::getResourceOwnerAccount() const {
|
||||
return resourceOwnerAccount_;
|
||||
}
|
||||
|
||||
void DescribeVSwitchesRequest::setResourceOwnerAccount(const std::string &resourceOwnerAccount) {
|
||||
resourceOwnerAccount_ = resourceOwnerAccount;
|
||||
setParameter(std::string("ResourceOwnerAccount"), resourceOwnerAccount);
|
||||
}
|
||||
|
||||
std::string DescribeVSwitchesRequest::getOwnerAccount() const {
|
||||
return ownerAccount_;
|
||||
}
|
||||
|
||||
void DescribeVSwitchesRequest::setOwnerAccount(const std::string &ownerAccount) {
|
||||
ownerAccount_ = ownerAccount;
|
||||
setParameter(std::string("OwnerAccount"), ownerAccount);
|
||||
}
|
||||
|
||||
long DescribeVSwitchesRequest::getOwnerId() const {
|
||||
return ownerId_;
|
||||
}
|
||||
|
||||
void DescribeVSwitchesRequest::setOwnerId(long ownerId) {
|
||||
ownerId_ = ownerId;
|
||||
setParameter(std::string("OwnerId"), std::to_string(ownerId));
|
||||
}
|
||||
|
||||
std::string DescribeVSwitchesRequest::getVpcId() const {
|
||||
return vpcId_;
|
||||
}
|
||||
|
||||
void DescribeVSwitchesRequest::setVpcId(const std::string &vpcId) {
|
||||
vpcId_ = vpcId;
|
||||
setParameter(std::string("VpcId"), vpcId);
|
||||
}
|
||||
|
||||
std::string DescribeVSwitchesRequest::getZoneId() const {
|
||||
return zoneId_;
|
||||
}
|
||||
|
||||
void DescribeVSwitchesRequest::setZoneId(const std::string &zoneId) {
|
||||
zoneId_ = zoneId;
|
||||
setParameter(std::string("ZoneId"), zoneId);
|
||||
}
|
||||
|
||||
78
adb/src/model/DescribeVSwitchesResult.cc
Normal file
78
adb/src/model/DescribeVSwitchesResult.cc
Normal file
@@ -0,0 +1,78 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/adb/model/DescribeVSwitchesResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Adb;
|
||||
using namespace AlibabaCloud::Adb::Model;
|
||||
|
||||
DescribeVSwitchesResult::DescribeVSwitchesResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DescribeVSwitchesResult::DescribeVSwitchesResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DescribeVSwitchesResult::~DescribeVSwitchesResult()
|
||||
{}
|
||||
|
||||
void DescribeVSwitchesResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto vSwitchesNode = value["VSwitches"];
|
||||
auto allVSwitchNode = vSwitchesNode["VSwitch"]["VSwitchItem"];
|
||||
for (auto vSwitchesNodeVSwitchVSwitchItem : allVSwitchNode)
|
||||
{
|
||||
VSwitches::VSwitchItem vSwitchItemObject;
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["Status"].isNull())
|
||||
vSwitchItemObject.status = vSwitchesNodeVSwitchVSwitchItem["Status"].asString();
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["IsDefault"].isNull())
|
||||
vSwitchItemObject.isDefault = vSwitchesNodeVSwitchVSwitchItem["IsDefault"].asString() == "true";
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["VSwitchId"].isNull())
|
||||
vSwitchItemObject.vSwitchId = vSwitchesNodeVSwitchVSwitchItem["VSwitchId"].asString();
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["CidrBlock"].isNull())
|
||||
vSwitchItemObject.cidrBlock = vSwitchesNodeVSwitchVSwitchItem["CidrBlock"].asString();
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["RegionNo"].isNull())
|
||||
vSwitchItemObject.regionNo = vSwitchesNodeVSwitchVSwitchItem["RegionNo"].asString();
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["GmtCreate"].isNull())
|
||||
vSwitchItemObject.gmtCreate = vSwitchesNodeVSwitchVSwitchItem["GmtCreate"].asString();
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["AliUid"].isNull())
|
||||
vSwitchItemObject.aliUid = vSwitchesNodeVSwitchVSwitchItem["AliUid"].asString();
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["GmtModified"].isNull())
|
||||
vSwitchItemObject.gmtModified = vSwitchesNodeVSwitchVSwitchItem["GmtModified"].asString();
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["Bid"].isNull())
|
||||
vSwitchItemObject.bid = vSwitchesNodeVSwitchVSwitchItem["Bid"].asString();
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["IzNo"].isNull())
|
||||
vSwitchItemObject.izNo = vSwitchesNodeVSwitchVSwitchItem["IzNo"].asString();
|
||||
if(!vSwitchesNodeVSwitchVSwitchItem["VSwitchName"].isNull())
|
||||
vSwitchItemObject.vSwitchName = vSwitchesNodeVSwitchVSwitchItem["VSwitchName"].asString();
|
||||
vSwitches_.vSwitch.push_back(vSwitchItemObject);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
DescribeVSwitchesResult::VSwitches DescribeVSwitchesResult::getVSwitches()const
|
||||
{
|
||||
return vSwitches_;
|
||||
}
|
||||
|
||||
@@ -1,171 +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 <alibabacloud/adb/model/DryRunClusterRequest.h>
|
||||
|
||||
using AlibabaCloud::Adb::Model::DryRunClusterRequest;
|
||||
|
||||
DryRunClusterRequest::DryRunClusterRequest()
|
||||
: RpcServiceRequest("adb", "2019-03-15", "DryRunCluster") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DryRunClusterRequest::~DryRunClusterRequest() {}
|
||||
|
||||
std::string DryRunClusterRequest::getDBClusterDescription() const {
|
||||
return dBClusterDescription_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setDBClusterDescription(const std::string &dBClusterDescription) {
|
||||
dBClusterDescription_ = dBClusterDescription;
|
||||
setParameter(std::string("DBClusterDescription"), dBClusterDescription);
|
||||
}
|
||||
|
||||
bool DryRunClusterRequest::getEnableDefaultResourcePool() const {
|
||||
return enableDefaultResourcePool_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setEnableDefaultResourcePool(bool enableDefaultResourcePool) {
|
||||
enableDefaultResourcePool_ = enableDefaultResourcePool;
|
||||
setParameter(std::string("EnableDefaultResourcePool"), enableDefaultResourcePool ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getAccessKeyId() const {
|
||||
return accessKeyId_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setAccessKeyId(const std::string &accessKeyId) {
|
||||
accessKeyId_ = accessKeyId;
|
||||
setParameter(std::string("AccessKeyId"), accessKeyId);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getStorageResource() const {
|
||||
return storageResource_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setStorageResource(const std::string &storageResource) {
|
||||
storageResource_ = storageResource;
|
||||
setParameter(std::string("StorageResource"), storageResource);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getRegionId() const {
|
||||
return regionId_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setRegionId(const std::string ®ionId) {
|
||||
regionId_ = regionId;
|
||||
setParameter(std::string("RegionId"), regionId);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getDBClusterNetworkType() const {
|
||||
return dBClusterNetworkType_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setDBClusterNetworkType(const std::string &dBClusterNetworkType) {
|
||||
dBClusterNetworkType_ = dBClusterNetworkType;
|
||||
setParameter(std::string("DBClusterNetworkType"), dBClusterNetworkType);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getPeriod() const {
|
||||
return period_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setPeriod(const std::string &period) {
|
||||
period_ = period;
|
||||
setParameter(std::string("Period"), period);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getDBClusterId() const {
|
||||
return dBClusterId_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setDBClusterId(const std::string &dBClusterId) {
|
||||
dBClusterId_ = dBClusterId;
|
||||
setParameter(std::string("DBClusterId"), dBClusterId);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getDBClusterVersion() const {
|
||||
return dBClusterVersion_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setDBClusterVersion(const std::string &dBClusterVersion) {
|
||||
dBClusterVersion_ = dBClusterVersion;
|
||||
setParameter(std::string("DBClusterVersion"), dBClusterVersion);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getUsedTime() const {
|
||||
return usedTime_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setUsedTime(const std::string &usedTime) {
|
||||
usedTime_ = usedTime;
|
||||
setParameter(std::string("UsedTime"), usedTime);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getVSwitchId() const {
|
||||
return vSwitchId_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setVSwitchId(const std::string &vSwitchId) {
|
||||
vSwitchId_ = vSwitchId;
|
||||
setParameter(std::string("VSwitchId"), vSwitchId);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getVPCId() const {
|
||||
return vPCId_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setVPCId(const std::string &vPCId) {
|
||||
vPCId_ = vPCId;
|
||||
setParameter(std::string("VPCId"), vPCId);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getZoneId() const {
|
||||
return zoneId_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setZoneId(const std::string &zoneId) {
|
||||
zoneId_ = zoneId;
|
||||
setParameter(std::string("ZoneId"), zoneId);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getComputeResource() const {
|
||||
return computeResource_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setComputeResource(const std::string &computeResource) {
|
||||
computeResource_ = computeResource;
|
||||
setParameter(std::string("ComputeResource"), computeResource);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getPayType() const {
|
||||
return payType_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setPayType(const std::string &payType) {
|
||||
payType_ = payType;
|
||||
setParameter(std::string("PayType"), payType);
|
||||
}
|
||||
|
||||
std::string DryRunClusterRequest::getOperation() const {
|
||||
return operation_;
|
||||
}
|
||||
|
||||
void DryRunClusterRequest::setOperation(const std::string &operation) {
|
||||
operation_ = operation;
|
||||
setParameter(std::string("Operation"), operation);
|
||||
}
|
||||
|
||||
@@ -1,51 +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 <alibabacloud/adb/model/DryRunClusterResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Adb;
|
||||
using namespace AlibabaCloud::Adb::Model;
|
||||
|
||||
DryRunClusterResult::DryRunClusterResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DryRunClusterResult::DryRunClusterResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DryRunClusterResult::~DryRunClusterResult()
|
||||
{}
|
||||
|
||||
void DryRunClusterResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
if(!value["Success"].isNull())
|
||||
success_ = value["Success"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
bool DryRunClusterResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
110
aicontent/CMakeLists.txt
Normal file
110
aicontent/CMakeLists.txt
Normal file
@@ -0,0 +1,110 @@
|
||||
#
|
||||
# Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
set(public_header_dir ${CMAKE_CURRENT_SOURCE_DIR}/../include)
|
||||
|
||||
set(aicontent_public_header
|
||||
include/alibabacloud/aicontent/AiContentClient.h
|
||||
include/alibabacloud/aicontent/AiContentExport.h )
|
||||
|
||||
set(aicontent_public_header_model
|
||||
include/alibabacloud/aicontent/model/AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest.h
|
||||
include/alibabacloud/aicontent/model/AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgAddInferenceJobRequest.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgAddInferenceJobResult.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgAddModelTrainJobRequest.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgAddModelTrainJobResult.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgQueryImageAssetRequest.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgQueryImageAssetResult.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgQueryInferenceJobInfoRequest.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgQueryInferenceJobInfoResult.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgQueryModelTrainJobListRequest.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgQueryModelTrainJobListResult.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgQueryModelTrainStatusRequest.h
|
||||
include/alibabacloud/aicontent/model/Personalizedtxt2imgQueryModelTrainStatusResult.h )
|
||||
|
||||
set(aicontent_src
|
||||
src/AiContentClient.cc
|
||||
src/model/AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest.cc
|
||||
src/model/AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult.cc
|
||||
src/model/Personalizedtxt2imgAddInferenceJobRequest.cc
|
||||
src/model/Personalizedtxt2imgAddInferenceJobResult.cc
|
||||
src/model/Personalizedtxt2imgAddModelTrainJobRequest.cc
|
||||
src/model/Personalizedtxt2imgAddModelTrainJobResult.cc
|
||||
src/model/Personalizedtxt2imgQueryImageAssetRequest.cc
|
||||
src/model/Personalizedtxt2imgQueryImageAssetResult.cc
|
||||
src/model/Personalizedtxt2imgQueryInferenceJobInfoRequest.cc
|
||||
src/model/Personalizedtxt2imgQueryInferenceJobInfoResult.cc
|
||||
src/model/Personalizedtxt2imgQueryModelTrainJobListRequest.cc
|
||||
src/model/Personalizedtxt2imgQueryModelTrainJobListResult.cc
|
||||
src/model/Personalizedtxt2imgQueryModelTrainStatusRequest.cc
|
||||
src/model/Personalizedtxt2imgQueryModelTrainStatusResult.cc )
|
||||
|
||||
add_library(aicontent ${LIB_TYPE}
|
||||
${aicontent_public_header}
|
||||
${aicontent_public_header_model}
|
||||
${aicontent_src})
|
||||
|
||||
set_target_properties(aicontent
|
||||
PROPERTIES
|
||||
LINKER_LANGUAGE CXX
|
||||
ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
|
||||
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
|
||||
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
|
||||
OUTPUT_NAME ${TARGET_OUTPUT_NAME_PREFIX}aicontent
|
||||
)
|
||||
|
||||
if(${LIB_TYPE} STREQUAL "SHARED")
|
||||
set_target_properties(aicontent
|
||||
PROPERTIES
|
||||
DEFINE_SYMBOL ALIBABACLOUD_AICONTENT_LIBRARY)
|
||||
endif()
|
||||
|
||||
target_include_directories(aicontent
|
||||
PRIVATE include
|
||||
${CMAKE_SOURCE_DIR}/core/include
|
||||
)
|
||||
target_link_libraries(aicontent
|
||||
core)
|
||||
|
||||
if(CMAKE_HOST_WIN32)
|
||||
ExternalProject_Get_Property(jsoncpp INSTALL_DIR)
|
||||
set(jsoncpp_install_dir ${INSTALL_DIR})
|
||||
add_dependencies(aicontent
|
||||
jsoncpp)
|
||||
target_include_directories(aicontent
|
||||
PRIVATE ${jsoncpp_install_dir}/include)
|
||||
target_link_libraries(aicontent
|
||||
${jsoncpp_install_dir}/lib/jsoncpp.lib)
|
||||
set_target_properties(aicontent
|
||||
PROPERTIES
|
||||
COMPILE_OPTIONS "/bigobj")
|
||||
else()
|
||||
target_include_directories(aicontent
|
||||
PRIVATE /usr/include/jsoncpp)
|
||||
target_link_libraries(aicontent
|
||||
jsoncpp)
|
||||
endif()
|
||||
|
||||
install(FILES ${aicontent_public_header}
|
||||
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/aicontent)
|
||||
install(FILES ${aicontent_public_header_model}
|
||||
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/aicontent/model)
|
||||
install(TARGETS aicontent
|
||||
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
|
||||
)
|
||||
102
aicontent/include/alibabacloud/aicontent/AiContentClient.h
Normal file
102
aicontent/include/alibabacloud/aicontent/AiContentClient.h
Normal file
@@ -0,0 +1,102 @@
|
||||
/*
|
||||
* 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_AICONTENT_AICONTENTCLIENT_H_
|
||||
#define ALIBABACLOUD_AICONTENT_AICONTENTCLIENT_H_
|
||||
|
||||
#include <future>
|
||||
#include <alibabacloud/core/AsyncCallerContext.h>
|
||||
#include <alibabacloud/core/EndpointProvider.h>
|
||||
#include <alibabacloud/core/RoaServiceClient.h>
|
||||
#include "AiContentExport.h"
|
||||
#include "model/AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest.h"
|
||||
#include "model/AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult.h"
|
||||
#include "model/Personalizedtxt2imgAddInferenceJobRequest.h"
|
||||
#include "model/Personalizedtxt2imgAddInferenceJobResult.h"
|
||||
#include "model/Personalizedtxt2imgAddModelTrainJobRequest.h"
|
||||
#include "model/Personalizedtxt2imgAddModelTrainJobResult.h"
|
||||
#include "model/Personalizedtxt2imgQueryImageAssetRequest.h"
|
||||
#include "model/Personalizedtxt2imgQueryImageAssetResult.h"
|
||||
#include "model/Personalizedtxt2imgQueryInferenceJobInfoRequest.h"
|
||||
#include "model/Personalizedtxt2imgQueryInferenceJobInfoResult.h"
|
||||
#include "model/Personalizedtxt2imgQueryModelTrainJobListRequest.h"
|
||||
#include "model/Personalizedtxt2imgQueryModelTrainJobListResult.h"
|
||||
#include "model/Personalizedtxt2imgQueryModelTrainStatusRequest.h"
|
||||
#include "model/Personalizedtxt2imgQueryModelTrainStatusResult.h"
|
||||
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AiContent
|
||||
{
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT AiContentClient : public RoaServiceClient
|
||||
{
|
||||
public:
|
||||
typedef Outcome<Error, Model::AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult> AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcome;
|
||||
typedef std::future<AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcome> AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcomeCallable;
|
||||
typedef std::function<void(const AiContentClient*, const Model::AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest&, const AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> AliyunConsoleOpenApiQueryAliyunConsoleServcieListAsyncHandler;
|
||||
typedef Outcome<Error, Model::Personalizedtxt2imgAddInferenceJobResult> Personalizedtxt2imgAddInferenceJobOutcome;
|
||||
typedef std::future<Personalizedtxt2imgAddInferenceJobOutcome> Personalizedtxt2imgAddInferenceJobOutcomeCallable;
|
||||
typedef std::function<void(const AiContentClient*, const Model::Personalizedtxt2imgAddInferenceJobRequest&, const Personalizedtxt2imgAddInferenceJobOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> Personalizedtxt2imgAddInferenceJobAsyncHandler;
|
||||
typedef Outcome<Error, Model::Personalizedtxt2imgAddModelTrainJobResult> Personalizedtxt2imgAddModelTrainJobOutcome;
|
||||
typedef std::future<Personalizedtxt2imgAddModelTrainJobOutcome> Personalizedtxt2imgAddModelTrainJobOutcomeCallable;
|
||||
typedef std::function<void(const AiContentClient*, const Model::Personalizedtxt2imgAddModelTrainJobRequest&, const Personalizedtxt2imgAddModelTrainJobOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> Personalizedtxt2imgAddModelTrainJobAsyncHandler;
|
||||
typedef Outcome<Error, Model::Personalizedtxt2imgQueryImageAssetResult> Personalizedtxt2imgQueryImageAssetOutcome;
|
||||
typedef std::future<Personalizedtxt2imgQueryImageAssetOutcome> Personalizedtxt2imgQueryImageAssetOutcomeCallable;
|
||||
typedef std::function<void(const AiContentClient*, const Model::Personalizedtxt2imgQueryImageAssetRequest&, const Personalizedtxt2imgQueryImageAssetOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> Personalizedtxt2imgQueryImageAssetAsyncHandler;
|
||||
typedef Outcome<Error, Model::Personalizedtxt2imgQueryInferenceJobInfoResult> Personalizedtxt2imgQueryInferenceJobInfoOutcome;
|
||||
typedef std::future<Personalizedtxt2imgQueryInferenceJobInfoOutcome> Personalizedtxt2imgQueryInferenceJobInfoOutcomeCallable;
|
||||
typedef std::function<void(const AiContentClient*, const Model::Personalizedtxt2imgQueryInferenceJobInfoRequest&, const Personalizedtxt2imgQueryInferenceJobInfoOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> Personalizedtxt2imgQueryInferenceJobInfoAsyncHandler;
|
||||
typedef Outcome<Error, Model::Personalizedtxt2imgQueryModelTrainJobListResult> Personalizedtxt2imgQueryModelTrainJobListOutcome;
|
||||
typedef std::future<Personalizedtxt2imgQueryModelTrainJobListOutcome> Personalizedtxt2imgQueryModelTrainJobListOutcomeCallable;
|
||||
typedef std::function<void(const AiContentClient*, const Model::Personalizedtxt2imgQueryModelTrainJobListRequest&, const Personalizedtxt2imgQueryModelTrainJobListOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> Personalizedtxt2imgQueryModelTrainJobListAsyncHandler;
|
||||
typedef Outcome<Error, Model::Personalizedtxt2imgQueryModelTrainStatusResult> Personalizedtxt2imgQueryModelTrainStatusOutcome;
|
||||
typedef std::future<Personalizedtxt2imgQueryModelTrainStatusOutcome> Personalizedtxt2imgQueryModelTrainStatusOutcomeCallable;
|
||||
typedef std::function<void(const AiContentClient*, const Model::Personalizedtxt2imgQueryModelTrainStatusRequest&, const Personalizedtxt2imgQueryModelTrainStatusOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> Personalizedtxt2imgQueryModelTrainStatusAsyncHandler;
|
||||
|
||||
AiContentClient(const Credentials &credentials, const ClientConfiguration &configuration);
|
||||
AiContentClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider, const ClientConfiguration &configuration);
|
||||
AiContentClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration);
|
||||
~AiContentClient();
|
||||
AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcome aliyunConsoleOpenApiQueryAliyunConsoleServcieList(const Model::AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest &request)const;
|
||||
void aliyunConsoleOpenApiQueryAliyunConsoleServcieListAsync(const Model::AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest& request, const AliyunConsoleOpenApiQueryAliyunConsoleServcieListAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcomeCallable aliyunConsoleOpenApiQueryAliyunConsoleServcieListCallable(const Model::AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest& request) const;
|
||||
Personalizedtxt2imgAddInferenceJobOutcome personalizedtxt2imgAddInferenceJob(const Model::Personalizedtxt2imgAddInferenceJobRequest &request)const;
|
||||
void personalizedtxt2imgAddInferenceJobAsync(const Model::Personalizedtxt2imgAddInferenceJobRequest& request, const Personalizedtxt2imgAddInferenceJobAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
Personalizedtxt2imgAddInferenceJobOutcomeCallable personalizedtxt2imgAddInferenceJobCallable(const Model::Personalizedtxt2imgAddInferenceJobRequest& request) const;
|
||||
Personalizedtxt2imgAddModelTrainJobOutcome personalizedtxt2imgAddModelTrainJob(const Model::Personalizedtxt2imgAddModelTrainJobRequest &request)const;
|
||||
void personalizedtxt2imgAddModelTrainJobAsync(const Model::Personalizedtxt2imgAddModelTrainJobRequest& request, const Personalizedtxt2imgAddModelTrainJobAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
Personalizedtxt2imgAddModelTrainJobOutcomeCallable personalizedtxt2imgAddModelTrainJobCallable(const Model::Personalizedtxt2imgAddModelTrainJobRequest& request) const;
|
||||
Personalizedtxt2imgQueryImageAssetOutcome personalizedtxt2imgQueryImageAsset(const Model::Personalizedtxt2imgQueryImageAssetRequest &request)const;
|
||||
void personalizedtxt2imgQueryImageAssetAsync(const Model::Personalizedtxt2imgQueryImageAssetRequest& request, const Personalizedtxt2imgQueryImageAssetAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
Personalizedtxt2imgQueryImageAssetOutcomeCallable personalizedtxt2imgQueryImageAssetCallable(const Model::Personalizedtxt2imgQueryImageAssetRequest& request) const;
|
||||
Personalizedtxt2imgQueryInferenceJobInfoOutcome personalizedtxt2imgQueryInferenceJobInfo(const Model::Personalizedtxt2imgQueryInferenceJobInfoRequest &request)const;
|
||||
void personalizedtxt2imgQueryInferenceJobInfoAsync(const Model::Personalizedtxt2imgQueryInferenceJobInfoRequest& request, const Personalizedtxt2imgQueryInferenceJobInfoAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
Personalizedtxt2imgQueryInferenceJobInfoOutcomeCallable personalizedtxt2imgQueryInferenceJobInfoCallable(const Model::Personalizedtxt2imgQueryInferenceJobInfoRequest& request) const;
|
||||
Personalizedtxt2imgQueryModelTrainJobListOutcome personalizedtxt2imgQueryModelTrainJobList(const Model::Personalizedtxt2imgQueryModelTrainJobListRequest &request)const;
|
||||
void personalizedtxt2imgQueryModelTrainJobListAsync(const Model::Personalizedtxt2imgQueryModelTrainJobListRequest& request, const Personalizedtxt2imgQueryModelTrainJobListAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
Personalizedtxt2imgQueryModelTrainJobListOutcomeCallable personalizedtxt2imgQueryModelTrainJobListCallable(const Model::Personalizedtxt2imgQueryModelTrainJobListRequest& request) const;
|
||||
Personalizedtxt2imgQueryModelTrainStatusOutcome personalizedtxt2imgQueryModelTrainStatus(const Model::Personalizedtxt2imgQueryModelTrainStatusRequest &request)const;
|
||||
void personalizedtxt2imgQueryModelTrainStatusAsync(const Model::Personalizedtxt2imgQueryModelTrainStatusRequest& request, const Personalizedtxt2imgQueryModelTrainStatusAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
Personalizedtxt2imgQueryModelTrainStatusOutcomeCallable personalizedtxt2imgQueryModelTrainStatusCallable(const Model::Personalizedtxt2imgQueryModelTrainStatusRequest& request) const;
|
||||
|
||||
private:
|
||||
std::shared_ptr<EndpointProvider> endpointProvider_;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
#endif // !ALIBABACLOUD_AICONTENT_AICONTENTCLIENT_H_
|
||||
32
aicontent/include/alibabacloud/aicontent/AiContentExport.h
Normal file
32
aicontent/include/alibabacloud/aicontent/AiContentExport.h
Normal file
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AICONTENT_AICONTENTEXPORT_H_
|
||||
#define ALIBABACLOUD_AICONTENT_AICONTENTEXPORT_H_
|
||||
|
||||
#include <alibabacloud/core/Global.h>
|
||||
|
||||
#if defined(ALIBABACLOUD_SHARED)
|
||||
# if defined(ALIBABACLOUD_AICONTENT_LIBRARY)
|
||||
# define ALIBABACLOUD_AICONTENT_EXPORT ALIBABACLOUD_DECL_EXPORT
|
||||
# else
|
||||
# define ALIBABACLOUD_AICONTENT_EXPORT ALIBABACLOUD_DECL_IMPORT
|
||||
# endif
|
||||
#else
|
||||
# define ALIBABACLOUD_AICONTENT_EXPORT
|
||||
#endif
|
||||
|
||||
#endif // !ALIBABACLOUD_AICONTENT_AICONTENTEXPORT_H_
|
||||
@@ -0,0 +1,39 @@
|
||||
/*
|
||||
* 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_AICONTENT_MODEL_ALIYUNCONSOLEOPENAPIQUERYALIYUNCONSOLESERVCIELISTREQUEST_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_ALIYUNCONSOLEOPENAPIQUERYALIYUNCONSOLESERVCIELISTREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
#include <alibabacloud/core/RoaServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AiContent {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest : public RoaServiceRequest {
|
||||
public:
|
||||
AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest();
|
||||
~AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest();
|
||||
|
||||
private:
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AiContent
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_ALIYUNCONSOLEOPENAPIQUERYALIYUNCONSOLESERVCIELISTREQUEST_H_
|
||||
@@ -0,0 +1,68 @@
|
||||
/*
|
||||
* 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_AICONTENT_MODEL_ALIYUNCONSOLEOPENAPIQUERYALIYUNCONSOLESERVCIELISTRESULT_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_ALIYUNCONSOLEOPENAPIQUERYALIYUNCONSOLESERVCIELISTRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AiContent
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct DataItem
|
||||
{
|
||||
std::string serviceCode;
|
||||
std::string serviceName;
|
||||
int freeConcurrencyCount;
|
||||
int freeCount;
|
||||
};
|
||||
|
||||
|
||||
AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult();
|
||||
explicit AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult(const std::string &payload);
|
||||
~AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult();
|
||||
std::vector<DataItem> getdata()const;
|
||||
std::string getRequestId()const;
|
||||
int getHttpStatusCode()const;
|
||||
std::string getErrMessage()const;
|
||||
bool getSuccess()const;
|
||||
std::string getErrCode()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::vector<DataItem> data_;
|
||||
std::string requestId_;
|
||||
int httpStatusCode_;
|
||||
std::string errMessage_;
|
||||
bool success_;
|
||||
std::string errCode_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_ALIYUNCONSOLEOPENAPIQUERYALIYUNCONSOLESERVCIELISTRESULT_H_
|
||||
@@ -0,0 +1,42 @@
|
||||
/*
|
||||
* 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_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDINFERENCEJOBREQUEST_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDINFERENCEJOBREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
#include <alibabacloud/core/RoaServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AiContent {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgAddInferenceJobRequest : public RoaServiceRequest {
|
||||
public:
|
||||
Personalizedtxt2imgAddInferenceJobRequest();
|
||||
~Personalizedtxt2imgAddInferenceJobRequest();
|
||||
std::string getBody() const;
|
||||
void setBody(const std::string &body);
|
||||
|
||||
private:
|
||||
std::string body_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AiContent
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDINFERENCEJOBREQUEST_H_
|
||||
@@ -0,0 +1,71 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDINFERENCEJOBRESULT_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDINFERENCEJOBRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AiContent
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgAddInferenceJobResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string jobStatus;
|
||||
double jobTrainProgress;
|
||||
std::string createTime;
|
||||
std::string id;
|
||||
std::vector<std::string> resultImageUrl;
|
||||
std::string promptId;
|
||||
std::string modelId;
|
||||
};
|
||||
|
||||
|
||||
Personalizedtxt2imgAddInferenceJobResult();
|
||||
explicit Personalizedtxt2imgAddInferenceJobResult(const std::string &payload);
|
||||
~Personalizedtxt2imgAddInferenceJobResult();
|
||||
std::string getRequestId()const;
|
||||
int getHttpStatusCode()const;
|
||||
Data getData()const;
|
||||
std::string getErrMessage()const;
|
||||
bool getSuccess()const;
|
||||
std::string getErrCode()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string requestId_;
|
||||
int httpStatusCode_;
|
||||
Data data_;
|
||||
std::string errMessage_;
|
||||
bool success_;
|
||||
std::string errCode_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDINFERENCEJOBRESULT_H_
|
||||
@@ -0,0 +1,42 @@
|
||||
/*
|
||||
* 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_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDMODELTRAINJOBREQUEST_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDMODELTRAINJOBREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
#include <alibabacloud/core/RoaServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AiContent {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgAddModelTrainJobRequest : public RoaServiceRequest {
|
||||
public:
|
||||
Personalizedtxt2imgAddModelTrainJobRequest();
|
||||
~Personalizedtxt2imgAddModelTrainJobRequest();
|
||||
std::string getBody() const;
|
||||
void setBody(const std::string &body);
|
||||
|
||||
private:
|
||||
std::string body_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AiContent
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDMODELTRAINJOBREQUEST_H_
|
||||
@@ -0,0 +1,84 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDMODELTRAINJOBRESULT_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDMODELTRAINJOBRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AiContent
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgAddModelTrainJobResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
struct InferenceJobListItem
|
||||
{
|
||||
std::string jobStatus;
|
||||
double jobTrainProgress;
|
||||
std::string createTime;
|
||||
std::string id;
|
||||
std::vector<std::string> resultImageUrl;
|
||||
std::string promptId;
|
||||
std::string modelId;
|
||||
};
|
||||
std::string jobStatus;
|
||||
std::string objectType;
|
||||
double jobTrainProgress;
|
||||
std::string createTime;
|
||||
std::vector<std::string> imageUrl;
|
||||
std::string id;
|
||||
int inferenceImageCount;
|
||||
std::vector<InferenceJobListItem> inferenceJobList;
|
||||
std::string modelId;
|
||||
std::string name;
|
||||
};
|
||||
|
||||
|
||||
Personalizedtxt2imgAddModelTrainJobResult();
|
||||
explicit Personalizedtxt2imgAddModelTrainJobResult(const std::string &payload);
|
||||
~Personalizedtxt2imgAddModelTrainJobResult();
|
||||
std::string getRequestId()const;
|
||||
int getHttpStatusCode()const;
|
||||
Data getData()const;
|
||||
std::string getErrMessage()const;
|
||||
bool getSuccess()const;
|
||||
std::string getErrCode()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string requestId_;
|
||||
int httpStatusCode_;
|
||||
Data data_;
|
||||
std::string errMessage_;
|
||||
bool success_;
|
||||
std::string errCode_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGADDMODELTRAINJOBRESULT_H_
|
||||
@@ -0,0 +1,51 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYIMAGEASSETREQUEST_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYIMAGEASSETREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
#include <alibabacloud/core/RoaServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AiContent {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgQueryImageAssetRequest : public RoaServiceRequest {
|
||||
public:
|
||||
Personalizedtxt2imgQueryImageAssetRequest();
|
||||
~Personalizedtxt2imgQueryImageAssetRequest();
|
||||
std::string getImageId() const;
|
||||
void setImageId(const std::string &imageId);
|
||||
std::string getModelId() const;
|
||||
void setModelId(const std::string &modelId);
|
||||
std::string getEncodeFormat() const;
|
||||
void setEncodeFormat(const std::string &encodeFormat);
|
||||
std::string getPromptId() const;
|
||||
void setPromptId(const std::string &promptId);
|
||||
|
||||
private:
|
||||
std::string imageId_;
|
||||
std::string modelId_;
|
||||
std::string encodeFormat_;
|
||||
std::string promptId_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AiContent
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYIMAGEASSETREQUEST_H_
|
||||
@@ -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_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYIMAGEASSETRESULT_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYIMAGEASSETRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AiContent
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgQueryImageAssetResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
Personalizedtxt2imgQueryImageAssetResult();
|
||||
explicit Personalizedtxt2imgQueryImageAssetResult(const std::string &payload);
|
||||
~Personalizedtxt2imgQueryImageAssetResult();
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYIMAGEASSETRESULT_H_
|
||||
@@ -0,0 +1,42 @@
|
||||
/*
|
||||
* 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_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYINFERENCEJOBINFOREQUEST_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYINFERENCEJOBINFOREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
#include <alibabacloud/core/RoaServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AiContent {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgQueryInferenceJobInfoRequest : public RoaServiceRequest {
|
||||
public:
|
||||
Personalizedtxt2imgQueryInferenceJobInfoRequest();
|
||||
~Personalizedtxt2imgQueryInferenceJobInfoRequest();
|
||||
std::string getInferenceJobId() const;
|
||||
void setInferenceJobId(const std::string &inferenceJobId);
|
||||
|
||||
private:
|
||||
std::string inferenceJobId_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AiContent
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYINFERENCEJOBINFOREQUEST_H_
|
||||
@@ -0,0 +1,71 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYINFERENCEJOBINFORESULT_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYINFERENCEJOBINFORESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AiContent
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgQueryInferenceJobInfoResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string jobStatus;
|
||||
double jobTrainProgress;
|
||||
std::string createTime;
|
||||
std::string id;
|
||||
std::vector<std::string> resultImageUrl;
|
||||
std::string promptId;
|
||||
std::string modelId;
|
||||
};
|
||||
|
||||
|
||||
Personalizedtxt2imgQueryInferenceJobInfoResult();
|
||||
explicit Personalizedtxt2imgQueryInferenceJobInfoResult(const std::string &payload);
|
||||
~Personalizedtxt2imgQueryInferenceJobInfoResult();
|
||||
std::string getRequestId()const;
|
||||
int getHttpStatusCode()const;
|
||||
Data getData()const;
|
||||
std::string getErrMessage()const;
|
||||
bool getSuccess()const;
|
||||
std::string getErrCode()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string requestId_;
|
||||
int httpStatusCode_;
|
||||
Data data_;
|
||||
std::string errMessage_;
|
||||
bool success_;
|
||||
std::string errCode_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYINFERENCEJOBINFORESULT_H_
|
||||
@@ -0,0 +1,39 @@
|
||||
/*
|
||||
* 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_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINJOBLISTREQUEST_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINJOBLISTREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
#include <alibabacloud/core/RoaServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AiContent {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgQueryModelTrainJobListRequest : public RoaServiceRequest {
|
||||
public:
|
||||
Personalizedtxt2imgQueryModelTrainJobListRequest();
|
||||
~Personalizedtxt2imgQueryModelTrainJobListRequest();
|
||||
|
||||
private:
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AiContent
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINJOBLISTREQUEST_H_
|
||||
@@ -0,0 +1,84 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINJOBLISTRESULT_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINJOBLISTRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AiContent
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgQueryModelTrainJobListResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct DataItem
|
||||
{
|
||||
struct InferenceJobListItem
|
||||
{
|
||||
std::string jobStatus;
|
||||
double jobTrainProgress;
|
||||
std::string createTime;
|
||||
std::string id;
|
||||
std::vector<std::string> resultImageUrl;
|
||||
std::string promptId;
|
||||
std::string modelId;
|
||||
};
|
||||
std::string jobStatus;
|
||||
std::string objectType;
|
||||
double jobTrainProgress;
|
||||
std::string createTime;
|
||||
std::vector<std::string> imageUrl;
|
||||
std::string id;
|
||||
int inferenceImageCount;
|
||||
std::vector<DataItem::InferenceJobListItem> inferenceJobList;
|
||||
std::string modelId;
|
||||
std::string name;
|
||||
};
|
||||
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainJobListResult();
|
||||
explicit Personalizedtxt2imgQueryModelTrainJobListResult(const std::string &payload);
|
||||
~Personalizedtxt2imgQueryModelTrainJobListResult();
|
||||
std::vector<DataItem> getdata()const;
|
||||
std::string getRequestId()const;
|
||||
int getHttpStatusCode()const;
|
||||
std::string getErrMessage()const;
|
||||
bool getSuccess()const;
|
||||
std::string getErrCode()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::vector<DataItem> data_;
|
||||
std::string requestId_;
|
||||
int httpStatusCode_;
|
||||
std::string errMessage_;
|
||||
bool success_;
|
||||
std::string errCode_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINJOBLISTRESULT_H_
|
||||
@@ -0,0 +1,42 @@
|
||||
/*
|
||||
* 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_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINSTATUSREQUEST_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINSTATUSREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
#include <alibabacloud/core/RoaServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace AiContent {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgQueryModelTrainStatusRequest : public RoaServiceRequest {
|
||||
public:
|
||||
Personalizedtxt2imgQueryModelTrainStatusRequest();
|
||||
~Personalizedtxt2imgQueryModelTrainStatusRequest();
|
||||
std::string getModelId() const;
|
||||
void setModelId(const std::string &modelId);
|
||||
|
||||
private:
|
||||
std::string modelId_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace AiContent
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINSTATUSREQUEST_H_
|
||||
@@ -0,0 +1,65 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINSTATUSRESULT_H_
|
||||
#define ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINSTATUSRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aicontent/AiContentExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace AiContent
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AICONTENT_EXPORT Personalizedtxt2imgQueryModelTrainStatusResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string modelTrainStatus;
|
||||
};
|
||||
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainStatusResult();
|
||||
explicit Personalizedtxt2imgQueryModelTrainStatusResult(const std::string &payload);
|
||||
~Personalizedtxt2imgQueryModelTrainStatusResult();
|
||||
std::string getRequestId()const;
|
||||
int getHttpStatusCode()const;
|
||||
Data getData()const;
|
||||
std::string getErrMessage()const;
|
||||
bool getSuccess()const;
|
||||
std::string getErrCode()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string requestId_;
|
||||
int httpStatusCode_;
|
||||
Data data_;
|
||||
std::string errMessage_;
|
||||
bool success_;
|
||||
std::string errCode_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AICONTENT_MODEL_PERSONALIZEDTXT2IMGQUERYMODELTRAINSTATUSRESULT_H_
|
||||
305
aicontent/src/AiContentClient.cc
Normal file
305
aicontent/src/AiContentClient.cc
Normal file
@@ -0,0 +1,305 @@
|
||||
/*
|
||||
* 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/aicontent/AiContentClient.h>
|
||||
#include <alibabacloud/core/SimpleCredentialsProvider.h>
|
||||
|
||||
using namespace AlibabaCloud;
|
||||
using namespace AlibabaCloud::Location;
|
||||
using namespace AlibabaCloud::AiContent;
|
||||
using namespace AlibabaCloud::AiContent::Model;
|
||||
|
||||
namespace
|
||||
{
|
||||
const std::string SERVICE_NAME = "AiContent";
|
||||
}
|
||||
|
||||
AiContentClient::AiContentClient(const Credentials &credentials, const ClientConfiguration &configuration) :
|
||||
RoaServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(credentials), configuration)
|
||||
{
|
||||
auto locationClient = std::make_shared<LocationClient>(credentials, configuration);
|
||||
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
|
||||
}
|
||||
|
||||
AiContentClient::AiContentClient(const std::shared_ptr<CredentialsProvider>& credentialsProvider, const ClientConfiguration & configuration) :
|
||||
RoaServiceClient(SERVICE_NAME, credentialsProvider, configuration)
|
||||
{
|
||||
auto locationClient = std::make_shared<LocationClient>(credentialsProvider, configuration);
|
||||
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
|
||||
}
|
||||
|
||||
AiContentClient::AiContentClient(const std::string & accessKeyId, const std::string & accessKeySecret, const ClientConfiguration & configuration) :
|
||||
RoaServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(accessKeyId, accessKeySecret), configuration)
|
||||
{
|
||||
auto locationClient = std::make_shared<LocationClient>(accessKeyId, accessKeySecret, configuration);
|
||||
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
|
||||
}
|
||||
|
||||
AiContentClient::~AiContentClient()
|
||||
{}
|
||||
|
||||
AiContentClient::AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcome AiContentClient::aliyunConsoleOpenApiQueryAliyunConsoleServcieList(const AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcome(AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult(outcome.result()));
|
||||
else
|
||||
return AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AiContentClient::aliyunConsoleOpenApiQueryAliyunConsoleServcieListAsync(const AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest& request, const AliyunConsoleOpenApiQueryAliyunConsoleServcieListAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, aliyunConsoleOpenApiQueryAliyunConsoleServcieList(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AiContentClient::AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcomeCallable AiContentClient::aliyunConsoleOpenApiQueryAliyunConsoleServcieListCallable(const AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<AliyunConsoleOpenApiQueryAliyunConsoleServcieListOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->aliyunConsoleOpenApiQueryAliyunConsoleServcieList(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgAddInferenceJobOutcome AiContentClient::personalizedtxt2imgAddInferenceJob(const Personalizedtxt2imgAddInferenceJobRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return Personalizedtxt2imgAddInferenceJobOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return Personalizedtxt2imgAddInferenceJobOutcome(Personalizedtxt2imgAddInferenceJobResult(outcome.result()));
|
||||
else
|
||||
return Personalizedtxt2imgAddInferenceJobOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AiContentClient::personalizedtxt2imgAddInferenceJobAsync(const Personalizedtxt2imgAddInferenceJobRequest& request, const Personalizedtxt2imgAddInferenceJobAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, personalizedtxt2imgAddInferenceJob(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgAddInferenceJobOutcomeCallable AiContentClient::personalizedtxt2imgAddInferenceJobCallable(const Personalizedtxt2imgAddInferenceJobRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<Personalizedtxt2imgAddInferenceJobOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->personalizedtxt2imgAddInferenceJob(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgAddModelTrainJobOutcome AiContentClient::personalizedtxt2imgAddModelTrainJob(const Personalizedtxt2imgAddModelTrainJobRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return Personalizedtxt2imgAddModelTrainJobOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return Personalizedtxt2imgAddModelTrainJobOutcome(Personalizedtxt2imgAddModelTrainJobResult(outcome.result()));
|
||||
else
|
||||
return Personalizedtxt2imgAddModelTrainJobOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AiContentClient::personalizedtxt2imgAddModelTrainJobAsync(const Personalizedtxt2imgAddModelTrainJobRequest& request, const Personalizedtxt2imgAddModelTrainJobAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, personalizedtxt2imgAddModelTrainJob(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgAddModelTrainJobOutcomeCallable AiContentClient::personalizedtxt2imgAddModelTrainJobCallable(const Personalizedtxt2imgAddModelTrainJobRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<Personalizedtxt2imgAddModelTrainJobOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->personalizedtxt2imgAddModelTrainJob(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgQueryImageAssetOutcome AiContentClient::personalizedtxt2imgQueryImageAsset(const Personalizedtxt2imgQueryImageAssetRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return Personalizedtxt2imgQueryImageAssetOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return Personalizedtxt2imgQueryImageAssetOutcome(Personalizedtxt2imgQueryImageAssetResult(outcome.result()));
|
||||
else
|
||||
return Personalizedtxt2imgQueryImageAssetOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AiContentClient::personalizedtxt2imgQueryImageAssetAsync(const Personalizedtxt2imgQueryImageAssetRequest& request, const Personalizedtxt2imgQueryImageAssetAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, personalizedtxt2imgQueryImageAsset(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgQueryImageAssetOutcomeCallable AiContentClient::personalizedtxt2imgQueryImageAssetCallable(const Personalizedtxt2imgQueryImageAssetRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<Personalizedtxt2imgQueryImageAssetOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->personalizedtxt2imgQueryImageAsset(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgQueryInferenceJobInfoOutcome AiContentClient::personalizedtxt2imgQueryInferenceJobInfo(const Personalizedtxt2imgQueryInferenceJobInfoRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return Personalizedtxt2imgQueryInferenceJobInfoOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return Personalizedtxt2imgQueryInferenceJobInfoOutcome(Personalizedtxt2imgQueryInferenceJobInfoResult(outcome.result()));
|
||||
else
|
||||
return Personalizedtxt2imgQueryInferenceJobInfoOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AiContentClient::personalizedtxt2imgQueryInferenceJobInfoAsync(const Personalizedtxt2imgQueryInferenceJobInfoRequest& request, const Personalizedtxt2imgQueryInferenceJobInfoAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, personalizedtxt2imgQueryInferenceJobInfo(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgQueryInferenceJobInfoOutcomeCallable AiContentClient::personalizedtxt2imgQueryInferenceJobInfoCallable(const Personalizedtxt2imgQueryInferenceJobInfoRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<Personalizedtxt2imgQueryInferenceJobInfoOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->personalizedtxt2imgQueryInferenceJobInfo(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgQueryModelTrainJobListOutcome AiContentClient::personalizedtxt2imgQueryModelTrainJobList(const Personalizedtxt2imgQueryModelTrainJobListRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return Personalizedtxt2imgQueryModelTrainJobListOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return Personalizedtxt2imgQueryModelTrainJobListOutcome(Personalizedtxt2imgQueryModelTrainJobListResult(outcome.result()));
|
||||
else
|
||||
return Personalizedtxt2imgQueryModelTrainJobListOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AiContentClient::personalizedtxt2imgQueryModelTrainJobListAsync(const Personalizedtxt2imgQueryModelTrainJobListRequest& request, const Personalizedtxt2imgQueryModelTrainJobListAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, personalizedtxt2imgQueryModelTrainJobList(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgQueryModelTrainJobListOutcomeCallable AiContentClient::personalizedtxt2imgQueryModelTrainJobListCallable(const Personalizedtxt2imgQueryModelTrainJobListRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<Personalizedtxt2imgQueryModelTrainJobListOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->personalizedtxt2imgQueryModelTrainJobList(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgQueryModelTrainStatusOutcome AiContentClient::personalizedtxt2imgQueryModelTrainStatus(const Personalizedtxt2imgQueryModelTrainStatusRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return Personalizedtxt2imgQueryModelTrainStatusOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return Personalizedtxt2imgQueryModelTrainStatusOutcome(Personalizedtxt2imgQueryModelTrainStatusResult(outcome.result()));
|
||||
else
|
||||
return Personalizedtxt2imgQueryModelTrainStatusOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AiContentClient::personalizedtxt2imgQueryModelTrainStatusAsync(const Personalizedtxt2imgQueryModelTrainStatusRequest& request, const Personalizedtxt2imgQueryModelTrainStatusAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, personalizedtxt2imgQueryModelTrainStatus(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AiContentClient::Personalizedtxt2imgQueryModelTrainStatusOutcomeCallable AiContentClient::personalizedtxt2imgQueryModelTrainStatusCallable(const Personalizedtxt2imgQueryModelTrainStatusRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<Personalizedtxt2imgQueryModelTrainStatusOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->personalizedtxt2imgQueryModelTrainStatus(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* 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/aicontent/model/AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest.h>
|
||||
|
||||
using AlibabaCloud::AiContent::Model::AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest;
|
||||
|
||||
AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest::AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest()
|
||||
: RoaServiceRequest("aicontent", "20240611") {
|
||||
setResourcePath("/api/v1/aliyunconsole/queryAliyunConsoleServcieList"};
|
||||
setMethod(HttpRequest::Method::Get);
|
||||
}
|
||||
|
||||
AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest::~AliyunConsoleOpenApiQueryAliyunConsoleServcieListRequest() {}
|
||||
|
||||
@@ -0,0 +1,98 @@
|
||||
/*
|
||||
* 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/aicontent/model/AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AiContent;
|
||||
using namespace AlibabaCloud::AiContent::Model;
|
||||
|
||||
AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::~AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult()
|
||||
{}
|
||||
|
||||
void AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto alldataNode = value["data"]["dataItem"];
|
||||
for (auto valuedatadataItem : alldataNode)
|
||||
{
|
||||
DataItem dataObject;
|
||||
if(!valuedatadataItem["ServiceCode"].isNull())
|
||||
dataObject.serviceCode = valuedatadataItem["ServiceCode"].asString();
|
||||
if(!valuedatadataItem["ServiceName"].isNull())
|
||||
dataObject.serviceName = valuedatadataItem["ServiceName"].asString();
|
||||
if(!valuedatadataItem["FreeCount"].isNull())
|
||||
dataObject.freeCount = std::stoi(valuedatadataItem["FreeCount"].asString());
|
||||
if(!valuedatadataItem["FreeConcurrencyCount"].isNull())
|
||||
dataObject.freeConcurrencyCount = std::stoi(valuedatadataItem["FreeConcurrencyCount"].asString());
|
||||
data_.push_back(dataObject);
|
||||
}
|
||||
if(!value["requestId"].isNull())
|
||||
requestId_ = value["requestId"].asString();
|
||||
if(!value["success"].isNull())
|
||||
success_ = value["success"].asString() == "true";
|
||||
if(!value["errCode"].isNull())
|
||||
errCode_ = value["errCode"].asString();
|
||||
if(!value["errMessage"].isNull())
|
||||
errMessage_ = value["errMessage"].asString();
|
||||
if(!value["httpStatusCode"].isNull())
|
||||
httpStatusCode_ = std::stoi(value["httpStatusCode"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::vector<AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::DataItem> AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::getdata()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::getRequestId()const
|
||||
{
|
||||
return requestId_;
|
||||
}
|
||||
|
||||
int AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::getHttpStatusCode()const
|
||||
{
|
||||
return httpStatusCode_;
|
||||
}
|
||||
|
||||
std::string AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::getErrMessage()const
|
||||
{
|
||||
return errMessage_;
|
||||
}
|
||||
|
||||
bool AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
std::string AliyunConsoleOpenApiQueryAliyunConsoleServcieListResult::getErrCode()const
|
||||
{
|
||||
return errCode_;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
/*
|
||||
* 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/aicontent/model/Personalizedtxt2imgAddInferenceJobRequest.h>
|
||||
|
||||
using AlibabaCloud::AiContent::Model::Personalizedtxt2imgAddInferenceJobRequest;
|
||||
|
||||
Personalizedtxt2imgAddInferenceJobRequest::Personalizedtxt2imgAddInferenceJobRequest()
|
||||
: RoaServiceRequest("aicontent", "20240611") {
|
||||
setResourcePath("/api/v1/personalizedtxt2img/addInferenceJob"};
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgAddInferenceJobRequest::~Personalizedtxt2imgAddInferenceJobRequest() {}
|
||||
|
||||
std::string Personalizedtxt2imgAddInferenceJobRequest::getBody() const {
|
||||
return body_;
|
||||
}
|
||||
|
||||
void Personalizedtxt2imgAddInferenceJobRequest::setBody(const std::string &body) {
|
||||
body_ = body;
|
||||
setBodyParameter(std::string("body"), body);
|
||||
}
|
||||
|
||||
100
aicontent/src/model/Personalizedtxt2imgAddInferenceJobResult.cc
Normal file
100
aicontent/src/model/Personalizedtxt2imgAddInferenceJobResult.cc
Normal file
@@ -0,0 +1,100 @@
|
||||
/*
|
||||
* 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/aicontent/model/Personalizedtxt2imgAddInferenceJobResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AiContent;
|
||||
using namespace AlibabaCloud::AiContent::Model;
|
||||
|
||||
Personalizedtxt2imgAddInferenceJobResult::Personalizedtxt2imgAddInferenceJobResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
Personalizedtxt2imgAddInferenceJobResult::Personalizedtxt2imgAddInferenceJobResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgAddInferenceJobResult::~Personalizedtxt2imgAddInferenceJobResult()
|
||||
{}
|
||||
|
||||
void Personalizedtxt2imgAddInferenceJobResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["data"];
|
||||
if(!dataNode["id"].isNull())
|
||||
data_.id = dataNode["id"].asString();
|
||||
if(!dataNode["promptId"].isNull())
|
||||
data_.promptId = dataNode["promptId"].asString();
|
||||
if(!dataNode["modelId"].isNull())
|
||||
data_.modelId = dataNode["modelId"].asString();
|
||||
if(!dataNode["jobStatus"].isNull())
|
||||
data_.jobStatus = dataNode["jobStatus"].asString();
|
||||
if(!dataNode["jobTrainProgress"].isNull())
|
||||
data_.jobTrainProgress = dataNode["jobTrainProgress"].asString();
|
||||
if(!dataNode["createTime"].isNull())
|
||||
data_.createTime = dataNode["createTime"].asString();
|
||||
auto allResultImageUrl = dataNode["resultImageUrl"]["resultImageUrl"];
|
||||
for (auto value : allResultImageUrl)
|
||||
data_.resultImageUrl.push_back(value.asString());
|
||||
if(!value["requestId"].isNull())
|
||||
requestId_ = value["requestId"].asString();
|
||||
if(!value["success"].isNull())
|
||||
success_ = value["success"].asString() == "true";
|
||||
if(!value["errCode"].isNull())
|
||||
errCode_ = value["errCode"].asString();
|
||||
if(!value["errMessage"].isNull())
|
||||
errMessage_ = value["errMessage"].asString();
|
||||
if(!value["httpStatusCode"].isNull())
|
||||
httpStatusCode_ = std::stoi(value["httpStatusCode"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgAddInferenceJobResult::getRequestId()const
|
||||
{
|
||||
return requestId_;
|
||||
}
|
||||
|
||||
int Personalizedtxt2imgAddInferenceJobResult::getHttpStatusCode()const
|
||||
{
|
||||
return httpStatusCode_;
|
||||
}
|
||||
|
||||
Personalizedtxt2imgAddInferenceJobResult::Data Personalizedtxt2imgAddInferenceJobResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgAddInferenceJobResult::getErrMessage()const
|
||||
{
|
||||
return errMessage_;
|
||||
}
|
||||
|
||||
bool Personalizedtxt2imgAddInferenceJobResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgAddInferenceJobResult::getErrCode()const
|
||||
{
|
||||
return errCode_;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
/*
|
||||
* 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/aicontent/model/Personalizedtxt2imgAddModelTrainJobRequest.h>
|
||||
|
||||
using AlibabaCloud::AiContent::Model::Personalizedtxt2imgAddModelTrainJobRequest;
|
||||
|
||||
Personalizedtxt2imgAddModelTrainJobRequest::Personalizedtxt2imgAddModelTrainJobRequest()
|
||||
: RoaServiceRequest("aicontent", "20240611") {
|
||||
setResourcePath("/api/v1/personalizedtxt2img/addModelTrainJob"};
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgAddModelTrainJobRequest::~Personalizedtxt2imgAddModelTrainJobRequest() {}
|
||||
|
||||
std::string Personalizedtxt2imgAddModelTrainJobRequest::getBody() const {
|
||||
return body_;
|
||||
}
|
||||
|
||||
void Personalizedtxt2imgAddModelTrainJobRequest::setBody(const std::string &body) {
|
||||
body_ = body;
|
||||
setBodyParameter(std::string("body"), body);
|
||||
}
|
||||
|
||||
125
aicontent/src/model/Personalizedtxt2imgAddModelTrainJobResult.cc
Normal file
125
aicontent/src/model/Personalizedtxt2imgAddModelTrainJobResult.cc
Normal file
@@ -0,0 +1,125 @@
|
||||
/*
|
||||
* 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/aicontent/model/Personalizedtxt2imgAddModelTrainJobResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AiContent;
|
||||
using namespace AlibabaCloud::AiContent::Model;
|
||||
|
||||
Personalizedtxt2imgAddModelTrainJobResult::Personalizedtxt2imgAddModelTrainJobResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
Personalizedtxt2imgAddModelTrainJobResult::Personalizedtxt2imgAddModelTrainJobResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgAddModelTrainJobResult::~Personalizedtxt2imgAddModelTrainJobResult()
|
||||
{}
|
||||
|
||||
void Personalizedtxt2imgAddModelTrainJobResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["data"];
|
||||
if(!dataNode["id"].isNull())
|
||||
data_.id = dataNode["id"].asString();
|
||||
if(!dataNode["modelId"].isNull())
|
||||
data_.modelId = dataNode["modelId"].asString();
|
||||
if(!dataNode["name"].isNull())
|
||||
data_.name = dataNode["name"].asString();
|
||||
if(!dataNode["objectType"].isNull())
|
||||
data_.objectType = dataNode["objectType"].asString();
|
||||
if(!dataNode["jobStatus"].isNull())
|
||||
data_.jobStatus = dataNode["jobStatus"].asString();
|
||||
if(!dataNode["jobTrainProgress"].isNull())
|
||||
data_.jobTrainProgress = dataNode["jobTrainProgress"].asString();
|
||||
if(!dataNode["inferenceImageCount"].isNull())
|
||||
data_.inferenceImageCount = std::stoi(dataNode["inferenceImageCount"].asString());
|
||||
if(!dataNode["createTime"].isNull())
|
||||
data_.createTime = dataNode["createTime"].asString();
|
||||
auto allinferenceJobListNode = dataNode["inferenceJobList"]["inferenceJobListItem"];
|
||||
for (auto dataNodeinferenceJobListinferenceJobListItem : allinferenceJobListNode)
|
||||
{
|
||||
Data::InferenceJobListItem inferenceJobListItemObject;
|
||||
if(!dataNodeinferenceJobListinferenceJobListItem["id"].isNull())
|
||||
inferenceJobListItemObject.id = dataNodeinferenceJobListinferenceJobListItem["id"].asString();
|
||||
if(!dataNodeinferenceJobListinferenceJobListItem["promptId"].isNull())
|
||||
inferenceJobListItemObject.promptId = dataNodeinferenceJobListinferenceJobListItem["promptId"].asString();
|
||||
if(!dataNodeinferenceJobListinferenceJobListItem["modelId"].isNull())
|
||||
inferenceJobListItemObject.modelId = dataNodeinferenceJobListinferenceJobListItem["modelId"].asString();
|
||||
if(!dataNodeinferenceJobListinferenceJobListItem["jobStatus"].isNull())
|
||||
inferenceJobListItemObject.jobStatus = dataNodeinferenceJobListinferenceJobListItem["jobStatus"].asString();
|
||||
if(!dataNodeinferenceJobListinferenceJobListItem["jobTrainProgress"].isNull())
|
||||
inferenceJobListItemObject.jobTrainProgress = dataNodeinferenceJobListinferenceJobListItem["jobTrainProgress"].asString();
|
||||
if(!dataNodeinferenceJobListinferenceJobListItem["createTime"].isNull())
|
||||
inferenceJobListItemObject.createTime = dataNodeinferenceJobListinferenceJobListItem["createTime"].asString();
|
||||
auto allResultImageUrl = value["resultImageUrl"]["resultImageUrl"];
|
||||
for (auto value : allResultImageUrl)
|
||||
inferenceJobListItemObject.resultImageUrl.push_back(value.asString());
|
||||
data_.inferenceJobList.push_back(inferenceJobListItemObject);
|
||||
}
|
||||
auto allImageUrl = dataNode["imageUrl"]["imageUrl"];
|
||||
for (auto value : allImageUrl)
|
||||
data_.imageUrl.push_back(value.asString());
|
||||
if(!value["requestId"].isNull())
|
||||
requestId_ = value["requestId"].asString();
|
||||
if(!value["success"].isNull())
|
||||
success_ = value["success"].asString() == "true";
|
||||
if(!value["errCode"].isNull())
|
||||
errCode_ = value["errCode"].asString();
|
||||
if(!value["errMessage"].isNull())
|
||||
errMessage_ = value["errMessage"].asString();
|
||||
if(!value["httpStatusCode"].isNull())
|
||||
httpStatusCode_ = std::stoi(value["httpStatusCode"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgAddModelTrainJobResult::getRequestId()const
|
||||
{
|
||||
return requestId_;
|
||||
}
|
||||
|
||||
int Personalizedtxt2imgAddModelTrainJobResult::getHttpStatusCode()const
|
||||
{
|
||||
return httpStatusCode_;
|
||||
}
|
||||
|
||||
Personalizedtxt2imgAddModelTrainJobResult::Data Personalizedtxt2imgAddModelTrainJobResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgAddModelTrainJobResult::getErrMessage()const
|
||||
{
|
||||
return errMessage_;
|
||||
}
|
||||
|
||||
bool Personalizedtxt2imgAddModelTrainJobResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgAddModelTrainJobResult::getErrCode()const
|
||||
{
|
||||
return errCode_;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,64 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/aicontent/model/Personalizedtxt2imgQueryImageAssetRequest.h>
|
||||
|
||||
using AlibabaCloud::AiContent::Model::Personalizedtxt2imgQueryImageAssetRequest;
|
||||
|
||||
Personalizedtxt2imgQueryImageAssetRequest::Personalizedtxt2imgQueryImageAssetRequest()
|
||||
: RoaServiceRequest("aicontent", "20240611") {
|
||||
setResourcePath("/api/v1/personalizedtxt2img/queryImageAsset"};
|
||||
setMethod(HttpRequest::Method::Get);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgQueryImageAssetRequest::~Personalizedtxt2imgQueryImageAssetRequest() {}
|
||||
|
||||
std::string Personalizedtxt2imgQueryImageAssetRequest::getImageId() const {
|
||||
return imageId_;
|
||||
}
|
||||
|
||||
void Personalizedtxt2imgQueryImageAssetRequest::setImageId(const std::string &imageId) {
|
||||
imageId_ = imageId;
|
||||
setParameter(std::string("imageId"), imageId);
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryImageAssetRequest::getModelId() const {
|
||||
return modelId_;
|
||||
}
|
||||
|
||||
void Personalizedtxt2imgQueryImageAssetRequest::setModelId(const std::string &modelId) {
|
||||
modelId_ = modelId;
|
||||
setParameter(std::string("modelId"), modelId);
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryImageAssetRequest::getEncodeFormat() const {
|
||||
return encodeFormat_;
|
||||
}
|
||||
|
||||
void Personalizedtxt2imgQueryImageAssetRequest::setEncodeFormat(const std::string &encodeFormat) {
|
||||
encodeFormat_ = encodeFormat;
|
||||
setParameter(std::string("encodeFormat"), encodeFormat);
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryImageAssetRequest::getPromptId() const {
|
||||
return promptId_;
|
||||
}
|
||||
|
||||
void Personalizedtxt2imgQueryImageAssetRequest::setPromptId(const std::string &promptId) {
|
||||
promptId_ = promptId;
|
||||
setParameter(std::string("promptId"), promptId);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,44 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/aicontent/model/Personalizedtxt2imgQueryImageAssetResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AiContent;
|
||||
using namespace AlibabaCloud::AiContent::Model;
|
||||
|
||||
Personalizedtxt2imgQueryImageAssetResult::Personalizedtxt2imgQueryImageAssetResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
Personalizedtxt2imgQueryImageAssetResult::Personalizedtxt2imgQueryImageAssetResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgQueryImageAssetResult::~Personalizedtxt2imgQueryImageAssetResult()
|
||||
{}
|
||||
|
||||
void Personalizedtxt2imgQueryImageAssetResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
/*
|
||||
* 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/aicontent/model/Personalizedtxt2imgQueryInferenceJobInfoRequest.h>
|
||||
|
||||
using AlibabaCloud::AiContent::Model::Personalizedtxt2imgQueryInferenceJobInfoRequest;
|
||||
|
||||
Personalizedtxt2imgQueryInferenceJobInfoRequest::Personalizedtxt2imgQueryInferenceJobInfoRequest()
|
||||
: RoaServiceRequest("aicontent", "20240611") {
|
||||
setResourcePath("/api/v1/personalizedtxt2img/queryInferenceJobInfo"};
|
||||
setMethod(HttpRequest::Method::Get);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgQueryInferenceJobInfoRequest::~Personalizedtxt2imgQueryInferenceJobInfoRequest() {}
|
||||
|
||||
std::string Personalizedtxt2imgQueryInferenceJobInfoRequest::getInferenceJobId() const {
|
||||
return inferenceJobId_;
|
||||
}
|
||||
|
||||
void Personalizedtxt2imgQueryInferenceJobInfoRequest::setInferenceJobId(const std::string &inferenceJobId) {
|
||||
inferenceJobId_ = inferenceJobId;
|
||||
setParameter(std::string("inferenceJobId"), inferenceJobId);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,100 @@
|
||||
/*
|
||||
* 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/aicontent/model/Personalizedtxt2imgQueryInferenceJobInfoResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AiContent;
|
||||
using namespace AlibabaCloud::AiContent::Model;
|
||||
|
||||
Personalizedtxt2imgQueryInferenceJobInfoResult::Personalizedtxt2imgQueryInferenceJobInfoResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
Personalizedtxt2imgQueryInferenceJobInfoResult::Personalizedtxt2imgQueryInferenceJobInfoResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgQueryInferenceJobInfoResult::~Personalizedtxt2imgQueryInferenceJobInfoResult()
|
||||
{}
|
||||
|
||||
void Personalizedtxt2imgQueryInferenceJobInfoResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["data"];
|
||||
if(!dataNode["id"].isNull())
|
||||
data_.id = dataNode["id"].asString();
|
||||
if(!dataNode["promptId"].isNull())
|
||||
data_.promptId = dataNode["promptId"].asString();
|
||||
if(!dataNode["modelId"].isNull())
|
||||
data_.modelId = dataNode["modelId"].asString();
|
||||
if(!dataNode["jobStatus"].isNull())
|
||||
data_.jobStatus = dataNode["jobStatus"].asString();
|
||||
if(!dataNode["jobTrainProgress"].isNull())
|
||||
data_.jobTrainProgress = dataNode["jobTrainProgress"].asString();
|
||||
if(!dataNode["createTime"].isNull())
|
||||
data_.createTime = dataNode["createTime"].asString();
|
||||
auto allResultImageUrl = dataNode["resultImageUrl"]["resultImageUrl"];
|
||||
for (auto value : allResultImageUrl)
|
||||
data_.resultImageUrl.push_back(value.asString());
|
||||
if(!value["requestId"].isNull())
|
||||
requestId_ = value["requestId"].asString();
|
||||
if(!value["success"].isNull())
|
||||
success_ = value["success"].asString() == "true";
|
||||
if(!value["errCode"].isNull())
|
||||
errCode_ = value["errCode"].asString();
|
||||
if(!value["errMessage"].isNull())
|
||||
errMessage_ = value["errMessage"].asString();
|
||||
if(!value["httpStatusCode"].isNull())
|
||||
httpStatusCode_ = std::stoi(value["httpStatusCode"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryInferenceJobInfoResult::getRequestId()const
|
||||
{
|
||||
return requestId_;
|
||||
}
|
||||
|
||||
int Personalizedtxt2imgQueryInferenceJobInfoResult::getHttpStatusCode()const
|
||||
{
|
||||
return httpStatusCode_;
|
||||
}
|
||||
|
||||
Personalizedtxt2imgQueryInferenceJobInfoResult::Data Personalizedtxt2imgQueryInferenceJobInfoResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryInferenceJobInfoResult::getErrMessage()const
|
||||
{
|
||||
return errMessage_;
|
||||
}
|
||||
|
||||
bool Personalizedtxt2imgQueryInferenceJobInfoResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryInferenceJobInfoResult::getErrCode()const
|
||||
{
|
||||
return errCode_;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* 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/aicontent/model/Personalizedtxt2imgQueryModelTrainJobListRequest.h>
|
||||
|
||||
using AlibabaCloud::AiContent::Model::Personalizedtxt2imgQueryModelTrainJobListRequest;
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainJobListRequest::Personalizedtxt2imgQueryModelTrainJobListRequest()
|
||||
: RoaServiceRequest("aicontent", "20240611") {
|
||||
setResourcePath("/api/v1/personalizedtxt2img/queryModelTrainJobList"};
|
||||
setMethod(HttpRequest::Method::Get);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainJobListRequest::~Personalizedtxt2imgQueryModelTrainJobListRequest() {}
|
||||
|
||||
@@ -0,0 +1,130 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/aicontent/model/Personalizedtxt2imgQueryModelTrainJobListResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AiContent;
|
||||
using namespace AlibabaCloud::AiContent::Model;
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainJobListResult::Personalizedtxt2imgQueryModelTrainJobListResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainJobListResult::Personalizedtxt2imgQueryModelTrainJobListResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainJobListResult::~Personalizedtxt2imgQueryModelTrainJobListResult()
|
||||
{}
|
||||
|
||||
void Personalizedtxt2imgQueryModelTrainJobListResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto alldataNode = value["data"]["dataItem"];
|
||||
for (auto valuedatadataItem : alldataNode)
|
||||
{
|
||||
DataItem dataObject;
|
||||
if(!valuedatadataItem["id"].isNull())
|
||||
dataObject.id = valuedatadataItem["id"].asString();
|
||||
if(!valuedatadataItem["modelId"].isNull())
|
||||
dataObject.modelId = valuedatadataItem["modelId"].asString();
|
||||
if(!valuedatadataItem["name"].isNull())
|
||||
dataObject.name = valuedatadataItem["name"].asString();
|
||||
if(!valuedatadataItem["objectType"].isNull())
|
||||
dataObject.objectType = valuedatadataItem["objectType"].asString();
|
||||
if(!valuedatadataItem["jobStatus"].isNull())
|
||||
dataObject.jobStatus = valuedatadataItem["jobStatus"].asString();
|
||||
if(!valuedatadataItem["jobTrainProgress"].isNull())
|
||||
dataObject.jobTrainProgress = valuedatadataItem["jobTrainProgress"].asString();
|
||||
if(!valuedatadataItem["inferenceImageCount"].isNull())
|
||||
dataObject.inferenceImageCount = std::stoi(valuedatadataItem["inferenceImageCount"].asString());
|
||||
if(!valuedatadataItem["createTime"].isNull())
|
||||
dataObject.createTime = valuedatadataItem["createTime"].asString();
|
||||
auto allinferenceJobListNode = valuedatadataItem["inferenceJobList"]["inferenceJobListItem"];
|
||||
for (auto valuedatadataIteminferenceJobListinferenceJobListItem : allinferenceJobListNode)
|
||||
{
|
||||
DataItem::InferenceJobListItem inferenceJobListObject;
|
||||
if(!valuedatadataIteminferenceJobListinferenceJobListItem["id"].isNull())
|
||||
inferenceJobListObject.id = valuedatadataIteminferenceJobListinferenceJobListItem["id"].asString();
|
||||
if(!valuedatadataIteminferenceJobListinferenceJobListItem["promptId"].isNull())
|
||||
inferenceJobListObject.promptId = valuedatadataIteminferenceJobListinferenceJobListItem["promptId"].asString();
|
||||
if(!valuedatadataIteminferenceJobListinferenceJobListItem["modelId"].isNull())
|
||||
inferenceJobListObject.modelId = valuedatadataIteminferenceJobListinferenceJobListItem["modelId"].asString();
|
||||
if(!valuedatadataIteminferenceJobListinferenceJobListItem["jobStatus"].isNull())
|
||||
inferenceJobListObject.jobStatus = valuedatadataIteminferenceJobListinferenceJobListItem["jobStatus"].asString();
|
||||
if(!valuedatadataIteminferenceJobListinferenceJobListItem["jobTrainProgress"].isNull())
|
||||
inferenceJobListObject.jobTrainProgress = valuedatadataIteminferenceJobListinferenceJobListItem["jobTrainProgress"].asString();
|
||||
if(!valuedatadataIteminferenceJobListinferenceJobListItem["createTime"].isNull())
|
||||
inferenceJobListObject.createTime = valuedatadataIteminferenceJobListinferenceJobListItem["createTime"].asString();
|
||||
auto allResultImageUrl = value["resultImageUrl"]["resultImageUrl"];
|
||||
for (auto value : allResultImageUrl)
|
||||
inferenceJobListObject.resultImageUrl.push_back(value.asString());
|
||||
dataObject.inferenceJobList.push_back(inferenceJobListObject);
|
||||
}
|
||||
auto allImageUrl = value["imageUrl"]["imageUrl"];
|
||||
for (auto value : allImageUrl)
|
||||
dataObject.imageUrl.push_back(value.asString());
|
||||
data_.push_back(dataObject);
|
||||
}
|
||||
if(!value["requestId"].isNull())
|
||||
requestId_ = value["requestId"].asString();
|
||||
if(!value["success"].isNull())
|
||||
success_ = value["success"].asString() == "true";
|
||||
if(!value["errCode"].isNull())
|
||||
errCode_ = value["errCode"].asString();
|
||||
if(!value["errMessage"].isNull())
|
||||
errMessage_ = value["errMessage"].asString();
|
||||
if(!value["httpStatusCode"].isNull())
|
||||
httpStatusCode_ = std::stoi(value["httpStatusCode"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::vector<Personalizedtxt2imgQueryModelTrainJobListResult::DataItem> Personalizedtxt2imgQueryModelTrainJobListResult::getdata()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryModelTrainJobListResult::getRequestId()const
|
||||
{
|
||||
return requestId_;
|
||||
}
|
||||
|
||||
int Personalizedtxt2imgQueryModelTrainJobListResult::getHttpStatusCode()const
|
||||
{
|
||||
return httpStatusCode_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryModelTrainJobListResult::getErrMessage()const
|
||||
{
|
||||
return errMessage_;
|
||||
}
|
||||
|
||||
bool Personalizedtxt2imgQueryModelTrainJobListResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryModelTrainJobListResult::getErrCode()const
|
||||
{
|
||||
return errCode_;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
/*
|
||||
* 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/aicontent/model/Personalizedtxt2imgQueryModelTrainStatusRequest.h>
|
||||
|
||||
using AlibabaCloud::AiContent::Model::Personalizedtxt2imgQueryModelTrainStatusRequest;
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainStatusRequest::Personalizedtxt2imgQueryModelTrainStatusRequest()
|
||||
: RoaServiceRequest("aicontent", "20240611") {
|
||||
setResourcePath("/api/v1/personalizedtxt2img/queryModelTrainStatus"};
|
||||
setMethod(HttpRequest::Method::Get);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainStatusRequest::~Personalizedtxt2imgQueryModelTrainStatusRequest() {}
|
||||
|
||||
std::string Personalizedtxt2imgQueryModelTrainStatusRequest::getModelId() const {
|
||||
return modelId_;
|
||||
}
|
||||
|
||||
void Personalizedtxt2imgQueryModelTrainStatusRequest::setModelId(const std::string &modelId) {
|
||||
modelId_ = modelId;
|
||||
setParameter(std::string("modelId"), modelId);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,87 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/aicontent/model/Personalizedtxt2imgQueryModelTrainStatusResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::AiContent;
|
||||
using namespace AlibabaCloud::AiContent::Model;
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainStatusResult::Personalizedtxt2imgQueryModelTrainStatusResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainStatusResult::Personalizedtxt2imgQueryModelTrainStatusResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainStatusResult::~Personalizedtxt2imgQueryModelTrainStatusResult()
|
||||
{}
|
||||
|
||||
void Personalizedtxt2imgQueryModelTrainStatusResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["data"];
|
||||
if(!dataNode["modelTrainStatus"].isNull())
|
||||
data_.modelTrainStatus = dataNode["modelTrainStatus"].asString();
|
||||
if(!value["requestId"].isNull())
|
||||
requestId_ = value["requestId"].asString();
|
||||
if(!value["success"].isNull())
|
||||
success_ = value["success"].asString() == "true";
|
||||
if(!value["errCode"].isNull())
|
||||
errCode_ = value["errCode"].asString();
|
||||
if(!value["errMessage"].isNull())
|
||||
errMessage_ = value["errMessage"].asString();
|
||||
if(!value["httpStatusCode"].isNull())
|
||||
httpStatusCode_ = std::stoi(value["httpStatusCode"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryModelTrainStatusResult::getRequestId()const
|
||||
{
|
||||
return requestId_;
|
||||
}
|
||||
|
||||
int Personalizedtxt2imgQueryModelTrainStatusResult::getHttpStatusCode()const
|
||||
{
|
||||
return httpStatusCode_;
|
||||
}
|
||||
|
||||
Personalizedtxt2imgQueryModelTrainStatusResult::Data Personalizedtxt2imgQueryModelTrainStatusResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryModelTrainStatusResult::getErrMessage()const
|
||||
{
|
||||
return errMessage_;
|
||||
}
|
||||
|
||||
bool Personalizedtxt2imgQueryModelTrainStatusResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
std::string Personalizedtxt2imgQueryModelTrainStatusResult::getErrCode()const
|
||||
{
|
||||
return errCode_;
|
||||
}
|
||||
|
||||
102
aigen/CMakeLists.txt
Normal file
102
aigen/CMakeLists.txt
Normal file
@@ -0,0 +1,102 @@
|
||||
#
|
||||
# Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
set(public_header_dir ${CMAKE_CURRENT_SOURCE_DIR}/../include)
|
||||
|
||||
set(aigen_public_header
|
||||
include/alibabacloud/aigen/AigenClient.h
|
||||
include/alibabacloud/aigen/AigenExport.h )
|
||||
|
||||
set(aigen_public_header_model
|
||||
include/alibabacloud/aigen/model/GenerateCosplayImageRequest.h
|
||||
include/alibabacloud/aigen/model/GenerateCosplayImageResult.h
|
||||
include/alibabacloud/aigen/model/GenerateTextDeformationRequest.h
|
||||
include/alibabacloud/aigen/model/GenerateTextDeformationResult.h
|
||||
include/alibabacloud/aigen/model/GenerateTextTextureRequest.h
|
||||
include/alibabacloud/aigen/model/GenerateTextTextureResult.h
|
||||
include/alibabacloud/aigen/model/InteractiveFullSegmentationRequest.h
|
||||
include/alibabacloud/aigen/model/InteractiveFullSegmentationResult.h
|
||||
include/alibabacloud/aigen/model/InteractiveScribbleSegmentationRequest.h
|
||||
include/alibabacloud/aigen/model/InteractiveScribbleSegmentationResult.h )
|
||||
|
||||
set(aigen_src
|
||||
src/AigenClient.cc
|
||||
src/model/GenerateCosplayImageRequest.cc
|
||||
src/model/GenerateCosplayImageResult.cc
|
||||
src/model/GenerateTextDeformationRequest.cc
|
||||
src/model/GenerateTextDeformationResult.cc
|
||||
src/model/GenerateTextTextureRequest.cc
|
||||
src/model/GenerateTextTextureResult.cc
|
||||
src/model/InteractiveFullSegmentationRequest.cc
|
||||
src/model/InteractiveFullSegmentationResult.cc
|
||||
src/model/InteractiveScribbleSegmentationRequest.cc
|
||||
src/model/InteractiveScribbleSegmentationResult.cc )
|
||||
|
||||
add_library(aigen ${LIB_TYPE}
|
||||
${aigen_public_header}
|
||||
${aigen_public_header_model}
|
||||
${aigen_src})
|
||||
|
||||
set_target_properties(aigen
|
||||
PROPERTIES
|
||||
LINKER_LANGUAGE CXX
|
||||
ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
|
||||
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
|
||||
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
|
||||
OUTPUT_NAME ${TARGET_OUTPUT_NAME_PREFIX}aigen
|
||||
)
|
||||
|
||||
if(${LIB_TYPE} STREQUAL "SHARED")
|
||||
set_target_properties(aigen
|
||||
PROPERTIES
|
||||
DEFINE_SYMBOL ALIBABACLOUD_AIGEN_LIBRARY)
|
||||
endif()
|
||||
|
||||
target_include_directories(aigen
|
||||
PRIVATE include
|
||||
${CMAKE_SOURCE_DIR}/core/include
|
||||
)
|
||||
target_link_libraries(aigen
|
||||
core)
|
||||
|
||||
if(CMAKE_HOST_WIN32)
|
||||
ExternalProject_Get_Property(jsoncpp INSTALL_DIR)
|
||||
set(jsoncpp_install_dir ${INSTALL_DIR})
|
||||
add_dependencies(aigen
|
||||
jsoncpp)
|
||||
target_include_directories(aigen
|
||||
PRIVATE ${jsoncpp_install_dir}/include)
|
||||
target_link_libraries(aigen
|
||||
${jsoncpp_install_dir}/lib/jsoncpp.lib)
|
||||
set_target_properties(aigen
|
||||
PROPERTIES
|
||||
COMPILE_OPTIONS "/bigobj")
|
||||
else()
|
||||
target_include_directories(aigen
|
||||
PRIVATE /usr/include/jsoncpp)
|
||||
target_link_libraries(aigen
|
||||
jsoncpp)
|
||||
endif()
|
||||
|
||||
install(FILES ${aigen_public_header}
|
||||
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/aigen)
|
||||
install(FILES ${aigen_public_header_model}
|
||||
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/aigen/model)
|
||||
install(TARGETS aigen
|
||||
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
|
||||
)
|
||||
86
aigen/include/alibabacloud/aigen/AigenClient.h
Normal file
86
aigen/include/alibabacloud/aigen/AigenClient.h
Normal file
@@ -0,0 +1,86 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_AIGENCLIENT_H_
|
||||
#define ALIBABACLOUD_AIGEN_AIGENCLIENT_H_
|
||||
|
||||
#include <future>
|
||||
#include <alibabacloud/core/AsyncCallerContext.h>
|
||||
#include <alibabacloud/core/EndpointProvider.h>
|
||||
#include <alibabacloud/core/RpcServiceClient.h>
|
||||
#include "AigenExport.h"
|
||||
#include "model/GenerateCosplayImageRequest.h"
|
||||
#include "model/GenerateCosplayImageResult.h"
|
||||
#include "model/GenerateTextDeformationRequest.h"
|
||||
#include "model/GenerateTextDeformationResult.h"
|
||||
#include "model/GenerateTextTextureRequest.h"
|
||||
#include "model/GenerateTextTextureResult.h"
|
||||
#include "model/InteractiveFullSegmentationRequest.h"
|
||||
#include "model/InteractiveFullSegmentationResult.h"
|
||||
#include "model/InteractiveScribbleSegmentationRequest.h"
|
||||
#include "model/InteractiveScribbleSegmentationResult.h"
|
||||
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Aigen
|
||||
{
|
||||
class ALIBABACLOUD_AIGEN_EXPORT AigenClient : public RpcServiceClient
|
||||
{
|
||||
public:
|
||||
typedef Outcome<Error, Model::GenerateCosplayImageResult> GenerateCosplayImageOutcome;
|
||||
typedef std::future<GenerateCosplayImageOutcome> GenerateCosplayImageOutcomeCallable;
|
||||
typedef std::function<void(const AigenClient*, const Model::GenerateCosplayImageRequest&, const GenerateCosplayImageOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GenerateCosplayImageAsyncHandler;
|
||||
typedef Outcome<Error, Model::GenerateTextDeformationResult> GenerateTextDeformationOutcome;
|
||||
typedef std::future<GenerateTextDeformationOutcome> GenerateTextDeformationOutcomeCallable;
|
||||
typedef std::function<void(const AigenClient*, const Model::GenerateTextDeformationRequest&, const GenerateTextDeformationOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GenerateTextDeformationAsyncHandler;
|
||||
typedef Outcome<Error, Model::GenerateTextTextureResult> GenerateTextTextureOutcome;
|
||||
typedef std::future<GenerateTextTextureOutcome> GenerateTextTextureOutcomeCallable;
|
||||
typedef std::function<void(const AigenClient*, const Model::GenerateTextTextureRequest&, const GenerateTextTextureOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GenerateTextTextureAsyncHandler;
|
||||
typedef Outcome<Error, Model::InteractiveFullSegmentationResult> InteractiveFullSegmentationOutcome;
|
||||
typedef std::future<InteractiveFullSegmentationOutcome> InteractiveFullSegmentationOutcomeCallable;
|
||||
typedef std::function<void(const AigenClient*, const Model::InteractiveFullSegmentationRequest&, const InteractiveFullSegmentationOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> InteractiveFullSegmentationAsyncHandler;
|
||||
typedef Outcome<Error, Model::InteractiveScribbleSegmentationResult> InteractiveScribbleSegmentationOutcome;
|
||||
typedef std::future<InteractiveScribbleSegmentationOutcome> InteractiveScribbleSegmentationOutcomeCallable;
|
||||
typedef std::function<void(const AigenClient*, const Model::InteractiveScribbleSegmentationRequest&, const InteractiveScribbleSegmentationOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> InteractiveScribbleSegmentationAsyncHandler;
|
||||
|
||||
AigenClient(const Credentials &credentials, const ClientConfiguration &configuration);
|
||||
AigenClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider, const ClientConfiguration &configuration);
|
||||
AigenClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration);
|
||||
~AigenClient();
|
||||
GenerateCosplayImageOutcome generateCosplayImage(const Model::GenerateCosplayImageRequest &request)const;
|
||||
void generateCosplayImageAsync(const Model::GenerateCosplayImageRequest& request, const GenerateCosplayImageAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GenerateCosplayImageOutcomeCallable generateCosplayImageCallable(const Model::GenerateCosplayImageRequest& request) const;
|
||||
GenerateTextDeformationOutcome generateTextDeformation(const Model::GenerateTextDeformationRequest &request)const;
|
||||
void generateTextDeformationAsync(const Model::GenerateTextDeformationRequest& request, const GenerateTextDeformationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GenerateTextDeformationOutcomeCallable generateTextDeformationCallable(const Model::GenerateTextDeformationRequest& request) const;
|
||||
GenerateTextTextureOutcome generateTextTexture(const Model::GenerateTextTextureRequest &request)const;
|
||||
void generateTextTextureAsync(const Model::GenerateTextTextureRequest& request, const GenerateTextTextureAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GenerateTextTextureOutcomeCallable generateTextTextureCallable(const Model::GenerateTextTextureRequest& request) const;
|
||||
InteractiveFullSegmentationOutcome interactiveFullSegmentation(const Model::InteractiveFullSegmentationRequest &request)const;
|
||||
void interactiveFullSegmentationAsync(const Model::InteractiveFullSegmentationRequest& request, const InteractiveFullSegmentationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
InteractiveFullSegmentationOutcomeCallable interactiveFullSegmentationCallable(const Model::InteractiveFullSegmentationRequest& request) const;
|
||||
InteractiveScribbleSegmentationOutcome interactiveScribbleSegmentation(const Model::InteractiveScribbleSegmentationRequest &request)const;
|
||||
void interactiveScribbleSegmentationAsync(const Model::InteractiveScribbleSegmentationRequest& request, const InteractiveScribbleSegmentationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
InteractiveScribbleSegmentationOutcomeCallable interactiveScribbleSegmentationCallable(const Model::InteractiveScribbleSegmentationRequest& request) const;
|
||||
|
||||
private:
|
||||
std::shared_ptr<EndpointProvider> endpointProvider_;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
#endif // !ALIBABACLOUD_AIGEN_AIGENCLIENT_H_
|
||||
32
aigen/include/alibabacloud/aigen/AigenExport.h
Normal file
32
aigen/include/alibabacloud/aigen/AigenExport.h
Normal file
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_AIGENEXPORT_H_
|
||||
#define ALIBABACLOUD_AIGEN_AIGENEXPORT_H_
|
||||
|
||||
#include <alibabacloud/core/Global.h>
|
||||
|
||||
#if defined(ALIBABACLOUD_SHARED)
|
||||
# if defined(ALIBABACLOUD_AIGEN_LIBRARY)
|
||||
# define ALIBABACLOUD_AIGEN_EXPORT ALIBABACLOUD_DECL_EXPORT
|
||||
# else
|
||||
# define ALIBABACLOUD_AIGEN_EXPORT ALIBABACLOUD_DECL_IMPORT
|
||||
# endif
|
||||
#else
|
||||
# define ALIBABACLOUD_AIGEN_EXPORT
|
||||
#endif
|
||||
|
||||
#endif // !ALIBABACLOUD_AIGEN_AIGENEXPORT_H_
|
||||
@@ -0,0 +1,51 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_MODEL_GENERATECOSPLAYIMAGEREQUEST_H_
|
||||
#define ALIBABACLOUD_AIGEN_MODEL_GENERATECOSPLAYIMAGEREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aigen/AigenExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Aigen {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AIGEN_EXPORT GenerateCosplayImageRequest : public RpcServiceRequest {
|
||||
public:
|
||||
GenerateCosplayImageRequest();
|
||||
~GenerateCosplayImageRequest();
|
||||
std::string getTemplateImageUrl() const;
|
||||
void setTemplateImageUrl(const std::string &templateImageUrl);
|
||||
std::string getFaceImageUrl() const;
|
||||
void setFaceImageUrl(const std::string &faceImageUrl);
|
||||
bool getAsync() const;
|
||||
void setAsync(bool async);
|
||||
long getStyle() const;
|
||||
void setStyle(long style);
|
||||
|
||||
private:
|
||||
std::string templateImageUrl_;
|
||||
std::string faceImageUrl_;
|
||||
bool async_;
|
||||
long style_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Aigen
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AIGEN_MODEL_GENERATECOSPLAYIMAGEREQUEST_H_
|
||||
@@ -0,0 +1,59 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_MODEL_GENERATECOSPLAYIMAGERESULT_H_
|
||||
#define ALIBABACLOUD_AIGEN_MODEL_GENERATECOSPLAYIMAGERESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aigen/AigenExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Aigen
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AIGEN_EXPORT GenerateCosplayImageResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string resultUrl;
|
||||
};
|
||||
|
||||
|
||||
GenerateCosplayImageResult();
|
||||
explicit GenerateCosplayImageResult(const std::string &payload);
|
||||
~GenerateCosplayImageResult();
|
||||
std::string getMessage()const;
|
||||
Data getData()const;
|
||||
std::string getCode()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
Data data_;
|
||||
std::string code_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AIGEN_MODEL_GENERATECOSPLAYIMAGERESULT_H_
|
||||
@@ -0,0 +1,60 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTDEFORMATIONREQUEST_H_
|
||||
#define ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTDEFORMATIONREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aigen/AigenExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Aigen {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AIGEN_EXPORT GenerateTextDeformationRequest : public RpcServiceRequest {
|
||||
public:
|
||||
GenerateTextDeformationRequest();
|
||||
~GenerateTextDeformationRequest();
|
||||
std::string getTextContent() const;
|
||||
void setTextContent(const std::string &textContent);
|
||||
std::string getFontName() const;
|
||||
void setFontName(const std::string &fontName);
|
||||
std::string getTtfUrl() const;
|
||||
void setTtfUrl(const std::string &ttfUrl);
|
||||
long getN() const;
|
||||
void setN(long n);
|
||||
bool getAsync() const;
|
||||
void setAsync(bool async);
|
||||
std::string getPrompt() const;
|
||||
void setPrompt(const std::string &prompt);
|
||||
std::string getOutputImageRatio() const;
|
||||
void setOutputImageRatio(const std::string &outputImageRatio);
|
||||
|
||||
private:
|
||||
std::string textContent_;
|
||||
std::string fontName_;
|
||||
std::string ttfUrl_;
|
||||
long n_;
|
||||
bool async_;
|
||||
std::string prompt_;
|
||||
std::string outputImageRatio_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Aigen
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTDEFORMATIONREQUEST_H_
|
||||
@@ -0,0 +1,57 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTDEFORMATIONRESULT_H_
|
||||
#define ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTDEFORMATIONRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aigen/AigenExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Aigen
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AIGEN_EXPORT GenerateTextDeformationResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string resultUrl;
|
||||
};
|
||||
|
||||
|
||||
GenerateTextDeformationResult();
|
||||
explicit GenerateTextDeformationResult(const std::string &payload);
|
||||
~GenerateTextDeformationResult();
|
||||
std::string getMessage()const;
|
||||
Data getData()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
Data data_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTDEFORMATIONRESULT_H_
|
||||
@@ -0,0 +1,72 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTTEXTUREREQUEST_H_
|
||||
#define ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTTEXTUREREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aigen/AigenExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Aigen {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AIGEN_EXPORT GenerateTextTextureRequest : public RpcServiceRequest {
|
||||
public:
|
||||
GenerateTextTextureRequest();
|
||||
~GenerateTextTextureRequest();
|
||||
std::string getTextContent() const;
|
||||
void setTextContent(const std::string &textContent);
|
||||
std::string getTextureStyle() const;
|
||||
void setTextureStyle(const std::string &textureStyle);
|
||||
std::string getFontName() const;
|
||||
void setFontName(const std::string &fontName);
|
||||
std::string getTtfUrl() const;
|
||||
void setTtfUrl(const std::string &ttfUrl);
|
||||
long getN() const;
|
||||
void setN(long n);
|
||||
bool getAsync() const;
|
||||
void setAsync(bool async);
|
||||
bool getAlphaChannel() const;
|
||||
void setAlphaChannel(bool alphaChannel);
|
||||
std::string getImageUrl() const;
|
||||
void setImageUrl(const std::string &imageUrl);
|
||||
long getImageShortSize() const;
|
||||
void setImageShortSize(long imageShortSize);
|
||||
std::string getPrompt() const;
|
||||
void setPrompt(const std::string &prompt);
|
||||
std::string getOutputImageRatio() const;
|
||||
void setOutputImageRatio(const std::string &outputImageRatio);
|
||||
|
||||
private:
|
||||
std::string textContent_;
|
||||
std::string textureStyle_;
|
||||
std::string fontName_;
|
||||
std::string ttfUrl_;
|
||||
long n_;
|
||||
bool async_;
|
||||
bool alphaChannel_;
|
||||
std::string imageUrl_;
|
||||
long imageShortSize_;
|
||||
std::string prompt_;
|
||||
std::string outputImageRatio_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Aigen
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTTEXTUREREQUEST_H_
|
||||
@@ -0,0 +1,57 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTTEXTURERESULT_H_
|
||||
#define ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTTEXTURERESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aigen/AigenExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Aigen
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AIGEN_EXPORT GenerateTextTextureResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string resultUrl;
|
||||
};
|
||||
|
||||
|
||||
GenerateTextTextureResult();
|
||||
explicit GenerateTextTextureResult(const std::string &payload);
|
||||
~GenerateTextTextureResult();
|
||||
std::string getMessage()const;
|
||||
Data getData()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
Data data_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AIGEN_MODEL_GENERATETEXTTEXTURERESULT_H_
|
||||
@@ -0,0 +1,48 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_MODEL_INTERACTIVEFULLSEGMENTATIONREQUEST_H_
|
||||
#define ALIBABACLOUD_AIGEN_MODEL_INTERACTIVEFULLSEGMENTATIONREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aigen/AigenExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Aigen {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AIGEN_EXPORT InteractiveFullSegmentationRequest : public RpcServiceRequest {
|
||||
public:
|
||||
InteractiveFullSegmentationRequest();
|
||||
~InteractiveFullSegmentationRequest();
|
||||
std::string getReturnFormat() const;
|
||||
void setReturnFormat(const std::string &returnFormat);
|
||||
bool getAsync() const;
|
||||
void setAsync(bool async);
|
||||
std::string getImageUrl() const;
|
||||
void setImageUrl(const std::string &imageUrl);
|
||||
|
||||
private:
|
||||
std::string returnFormat_;
|
||||
bool async_;
|
||||
std::string imageUrl_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Aigen
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AIGEN_MODEL_INTERACTIVEFULLSEGMENTATIONREQUEST_H_
|
||||
@@ -0,0 +1,59 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_MODEL_INTERACTIVEFULLSEGMENTATIONRESULT_H_
|
||||
#define ALIBABACLOUD_AIGEN_MODEL_INTERACTIVEFULLSEGMENTATIONRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aigen/AigenExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Aigen
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AIGEN_EXPORT InteractiveFullSegmentationResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string resultUrl;
|
||||
};
|
||||
|
||||
|
||||
InteractiveFullSegmentationResult();
|
||||
explicit InteractiveFullSegmentationResult(const std::string &payload);
|
||||
~InteractiveFullSegmentationResult();
|
||||
std::string getMessage()const;
|
||||
Data getData()const;
|
||||
std::string getCode()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
Data data_;
|
||||
std::string code_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AIGEN_MODEL_INTERACTIVEFULLSEGMENTATIONRESULT_H_
|
||||
@@ -0,0 +1,66 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_MODEL_INTERACTIVESCRIBBLESEGMENTATIONREQUEST_H_
|
||||
#define ALIBABACLOUD_AIGEN_MODEL_INTERACTIVESCRIBBLESEGMENTATIONREQUEST_H_
|
||||
|
||||
#include <alibabacloud/aigen/AigenExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Aigen {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_AIGEN_EXPORT InteractiveScribbleSegmentationRequest : public RpcServiceRequest {
|
||||
public:
|
||||
InteractiveScribbleSegmentationRequest();
|
||||
~InteractiveScribbleSegmentationRequest();
|
||||
std::string getPosScribbleImageUrl() const;
|
||||
void setPosScribbleImageUrl(const std::string &posScribbleImageUrl);
|
||||
std::string getIntegratedMaskUrl() const;
|
||||
void setIntegratedMaskUrl(const std::string &integratedMaskUrl);
|
||||
std::string getMaskImageUrl() const;
|
||||
void setMaskImageUrl(const std::string &maskImageUrl);
|
||||
std::string getReturnForm() const;
|
||||
void setReturnForm(const std::string &returnForm);
|
||||
std::string getNegScribbleImageUrl() const;
|
||||
void setNegScribbleImageUrl(const std::string &negScribbleImageUrl);
|
||||
std::string getReturnFormat() const;
|
||||
void setReturnFormat(const std::string &returnFormat);
|
||||
std::string getEdgeFeathering() const;
|
||||
void setEdgeFeathering(const std::string &edgeFeathering);
|
||||
std::string getImageUrl() const;
|
||||
void setImageUrl(const std::string &imageUrl);
|
||||
std::string getPostprocessOption() const;
|
||||
void setPostprocessOption(const std::string &postprocessOption);
|
||||
|
||||
private:
|
||||
std::string posScribbleImageUrl_;
|
||||
std::string integratedMaskUrl_;
|
||||
std::string maskImageUrl_;
|
||||
std::string returnForm_;
|
||||
std::string negScribbleImageUrl_;
|
||||
std::string returnFormat_;
|
||||
std::string edgeFeathering_;
|
||||
std::string imageUrl_;
|
||||
std::string postprocessOption_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Aigen
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_AIGEN_MODEL_INTERACTIVESCRIBBLESEGMENTATIONREQUEST_H_
|
||||
@@ -0,0 +1,55 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_AIGEN_MODEL_INTERACTIVESCRIBBLESEGMENTATIONRESULT_H_
|
||||
#define ALIBABACLOUD_AIGEN_MODEL_INTERACTIVESCRIBBLESEGMENTATIONRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/aigen/AigenExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Aigen
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_AIGEN_EXPORT InteractiveScribbleSegmentationResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string resultUrl;
|
||||
};
|
||||
|
||||
|
||||
InteractiveScribbleSegmentationResult();
|
||||
explicit InteractiveScribbleSegmentationResult(const std::string &payload);
|
||||
~InteractiveScribbleSegmentationResult();
|
||||
Data getData()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Data data_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_AIGEN_MODEL_INTERACTIVESCRIBBLESEGMENTATIONRESULT_H_
|
||||
233
aigen/src/AigenClient.cc
Normal file
233
aigen/src/AigenClient.cc
Normal file
@@ -0,0 +1,233 @@
|
||||
/*
|
||||
* 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/aigen/AigenClient.h>
|
||||
#include <alibabacloud/core/SimpleCredentialsProvider.h>
|
||||
|
||||
using namespace AlibabaCloud;
|
||||
using namespace AlibabaCloud::Location;
|
||||
using namespace AlibabaCloud::Aigen;
|
||||
using namespace AlibabaCloud::Aigen::Model;
|
||||
|
||||
namespace
|
||||
{
|
||||
const std::string SERVICE_NAME = "aigen";
|
||||
}
|
||||
|
||||
AigenClient::AigenClient(const Credentials &credentials, const ClientConfiguration &configuration) :
|
||||
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(credentials), configuration)
|
||||
{
|
||||
auto locationClient = std::make_shared<LocationClient>(credentials, configuration);
|
||||
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
|
||||
}
|
||||
|
||||
AigenClient::AigenClient(const std::shared_ptr<CredentialsProvider>& credentialsProvider, const ClientConfiguration & configuration) :
|
||||
RpcServiceClient(SERVICE_NAME, credentialsProvider, configuration)
|
||||
{
|
||||
auto locationClient = std::make_shared<LocationClient>(credentialsProvider, configuration);
|
||||
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
|
||||
}
|
||||
|
||||
AigenClient::AigenClient(const std::string & accessKeyId, const std::string & accessKeySecret, const ClientConfiguration & configuration) :
|
||||
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(accessKeyId, accessKeySecret), configuration)
|
||||
{
|
||||
auto locationClient = std::make_shared<LocationClient>(accessKeyId, accessKeySecret, configuration);
|
||||
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
|
||||
}
|
||||
|
||||
AigenClient::~AigenClient()
|
||||
{}
|
||||
|
||||
AigenClient::GenerateCosplayImageOutcome AigenClient::generateCosplayImage(const GenerateCosplayImageRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return GenerateCosplayImageOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return GenerateCosplayImageOutcome(GenerateCosplayImageResult(outcome.result()));
|
||||
else
|
||||
return GenerateCosplayImageOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AigenClient::generateCosplayImageAsync(const GenerateCosplayImageRequest& request, const GenerateCosplayImageAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, generateCosplayImage(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AigenClient::GenerateCosplayImageOutcomeCallable AigenClient::generateCosplayImageCallable(const GenerateCosplayImageRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<GenerateCosplayImageOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->generateCosplayImage(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AigenClient::GenerateTextDeformationOutcome AigenClient::generateTextDeformation(const GenerateTextDeformationRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return GenerateTextDeformationOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return GenerateTextDeformationOutcome(GenerateTextDeformationResult(outcome.result()));
|
||||
else
|
||||
return GenerateTextDeformationOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AigenClient::generateTextDeformationAsync(const GenerateTextDeformationRequest& request, const GenerateTextDeformationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, generateTextDeformation(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AigenClient::GenerateTextDeformationOutcomeCallable AigenClient::generateTextDeformationCallable(const GenerateTextDeformationRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<GenerateTextDeformationOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->generateTextDeformation(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AigenClient::GenerateTextTextureOutcome AigenClient::generateTextTexture(const GenerateTextTextureRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return GenerateTextTextureOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return GenerateTextTextureOutcome(GenerateTextTextureResult(outcome.result()));
|
||||
else
|
||||
return GenerateTextTextureOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AigenClient::generateTextTextureAsync(const GenerateTextTextureRequest& request, const GenerateTextTextureAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, generateTextTexture(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AigenClient::GenerateTextTextureOutcomeCallable AigenClient::generateTextTextureCallable(const GenerateTextTextureRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<GenerateTextTextureOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->generateTextTexture(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AigenClient::InteractiveFullSegmentationOutcome AigenClient::interactiveFullSegmentation(const InteractiveFullSegmentationRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return InteractiveFullSegmentationOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return InteractiveFullSegmentationOutcome(InteractiveFullSegmentationResult(outcome.result()));
|
||||
else
|
||||
return InteractiveFullSegmentationOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AigenClient::interactiveFullSegmentationAsync(const InteractiveFullSegmentationRequest& request, const InteractiveFullSegmentationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, interactiveFullSegmentation(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AigenClient::InteractiveFullSegmentationOutcomeCallable AigenClient::interactiveFullSegmentationCallable(const InteractiveFullSegmentationRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<InteractiveFullSegmentationOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->interactiveFullSegmentation(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
AigenClient::InteractiveScribbleSegmentationOutcome AigenClient::interactiveScribbleSegmentation(const InteractiveScribbleSegmentationRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return InteractiveScribbleSegmentationOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return InteractiveScribbleSegmentationOutcome(InteractiveScribbleSegmentationResult(outcome.result()));
|
||||
else
|
||||
return InteractiveScribbleSegmentationOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void AigenClient::interactiveScribbleSegmentationAsync(const InteractiveScribbleSegmentationRequest& request, const InteractiveScribbleSegmentationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, interactiveScribbleSegmentation(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
AigenClient::InteractiveScribbleSegmentationOutcomeCallable AigenClient::interactiveScribbleSegmentationCallable(const InteractiveScribbleSegmentationRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<InteractiveScribbleSegmentationOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->interactiveScribbleSegmentation(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
63
aigen/src/model/GenerateCosplayImageRequest.cc
Normal file
63
aigen/src/model/GenerateCosplayImageRequest.cc
Normal 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.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/aigen/model/GenerateCosplayImageRequest.h>
|
||||
|
||||
using AlibabaCloud::Aigen::Model::GenerateCosplayImageRequest;
|
||||
|
||||
GenerateCosplayImageRequest::GenerateCosplayImageRequest()
|
||||
: RpcServiceRequest("aigen", "2024-01-11", "GenerateCosplayImage") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
GenerateCosplayImageRequest::~GenerateCosplayImageRequest() {}
|
||||
|
||||
std::string GenerateCosplayImageRequest::getTemplateImageUrl() const {
|
||||
return templateImageUrl_;
|
||||
}
|
||||
|
||||
void GenerateCosplayImageRequest::setTemplateImageUrl(const std::string &templateImageUrl) {
|
||||
templateImageUrl_ = templateImageUrl;
|
||||
setBodyParameter(std::string("TemplateImageUrl"), templateImageUrl);
|
||||
}
|
||||
|
||||
std::string GenerateCosplayImageRequest::getFaceImageUrl() const {
|
||||
return faceImageUrl_;
|
||||
}
|
||||
|
||||
void GenerateCosplayImageRequest::setFaceImageUrl(const std::string &faceImageUrl) {
|
||||
faceImageUrl_ = faceImageUrl;
|
||||
setBodyParameter(std::string("FaceImageUrl"), faceImageUrl);
|
||||
}
|
||||
|
||||
bool GenerateCosplayImageRequest::getAsync() const {
|
||||
return async_;
|
||||
}
|
||||
|
||||
void GenerateCosplayImageRequest::setAsync(bool async) {
|
||||
async_ = async;
|
||||
setBodyParameter(std::string("Async"), async ? "true" : "false");
|
||||
}
|
||||
|
||||
long GenerateCosplayImageRequest::getStyle() const {
|
||||
return style_;
|
||||
}
|
||||
|
||||
void GenerateCosplayImageRequest::setStyle(long style) {
|
||||
style_ = style;
|
||||
setBodyParameter(std::string("Style"), std::to_string(style));
|
||||
}
|
||||
|
||||
66
aigen/src/model/GenerateCosplayImageResult.cc
Normal file
66
aigen/src/model/GenerateCosplayImageResult.cc
Normal file
@@ -0,0 +1,66 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/aigen/model/GenerateCosplayImageResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Aigen;
|
||||
using namespace AlibabaCloud::Aigen::Model;
|
||||
|
||||
GenerateCosplayImageResult::GenerateCosplayImageResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
GenerateCosplayImageResult::GenerateCosplayImageResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
GenerateCosplayImageResult::~GenerateCosplayImageResult()
|
||||
{}
|
||||
|
||||
void GenerateCosplayImageResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
if(!dataNode["ResultUrl"].isNull())
|
||||
data_.resultUrl = dataNode["ResultUrl"].asString();
|
||||
if(!value["Code"].isNull())
|
||||
code_ = value["Code"].asString();
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
|
||||
}
|
||||
|
||||
std::string GenerateCosplayImageResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
GenerateCosplayImageResult::Data GenerateCosplayImageResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string GenerateCosplayImageResult::getCode()const
|
||||
{
|
||||
return code_;
|
||||
}
|
||||
|
||||
90
aigen/src/model/GenerateTextDeformationRequest.cc
Normal file
90
aigen/src/model/GenerateTextDeformationRequest.cc
Normal file
@@ -0,0 +1,90 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/aigen/model/GenerateTextDeformationRequest.h>
|
||||
|
||||
using AlibabaCloud::Aigen::Model::GenerateTextDeformationRequest;
|
||||
|
||||
GenerateTextDeformationRequest::GenerateTextDeformationRequest()
|
||||
: RpcServiceRequest("aigen", "2024-01-11", "GenerateTextDeformation") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
GenerateTextDeformationRequest::~GenerateTextDeformationRequest() {}
|
||||
|
||||
std::string GenerateTextDeformationRequest::getTextContent() const {
|
||||
return textContent_;
|
||||
}
|
||||
|
||||
void GenerateTextDeformationRequest::setTextContent(const std::string &textContent) {
|
||||
textContent_ = textContent;
|
||||
setBodyParameter(std::string("TextContent"), textContent);
|
||||
}
|
||||
|
||||
std::string GenerateTextDeformationRequest::getFontName() const {
|
||||
return fontName_;
|
||||
}
|
||||
|
||||
void GenerateTextDeformationRequest::setFontName(const std::string &fontName) {
|
||||
fontName_ = fontName;
|
||||
setBodyParameter(std::string("FontName"), fontName);
|
||||
}
|
||||
|
||||
std::string GenerateTextDeformationRequest::getTtfUrl() const {
|
||||
return ttfUrl_;
|
||||
}
|
||||
|
||||
void GenerateTextDeformationRequest::setTtfUrl(const std::string &ttfUrl) {
|
||||
ttfUrl_ = ttfUrl;
|
||||
setBodyParameter(std::string("TtfUrl"), ttfUrl);
|
||||
}
|
||||
|
||||
long GenerateTextDeformationRequest::getN() const {
|
||||
return n_;
|
||||
}
|
||||
|
||||
void GenerateTextDeformationRequest::setN(long n) {
|
||||
n_ = n;
|
||||
setBodyParameter(std::string("N"), std::to_string(n));
|
||||
}
|
||||
|
||||
bool GenerateTextDeformationRequest::getAsync() const {
|
||||
return async_;
|
||||
}
|
||||
|
||||
void GenerateTextDeformationRequest::setAsync(bool async) {
|
||||
async_ = async;
|
||||
setBodyParameter(std::string("Async"), async ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string GenerateTextDeformationRequest::getPrompt() const {
|
||||
return prompt_;
|
||||
}
|
||||
|
||||
void GenerateTextDeformationRequest::setPrompt(const std::string &prompt) {
|
||||
prompt_ = prompt;
|
||||
setBodyParameter(std::string("Prompt"), prompt);
|
||||
}
|
||||
|
||||
std::string GenerateTextDeformationRequest::getOutputImageRatio() const {
|
||||
return outputImageRatio_;
|
||||
}
|
||||
|
||||
void GenerateTextDeformationRequest::setOutputImageRatio(const std::string &outputImageRatio) {
|
||||
outputImageRatio_ = outputImageRatio;
|
||||
setBodyParameter(std::string("OutputImageRatio"), outputImageRatio);
|
||||
}
|
||||
|
||||
59
aigen/src/model/GenerateTextDeformationResult.cc
Normal file
59
aigen/src/model/GenerateTextDeformationResult.cc
Normal file
@@ -0,0 +1,59 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/aigen/model/GenerateTextDeformationResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Aigen;
|
||||
using namespace AlibabaCloud::Aigen::Model;
|
||||
|
||||
GenerateTextDeformationResult::GenerateTextDeformationResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
GenerateTextDeformationResult::GenerateTextDeformationResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
GenerateTextDeformationResult::~GenerateTextDeformationResult()
|
||||
{}
|
||||
|
||||
void GenerateTextDeformationResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
if(!dataNode["ResultUrl"].isNull())
|
||||
data_.resultUrl = dataNode["ResultUrl"].asString();
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
|
||||
}
|
||||
|
||||
std::string GenerateTextDeformationResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
GenerateTextDeformationResult::Data GenerateTextDeformationResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
126
aigen/src/model/GenerateTextTextureRequest.cc
Normal file
126
aigen/src/model/GenerateTextTextureRequest.cc
Normal file
@@ -0,0 +1,126 @@
|
||||
/*
|
||||
* 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/aigen/model/GenerateTextTextureRequest.h>
|
||||
|
||||
using AlibabaCloud::Aigen::Model::GenerateTextTextureRequest;
|
||||
|
||||
GenerateTextTextureRequest::GenerateTextTextureRequest()
|
||||
: RpcServiceRequest("aigen", "2024-01-11", "GenerateTextTexture") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
GenerateTextTextureRequest::~GenerateTextTextureRequest() {}
|
||||
|
||||
std::string GenerateTextTextureRequest::getTextContent() const {
|
||||
return textContent_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setTextContent(const std::string &textContent) {
|
||||
textContent_ = textContent;
|
||||
setBodyParameter(std::string("TextContent"), textContent);
|
||||
}
|
||||
|
||||
std::string GenerateTextTextureRequest::getTextureStyle() const {
|
||||
return textureStyle_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setTextureStyle(const std::string &textureStyle) {
|
||||
textureStyle_ = textureStyle;
|
||||
setParameter(std::string("TextureStyle"), textureStyle);
|
||||
}
|
||||
|
||||
std::string GenerateTextTextureRequest::getFontName() const {
|
||||
return fontName_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setFontName(const std::string &fontName) {
|
||||
fontName_ = fontName;
|
||||
setBodyParameter(std::string("FontName"), fontName);
|
||||
}
|
||||
|
||||
std::string GenerateTextTextureRequest::getTtfUrl() const {
|
||||
return ttfUrl_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setTtfUrl(const std::string &ttfUrl) {
|
||||
ttfUrl_ = ttfUrl;
|
||||
setBodyParameter(std::string("TtfUrl"), ttfUrl);
|
||||
}
|
||||
|
||||
long GenerateTextTextureRequest::getN() const {
|
||||
return n_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setN(long n) {
|
||||
n_ = n;
|
||||
setBodyParameter(std::string("N"), std::to_string(n));
|
||||
}
|
||||
|
||||
bool GenerateTextTextureRequest::getAsync() const {
|
||||
return async_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setAsync(bool async) {
|
||||
async_ = async;
|
||||
setBodyParameter(std::string("Async"), async ? "true" : "false");
|
||||
}
|
||||
|
||||
bool GenerateTextTextureRequest::getAlphaChannel() const {
|
||||
return alphaChannel_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setAlphaChannel(bool alphaChannel) {
|
||||
alphaChannel_ = alphaChannel;
|
||||
setBodyParameter(std::string("AlphaChannel"), alphaChannel ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string GenerateTextTextureRequest::getImageUrl() const {
|
||||
return imageUrl_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setImageUrl(const std::string &imageUrl) {
|
||||
imageUrl_ = imageUrl;
|
||||
setBodyParameter(std::string("ImageUrl"), imageUrl);
|
||||
}
|
||||
|
||||
long GenerateTextTextureRequest::getImageShortSize() const {
|
||||
return imageShortSize_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setImageShortSize(long imageShortSize) {
|
||||
imageShortSize_ = imageShortSize;
|
||||
setBodyParameter(std::string("ImageShortSize"), std::to_string(imageShortSize));
|
||||
}
|
||||
|
||||
std::string GenerateTextTextureRequest::getPrompt() const {
|
||||
return prompt_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setPrompt(const std::string &prompt) {
|
||||
prompt_ = prompt;
|
||||
setBodyParameter(std::string("Prompt"), prompt);
|
||||
}
|
||||
|
||||
std::string GenerateTextTextureRequest::getOutputImageRatio() const {
|
||||
return outputImageRatio_;
|
||||
}
|
||||
|
||||
void GenerateTextTextureRequest::setOutputImageRatio(const std::string &outputImageRatio) {
|
||||
outputImageRatio_ = outputImageRatio;
|
||||
setBodyParameter(std::string("OutputImageRatio"), outputImageRatio);
|
||||
}
|
||||
|
||||
59
aigen/src/model/GenerateTextTextureResult.cc
Normal file
59
aigen/src/model/GenerateTextTextureResult.cc
Normal file
@@ -0,0 +1,59 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/aigen/model/GenerateTextTextureResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Aigen;
|
||||
using namespace AlibabaCloud::Aigen::Model;
|
||||
|
||||
GenerateTextTextureResult::GenerateTextTextureResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
GenerateTextTextureResult::GenerateTextTextureResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
GenerateTextTextureResult::~GenerateTextTextureResult()
|
||||
{}
|
||||
|
||||
void GenerateTextTextureResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
if(!dataNode["ResultUrl"].isNull())
|
||||
data_.resultUrl = dataNode["ResultUrl"].asString();
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
|
||||
}
|
||||
|
||||
std::string GenerateTextTextureResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
GenerateTextTextureResult::Data GenerateTextTextureResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user