blob: d62a5c05826bcb0662ebad25c25dcbacde597f5c (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
|
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/s3/S3_EXPORTS.h>
#include <aws/s3/S3ClientConfiguration.h>
#include <aws/core/endpoint/DefaultEndpointProvider.h>
#include <aws/core/endpoint/EndpointParameter.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/s3/S3EndpointRules.h>
namespace Aws
{
namespace S3
{
namespace Endpoint
{
using S3ClientConfiguration = Aws::S3::S3ClientConfiguration;
using EndpointParameters = Aws::Endpoint::EndpointParameters;
using Aws::Endpoint::EndpointProviderBase;
using Aws::Endpoint::DefaultEndpointProvider;
class AWS_S3_API S3ClientContextParameters : public Aws::Endpoint::ClientContextParameters
{
public:
virtual ~S3ClientContextParameters(){};
/**
* Forces this client to use path-style addressing for buckets.
*/
void SetForcePathStyle(bool value);
const ClientContextParameters::EndpointParameter& GetForcePathStyle() const;
/**
* Disables this client's usage of Multi-Region Access Points.
*/
void SetDisableMultiRegionAccessPoints(bool value);
const ClientContextParameters::EndpointParameter& GetDisableMultiRegionAccessPoints() const;
/**
* Enables this client to use an ARN's region when constructing an endpoint instead of the client's configured region.
*/
void SetUseArnRegion(bool value);
const ClientContextParameters::EndpointParameter& GetUseArnRegion() const;
/**
* Enables this client to use S3 Transfer Acceleration endpoints.
*/
void SetAccelerate(bool value);
const ClientContextParameters::EndpointParameter& GetAccelerate() const;
};
class AWS_S3_API S3BuiltInParameters : public Aws::Endpoint::BuiltInParameters
{
public:
virtual ~S3BuiltInParameters(){};
using Aws::Endpoint::BuiltInParameters::SetFromClientConfiguration;
virtual void SetFromClientConfiguration(const S3ClientConfiguration& config);
};
/**
* The type for the S3 Client Endpoint Provider.
* Inherit from this Base class / "Interface" should you want to provide a custom endpoint provider.
* The SDK must use service-specific type for each service per specification.
*/
using S3EndpointProviderBase =
EndpointProviderBase<S3ClientConfiguration, S3BuiltInParameters, S3ClientContextParameters>;
using S3DefaultEpProviderBase =
DefaultEndpointProvider<S3ClientConfiguration, S3BuiltInParameters, S3ClientContextParameters>;
} // namespace Endpoint
} // namespace S3
namespace Endpoint
{
/**
* Export endpoint provider symbols from DLL
*/
template class AWS_S3_API
Aws::Endpoint::EndpointProviderBase<S3::Endpoint::S3ClientConfiguration, S3::Endpoint::S3BuiltInParameters, S3::Endpoint::S3ClientContextParameters>;
template class AWS_S3_API
Aws::Endpoint::DefaultEndpointProvider<S3::Endpoint::S3ClientConfiguration, S3::Endpoint::S3BuiltInParameters, S3::Endpoint::S3ClientContextParameters>;
} // namespace Endpoint
namespace S3
{
namespace Endpoint
{
/**
* Default endpoint provider used for this service
*/
class AWS_S3_API S3EndpointProvider : public S3DefaultEpProviderBase
{
public:
using S3ResolveEndpointOutcome = Aws::Endpoint::ResolveEndpointOutcome;
S3EndpointProvider()
: S3DefaultEpProviderBase(Aws::S3::S3EndpointRules::GetRulesBlob(), Aws::S3::S3EndpointRules::RulesBlobSize)
{}
~S3EndpointProvider()
{
}
};
} // namespace Endpoint
} // namespace S3
} // namespace Aws
|