Class StaticClientEndpointProvider
java.lang.Object
software.amazon.awssdk.core.internal.StaticClientEndpointProvider
- All Implemented Interfaces:
ClientEndpointProvider
@SdkInternalApi
public class StaticClientEndpointProvider
extends Object
implements ClientEndpointProvider
An implementation of
ClientEndpointProvider that uses static values.- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionStaticClientEndpointProvider(URI clientEndpoint, boolean isEndpointOverridden) -
Method Summary
Modifier and TypeMethodDescriptionRetrieve the client endpoint from this provider.booleaninthashCode()booleanReturns true if this endpoint was specified as an override by the customer, or false if it was determined automatically by the SDK.final StringReturns the client endpoint as a string with the query and user-info components stripped, as the rules engine'sParseURLrejects a URI carrying query parameters.toString()
-
Constructor Details
-
StaticClientEndpointProvider
-
-
Method Details
-
sanitizedEndpointString
Returns the client endpoint as a string with the query and user-info components stripped, as the rules engine'sParseURLrejects a URI carrying query parameters. Returnsnullif the endpoint is not overridden.Returns the same
Stringreference on every call, because the value is computed once at construction. That removes a URI construction and its string conversion from every request that resolves an endpoint against an overridden client endpoint.finalso that the cached value cannot be shadowed by a subclass whose overridden accessors the constructor did not see.- Specified by:
sanitizedEndpointStringin interfaceClientEndpointProvider
-
clientEndpoint
Description copied from interface:ClientEndpointProviderRetrieve the client endpoint from this provider.- Specified by:
clientEndpointin interfaceClientEndpointProvider
-
isEndpointOverridden
public boolean isEndpointOverridden()Description copied from interface:ClientEndpointProviderReturns true if this endpoint was specified as an override by the customer, or false if it was determined automatically by the SDK.- Specified by:
isEndpointOverriddenin interfaceClientEndpointProvider
-
equals
-
hashCode
-
toString
-