Skip to content

Commit 0ce806f

Browse files
aws-sdk-cpp-automationkai-ion
authored andcommitted
null
# Conflicts: # VERSION # src/aws-cpp-sdk-core/include/aws/core/VersionConfig.h # tools/code-generation/smithy/codegen/cpp-smoke-tests/smithy-build.json
1 parent bf799b4 commit 0ce806f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+3354
-0
lines changed
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
add_project(aws-cpp-sdk-test-new-service-sdk-testing "C++ SDK for the AWS test-new-service-sdk-testing service" aws-cpp-sdk-core)
2+
3+
file(GLOB AWS_TEST-NEW-SERVICE-SDK-TESTING_HEADERS
4+
"include/aws/test-new-service-sdk-testing/*.h"
5+
)
6+
7+
file(GLOB AWS_TEST-NEW-SERVICE-SDK-TESTING_MODEL_HEADERS
8+
"include/aws/test-new-service-sdk-testing/model/*.h"
9+
)
10+
11+
file(GLOB AWS_TEST-NEW-SERVICE-SDK-TESTING_SOURCE
12+
"source/*.cpp"
13+
)
14+
15+
file(GLOB AWS_TEST-NEW-SERVICE-SDK-TESTING_MODEL_SOURCE
16+
"source/model/*.cpp"
17+
)
18+
19+
file(GLOB TEST-NEW-SERVICE-SDK-TESTING_UNIFIED_HEADERS
20+
${AWS_TEST-NEW-SERVICE-SDK-TESTING_HEADERS}
21+
${AWS_TEST-NEW-SERVICE-SDK-TESTING_MODEL_HEADERS}
22+
)
23+
24+
file(GLOB TEST-NEW-SERVICE-SDK-TESTING_UNITY_SRC
25+
${AWS_TEST-NEW-SERVICE-SDK-TESTING_SOURCE}
26+
${AWS_TEST-NEW-SERVICE-SDK-TESTING_MODEL_SOURCE}
27+
)
28+
29+
if(ENABLE_UNITY_BUILD)
30+
enable_unity_build("TEST-NEW-SERVICE-SDK-TESTING" TEST-NEW-SERVICE-SDK-TESTING_UNITY_SRC)
31+
endif()
32+
33+
file(GLOB TEST-NEW-SERVICE-SDK-TESTING_SRC
34+
${TEST-NEW-SERVICE-SDK-TESTING_UNIFIED_HEADERS}
35+
${TEST-NEW-SERVICE-SDK-TESTING_UNITY_SRC}
36+
)
37+
38+
if(WIN32)
39+
#if we are compiling for visual studio, create a sane directory tree.
40+
if(MSVC)
41+
source_group("Header Files\\aws\\test-new-service-sdk-testing" FILES ${AWS_TEST-NEW-SERVICE-SDK-TESTING_HEADERS})
42+
source_group("Header Files\\aws\\test-new-service-sdk-testing\\model" FILES ${AWS_TEST-NEW-SERVICE-SDK-TESTING_MODEL_HEADERS})
43+
source_group("Source Files" FILES ${AWS_TEST-NEW-SERVICE-SDK-TESTING_SOURCE})
44+
source_group("Source Files\\model" FILES ${AWS_TEST-NEW-SERVICE-SDK-TESTING_MODEL_SOURCE})
45+
endif(MSVC)
46+
endif()
47+
48+
set(TEST-NEW-SERVICE-SDK-TESTING_INCLUDES
49+
"${CMAKE_CURRENT_SOURCE_DIR}/include/"
50+
)
51+
52+
add_library(${PROJECT_NAME} ${TEST-NEW-SERVICE-SDK-TESTING_SRC})
53+
add_library(AWS::${PROJECT_NAME} ALIAS ${PROJECT_NAME})
54+
55+
set_compiler_flags(${PROJECT_NAME})
56+
set_compiler_warnings(${PROJECT_NAME})
57+
58+
if(USE_WINDOWS_DLL_SEMANTICS AND BUILD_SHARED_LIBS)
59+
target_compile_definitions(${PROJECT_NAME} PRIVATE "AWS_TESTNEWSERVICESDKTESTING_EXPORTS")
60+
endif()
61+
62+
target_include_directories(${PROJECT_NAME} PUBLIC
63+
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
64+
$<INSTALL_INTERFACE:include>)
65+
66+
target_link_libraries(${PROJECT_NAME} PRIVATE ${PLATFORM_DEP_LIBS} ${PROJECT_LIBS})
67+
68+
69+
setup_install()
70+
71+
install (FILES ${AWS_TEST-NEW-SERVICE-SDK-TESTING_HEADERS} DESTINATION ${INCLUDE_DIRECTORY}/aws/test-new-service-sdk-testing)
72+
install (FILES ${AWS_TEST-NEW-SERVICE-SDK-TESTING_MODEL_HEADERS} DESTINATION ${INCLUDE_DIRECTORY}/aws/test-new-service-sdk-testing/model)
73+
74+
do_packaging()
75+
76+
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,146 @@
1+
/**
2+
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
* SPDX-License-Identifier: Apache-2.0.
4+
*/
5+
6+
#pragma once
7+
#include <aws/core/client/AWSClient.h>
8+
#include <aws/core/client/AWSClientAsyncCRTP.h>
9+
#include <aws/core/client/ClientConfiguration.h>
10+
#include <aws/core/utils/json/JsonSerializer.h>
11+
#include <aws/test-new-service-sdk-testing/TestNewServiceSDKTestingServiceClientModel.h>
12+
#include <aws/test-new-service-sdk-testing/TestNewServiceSDKTesting_EXPORTS.h>
13+
14+
namespace Aws {
15+
namespace TestNewServiceSDKTesting {
16+
class AWS_TESTNEWSERVICESDKTESTING_API TestNewServiceSDKTestingClient
17+
: public Aws::Client::AWSJsonClient,
18+
public Aws::Client::ClientWithAsyncTemplateMethods<TestNewServiceSDKTestingClient> {
19+
public:
20+
typedef Aws::Client::AWSJsonClient BASECLASS;
21+
static const char* GetServiceName();
22+
static const char* GetAllocationTag();
23+
24+
typedef TestNewServiceSDKTestingClientConfiguration ClientConfigurationType;
25+
typedef TestNewServiceSDKTestingEndpointProvider EndpointProviderType;
26+
27+
/**
28+
* Initializes client to use DefaultCredentialProviderChain, with default http client factory, and optional client config. If client
29+
* config is not specified, it will be initialized to default values.
30+
*/
31+
TestNewServiceSDKTestingClient(const Aws::TestNewServiceSDKTesting::TestNewServiceSDKTestingClientConfiguration& clientConfiguration =
32+
Aws::TestNewServiceSDKTesting::TestNewServiceSDKTestingClientConfiguration(),
33+
std::shared_ptr<TestNewServiceSDKTestingEndpointProviderBase> endpointProvider = nullptr);
34+
35+
/**
36+
* Initializes client to use SimpleAWSCredentialsProvider, with default http client factory, and optional client config. If client config
37+
* is not specified, it will be initialized to default values.
38+
*/
39+
TestNewServiceSDKTestingClient(const Aws::Auth::AWSCredentials& credentials,
40+
std::shared_ptr<TestNewServiceSDKTestingEndpointProviderBase> endpointProvider = nullptr,
41+
const Aws::TestNewServiceSDKTesting::TestNewServiceSDKTestingClientConfiguration& clientConfiguration =
42+
Aws::TestNewServiceSDKTesting::TestNewServiceSDKTestingClientConfiguration());
43+
44+
/**
45+
* Initializes client to use specified credentials provider with specified client config. If http client factory is not supplied,
46+
* the default http client factory will be used
47+
*/
48+
TestNewServiceSDKTestingClient(const std::shared_ptr<Aws::Auth::AWSCredentialsProvider>& credentialsProvider,
49+
std::shared_ptr<TestNewServiceSDKTestingEndpointProviderBase> endpointProvider = nullptr,
50+
const Aws::TestNewServiceSDKTesting::TestNewServiceSDKTestingClientConfiguration& clientConfiguration =
51+
Aws::TestNewServiceSDKTesting::TestNewServiceSDKTestingClientConfiguration());
52+
53+
/* Legacy constructors due deprecation */
54+
/**
55+
* Initializes client to use DefaultCredentialProviderChain, with default http client factory, and optional client config. If client
56+
* config is not specified, it will be initialized to default values.
57+
*/
58+
TestNewServiceSDKTestingClient(const Aws::Client::ClientConfiguration& clientConfiguration);
59+
60+
/**
61+
* Initializes client to use SimpleAWSCredentialsProvider, with default http client factory, and optional client config. If client config
62+
* is not specified, it will be initialized to default values.
63+
*/
64+
TestNewServiceSDKTestingClient(const Aws::Auth::AWSCredentials& credentials, const Aws::Client::ClientConfiguration& clientConfiguration);
65+
66+
/**
67+
* Initializes client to use specified credentials provider with specified client config. If http client factory is not supplied,
68+
* the default http client factory will be used
69+
*/
70+
TestNewServiceSDKTestingClient(const std::shared_ptr<Aws::Auth::AWSCredentialsProvider>& credentialsProvider,
71+
const Aws::Client::ClientConfiguration& clientConfiguration);
72+
73+
/* End of legacy constructors due deprecation */
74+
virtual ~TestNewServiceSDKTestingClient();
75+
76+
/**
77+
*
78+
*/
79+
virtual Model::GetFooOutcome GetFoo(const Model::GetFooRequest& request) const;
80+
81+
/**
82+
* A Callable wrapper for GetFoo that returns a future to the operation so that it can be executed in parallel to other requests.
83+
*/
84+
template <typename GetFooRequestT = Model::GetFooRequest>
85+
Model::GetFooOutcomeCallable GetFooCallable(const GetFooRequestT& request) const {
86+
return SubmitCallable(&TestNewServiceSDKTestingClient::GetFoo, request);
87+
}
88+
89+
/**
90+
* An Async wrapper for GetFoo that queues the request into a thread executor and triggers associated callback when operation has
91+
* finished.
92+
*/
93+
template <typename GetFooRequestT = Model::GetFooRequest>
94+
void GetFooAsync(const GetFooRequestT& request, const GetFooResponseReceivedHandler& handler,
95+
const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const {
96+
return SubmitAsync(&TestNewServiceSDKTestingClient::GetFoo, request, handler, context);
97+
}
98+
99+
/**
100+
*
101+
*/
102+
virtual Model::GetFoosOutcome GetFoos(const Model::GetFoosRequest& request = {}) const;
103+
104+
/**
105+
* A Callable wrapper for GetFoos that returns a future to the operation so that it can be executed in parallel to other requests.
106+
*/
107+
template <typename GetFoosRequestT = Model::GetFoosRequest>
108+
Model::GetFoosOutcomeCallable GetFoosCallable(const GetFoosRequestT& request = {}) const {
109+
return SubmitCallable(&TestNewServiceSDKTestingClient::GetFoos, request);
110+
}
111+
112+
/**
113+
* An Async wrapper for GetFoos that queues the request into a thread executor and triggers associated callback when operation has
114+
* finished.
115+
*/
116+
template <typename GetFoosRequestT = Model::GetFoosRequest>
117+
void GetFoosAsync(const GetFoosResponseReceivedHandler& handler,
118+
const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr,
119+
const GetFoosRequestT& request = {}) const {
120+
return SubmitAsync(&TestNewServiceSDKTestingClient::GetFoos, request, handler, context);
121+
}
122+
123+
/**
124+
*
125+
*
126+
* Queues the request into a thread executor.
127+
* The streamReadyHandler is triggered when the stream is ready to be written to.
128+
* The handler is triggered when the request is finished.
129+
*/
130+
virtual void PublishFoosAsync(Model::PublishFoosRequest& request, const PublishFoosStreamReadyHandler& streamReadyHandler,
131+
const PublishFoosResponseReceivedHandler& handler,
132+
const std::shared_ptr<const Aws::Client::AsyncCallerContext>& handlerContext = nullptr) const;
133+
134+
void OverrideEndpoint(const Aws::String& endpoint);
135+
std::shared_ptr<TestNewServiceSDKTestingEndpointProviderBase>& accessEndpointProvider();
136+
137+
private:
138+
friend class Aws::Client::ClientWithAsyncTemplateMethods<TestNewServiceSDKTestingClient>;
139+
void init(const TestNewServiceSDKTestingClientConfiguration& clientConfiguration);
140+
141+
TestNewServiceSDKTestingClientConfiguration m_clientConfiguration;
142+
std::shared_ptr<TestNewServiceSDKTestingEndpointProviderBase> m_endpointProvider;
143+
};
144+
145+
} // namespace TestNewServiceSDKTesting
146+
} // namespace Aws
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
/**
2+
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
* SPDX-License-Identifier: Apache-2.0.
4+
*/
5+
6+
#pragma once
7+
#include <aws/core/client/GenericClientConfiguration.h>
8+
#include <aws/core/endpoint/DefaultEndpointProvider.h>
9+
#include <aws/core/endpoint/EndpointParameter.h>
10+
#include <aws/core/utils/memory/stl/AWSString.h>
11+
#include <aws/core/utils/memory/stl/AWSVector.h>
12+
#include <aws/test-new-service-sdk-testing/TestNewServiceSDKTestingEndpointRules.h>
13+
#include <aws/test-new-service-sdk-testing/TestNewServiceSDKTesting_EXPORTS.h>
14+
15+
namespace Aws {
16+
namespace TestNewServiceSDKTesting {
17+
namespace Endpoint {
18+
using EndpointParameters = Aws::Endpoint::EndpointParameters;
19+
using Aws::Endpoint::DefaultEndpointProvider;
20+
using Aws::Endpoint::EndpointProviderBase;
21+
22+
using TestNewServiceSDKTestingClientContextParameters = Aws::Endpoint::ClientContextParameters;
23+
24+
using TestNewServiceSDKTestingClientConfiguration = Aws::Client::GenericClientConfiguration;
25+
using TestNewServiceSDKTestingBuiltInParameters = Aws::Endpoint::BuiltInParameters;
26+
27+
/**
28+
* The type for the TestNewServiceSDKTesting Client Endpoint Provider.
29+
* Inherit from this Base class / "Interface" should you want to provide a custom endpoint provider.
30+
* The SDK must use service-specific type for each service per specification.
31+
*/
32+
using TestNewServiceSDKTestingEndpointProviderBase =
33+
EndpointProviderBase<TestNewServiceSDKTestingClientConfiguration, TestNewServiceSDKTestingBuiltInParameters,
34+
TestNewServiceSDKTestingClientContextParameters>;
35+
36+
using TestNewServiceSDKTestingDefaultEpProviderBase =
37+
DefaultEndpointProvider<TestNewServiceSDKTestingClientConfiguration, TestNewServiceSDKTestingBuiltInParameters,
38+
TestNewServiceSDKTestingClientContextParameters>;
39+
40+
/**
41+
* Default endpoint provider used for this service
42+
*/
43+
class AWS_TESTNEWSERVICESDKTESTING_API TestNewServiceSDKTestingEndpointProvider : public TestNewServiceSDKTestingDefaultEpProviderBase {
44+
public:
45+
using TestNewServiceSDKTestingResolveEndpointOutcome = Aws::Endpoint::ResolveEndpointOutcome;
46+
47+
TestNewServiceSDKTestingEndpointProvider()
48+
: TestNewServiceSDKTestingDefaultEpProviderBase(Aws::TestNewServiceSDKTesting::TestNewServiceSDKTestingEndpointRules::GetRulesBlob(),
49+
Aws::TestNewServiceSDKTesting::TestNewServiceSDKTestingEndpointRules::RulesBlobSize) {
50+
}
51+
52+
~TestNewServiceSDKTestingEndpointProvider() {}
53+
};
54+
} // namespace Endpoint
55+
} // namespace TestNewServiceSDKTesting
56+
} // namespace Aws
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/**
2+
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
* SPDX-License-Identifier: Apache-2.0.
4+
*/
5+
6+
#pragma once
7+
#include <aws/test-new-service-sdk-testing/TestNewServiceSDKTesting_EXPORTS.h>
8+
9+
#include <cstddef>
10+
11+
namespace Aws {
12+
namespace TestNewServiceSDKTesting {
13+
class TestNewServiceSDKTestingEndpointRules {
14+
public:
15+
static const size_t RulesBlobStrLen;
16+
static const size_t RulesBlobSize;
17+
18+
static const char* GetRulesBlob();
19+
};
20+
} // namespace TestNewServiceSDKTesting
21+
} // namespace Aws
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
/**
2+
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
* SPDX-License-Identifier: Apache-2.0.
4+
*/
5+
6+
#pragma once
7+
8+
#include <aws/core/client/AWSErrorMarshaller.h>
9+
#include <aws/test-new-service-sdk-testing/TestNewServiceSDKTesting_EXPORTS.h>
10+
11+
namespace Aws {
12+
namespace Client {
13+
14+
class AWS_TESTNEWSERVICESDKTESTING_API TestNewServiceSDKTestingErrorMarshaller : public Aws::Client::JsonErrorMarshaller {
15+
public:
16+
Aws::Client::AWSError<Aws::Client::CoreErrors> FindErrorByName(const char* exceptionName) const override;
17+
};
18+
19+
} // namespace Client
20+
} // namespace Aws
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
/**
2+
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
* SPDX-License-Identifier: Apache-2.0.
4+
*/
5+
6+
#pragma once
7+
8+
#include <aws/core/client/AWSError.h>
9+
#include <aws/core/client/CoreErrors.h>
10+
#include <aws/test-new-service-sdk-testing/TestNewServiceSDKTesting_EXPORTS.h>
11+
12+
namespace Aws {
13+
namespace TestNewServiceSDKTesting {
14+
enum class TestNewServiceSDKTestingErrors {
15+
// From Core//
16+
//////////////////////////////////////////////////////////////////////////////////////////
17+
INCOMPLETE_SIGNATURE = 0,
18+
INTERNAL_FAILURE = 1,
19+
INVALID_ACTION = 2,
20+
INVALID_CLIENT_TOKEN_ID = 3,
21+
INVALID_PARAMETER_COMBINATION = 4,
22+
INVALID_QUERY_PARAMETER = 5,
23+
INVALID_PARAMETER_VALUE = 6,
24+
MISSING_ACTION = 7, // SDK should never allow
25+
MISSING_AUTHENTICATION_TOKEN = 8, // SDK should never allow
26+
MISSING_PARAMETER = 9, // SDK should never allow
27+
OPT_IN_REQUIRED = 10,
28+
REQUEST_EXPIRED = 11,
29+
SERVICE_UNAVAILABLE = 12,
30+
THROTTLING = 13,
31+
VALIDATION = 14,
32+
ACCESS_DENIED = 15,
33+
RESOURCE_NOT_FOUND = 16,
34+
UNRECOGNIZED_CLIENT = 17,
35+
MALFORMED_QUERY_STRING = 18,
36+
SLOW_DOWN = 19,
37+
REQUEST_TIME_TOO_SKEWED = 20,
38+
INVALID_SIGNATURE = 21,
39+
SIGNATURE_DOES_NOT_MATCH = 22,
40+
INVALID_ACCESS_KEY_ID = 23,
41+
REQUEST_TIMEOUT = 24,
42+
NETWORK_CONNECTION = 99,
43+
44+
UNKNOWN = 100,
45+
///////////////////////////////////////////////////////////////////////////////////////////
46+
47+
NO_SUCH_RESOURCE = static_cast<int>(Aws::Client::CoreErrors::SERVICE_EXTENSION_START_RANGE) + 1
48+
};
49+
50+
class AWS_TESTNEWSERVICESDKTESTING_API TestNewServiceSDKTestingError : public Aws::Client::AWSError<TestNewServiceSDKTestingErrors> {
51+
public:
52+
TestNewServiceSDKTestingError() {}
53+
TestNewServiceSDKTestingError(const Aws::Client::AWSError<Aws::Client::CoreErrors>& rhs)
54+
: Aws::Client::AWSError<TestNewServiceSDKTestingErrors>(rhs) {}
55+
TestNewServiceSDKTestingError(Aws::Client::AWSError<Aws::Client::CoreErrors>&& rhs)
56+
: Aws::Client::AWSError<TestNewServiceSDKTestingErrors>(rhs) {}
57+
TestNewServiceSDKTestingError(const Aws::Client::AWSError<TestNewServiceSDKTestingErrors>& rhs)
58+
: Aws::Client::AWSError<TestNewServiceSDKTestingErrors>(rhs) {}
59+
TestNewServiceSDKTestingError(Aws::Client::AWSError<TestNewServiceSDKTestingErrors>&& rhs)
60+
: Aws::Client::AWSError<TestNewServiceSDKTestingErrors>(rhs) {}
61+
62+
template <typename T>
63+
T GetModeledError();
64+
};
65+
66+
namespace TestNewServiceSDKTestingErrorMapper {
67+
AWS_TESTNEWSERVICESDKTESTING_API Aws::Client::AWSError<Aws::Client::CoreErrors> GetErrorForName(const char* errorName);
68+
}
69+
70+
} // namespace TestNewServiceSDKTesting
71+
} // namespace Aws

0 commit comments

Comments
 (0)