Skip to content

Commit f25f37d

Browse files
committed
fix copy and move constructors for client configuration with endpoint discovery
1 parent d7542e5 commit f25f37d

File tree

4 files changed

+114
-0
lines changed

4 files changed

+114
-0
lines changed

generated/src/aws-cpp-sdk-dynamodb/include/aws/dynamodb/DynamoDBClientConfiguration.h

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,34 @@ namespace Aws
1919
static const bool EndpointDiscoverySupported = true;
2020
static const bool EndpointDiscoveryRequired = false;
2121

22+
DynamoDBClientConfiguration(const DynamoDBClientConfiguration& other)
23+
: Aws::Client::GenericClientConfiguration(other),
24+
enableEndpointDiscovery(BaseClientConfigClass::enableEndpointDiscovery)
25+
{
26+
}
27+
28+
DynamoDBClientConfiguration(DynamoDBClientConfiguration&& other) noexcept
29+
: Aws::Client::GenericClientConfiguration(std::move(other)),
30+
enableEndpointDiscovery(BaseClientConfigClass::enableEndpointDiscovery)
31+
{
32+
}
33+
34+
DynamoDBClientConfiguration& operator=(const DynamoDBClientConfiguration& other)
35+
{
36+
if (this == &other)
37+
return *this;
38+
Aws::Client::GenericClientConfiguration::operator =(other);
39+
return *this;
40+
}
41+
42+
DynamoDBClientConfiguration& operator=(DynamoDBClientConfiguration&& other) noexcept
43+
{
44+
if (this == &other)
45+
return *this;
46+
Aws::Client::GenericClientConfiguration::operator =(std::move(other));
47+
return *this;
48+
}
49+
2250
DynamoDBClientConfiguration(const Client::ClientConfigurationInitValues &configuration = {});
2351

2452
/**

generated/src/aws-cpp-sdk-timestream-query/include/aws/timestream-query/TimestreamQueryClientConfiguration.h

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,34 @@ namespace Aws
1919
static const bool EndpointDiscoverySupported = true;
2020
static const bool EndpointDiscoveryRequired = true;
2121

22+
TimestreamQueryClientConfiguration(const TimestreamQueryClientConfiguration& other)
23+
: Aws::Client::GenericClientConfiguration(other),
24+
enableEndpointDiscovery(BaseClientConfigClass::enableEndpointDiscovery)
25+
{
26+
}
27+
28+
TimestreamQueryClientConfiguration(TimestreamQueryClientConfiguration&& other) noexcept
29+
: Aws::Client::GenericClientConfiguration(std::move(other)),
30+
enableEndpointDiscovery(BaseClientConfigClass::enableEndpointDiscovery)
31+
{
32+
}
33+
34+
TimestreamQueryClientConfiguration& operator=(const TimestreamQueryClientConfiguration& other)
35+
{
36+
if (this == &other)
37+
return *this;
38+
Aws::Client::GenericClientConfiguration::operator =(other);
39+
return *this;
40+
}
41+
42+
TimestreamQueryClientConfiguration& operator=(TimestreamQueryClientConfiguration&& other) noexcept
43+
{
44+
if (this == &other)
45+
return *this;
46+
Aws::Client::GenericClientConfiguration::operator =(std::move(other));
47+
return *this;
48+
}
49+
2250
TimestreamQueryClientConfiguration(const Client::ClientConfigurationInitValues &configuration = {});
2351

2452
/**

generated/src/aws-cpp-sdk-timestream-write/include/aws/timestream-write/TimestreamWriteClientConfiguration.h

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,34 @@ namespace Aws
1919
static const bool EndpointDiscoverySupported = true;
2020
static const bool EndpointDiscoveryRequired = true;
2121

22+
TimestreamWriteClientConfiguration(const TimestreamWriteClientConfiguration& other)
23+
: Aws::Client::GenericClientConfiguration(other),
24+
enableEndpointDiscovery(BaseClientConfigClass::enableEndpointDiscovery)
25+
{
26+
}
27+
28+
TimestreamWriteClientConfiguration(TimestreamWriteClientConfiguration&& other) noexcept
29+
: Aws::Client::GenericClientConfiguration(std::move(other)),
30+
enableEndpointDiscovery(BaseClientConfigClass::enableEndpointDiscovery)
31+
{
32+
}
33+
34+
TimestreamWriteClientConfiguration& operator=(const TimestreamWriteClientConfiguration& other)
35+
{
36+
if (this == &other)
37+
return *this;
38+
Aws::Client::GenericClientConfiguration::operator =(other);
39+
return *this;
40+
}
41+
42+
TimestreamWriteClientConfiguration& operator=(TimestreamWriteClientConfiguration&& other) noexcept
43+
{
44+
if (this == &other)
45+
return *this;
46+
Aws::Client::GenericClientConfiguration::operator =(std::move(other));
47+
return *this;
48+
}
49+
2250
TimestreamWriteClientConfiguration(const Client::ClientConfigurationInitValues &configuration = {});
2351

2452
/**

tools/code-generation/generator/src/main/resources/com/amazonaws/util/awsclientgenerator/velocity/cpp/common/ServiceClientConfigurationHeader.vm

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,36 @@ namespace ${rootNamespace}
4545
#end
4646
#end
4747

48+
#if($metadata.hasEndpointDiscoveryTrait)
49+
${metadata.classNamePrefix}ClientConfiguration(const ${metadata.classNamePrefix}ClientConfiguration& other)
50+
: Aws::Client::GenericClientConfiguration(other),
51+
enableEndpointDiscovery(BaseClientConfigClass::enableEndpointDiscovery)
52+
{
53+
}
54+
55+
${metadata.classNamePrefix}ClientConfiguration(${metadata.classNamePrefix}ClientConfiguration&& other) noexcept
56+
: Aws::Client::GenericClientConfiguration(std::move(other)),
57+
enableEndpointDiscovery(BaseClientConfigClass::enableEndpointDiscovery)
58+
{
59+
}
60+
61+
${metadata.classNamePrefix}ClientConfiguration& operator=(const ${metadata.classNamePrefix}ClientConfiguration& other)
62+
{
63+
if (this == &other)
64+
return *this;
65+
Aws::Client::GenericClientConfiguration::operator =(other);
66+
return *this;
67+
}
68+
69+
${metadata.classNamePrefix}ClientConfiguration& operator=(${metadata.classNamePrefix}ClientConfiguration&& other) noexcept
70+
{
71+
if (this == &other)
72+
return *this;
73+
Aws::Client::GenericClientConfiguration::operator =(std::move(other));
74+
return *this;
75+
}
76+
77+
#end
4878
${metadata.classNamePrefix}ClientConfiguration(const Client::ClientConfigurationInitValues &configuration = {});
4979

5080
/**

0 commit comments

Comments
 (0)