1 /*
2  * Copyright 2015-2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3  * 
4  * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
5  * the License. A copy of the License is located at
6  * 
7  * http://aws.amazon.com/apache2.0
8  * 
9  * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
10  * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
11  * and limitations under the License.
12  */

13
14 package software.amazon.awssdk.regions.partitionmetadata;
15
16 import software.amazon.awssdk.annotations.Generated;
17 import software.amazon.awssdk.annotations.SdkPublicApi;
18 import software.amazon.awssdk.regions.PartitionMetadata;
19
20 @SdkPublicApi
21 @Generated("software.amazon.awssdk:codegen")
22 public final class AwsPartitionMetadata implements PartitionMetadata {
23     private static final String DNS_SUFFIX = "amazonaws.com";
24
25     private static final String HOSTNAME = "{service}.{region}.{dnsSuffix}";
26
27     private static final String ID = "aws";
28
29     private static final String NAME = "AWS Standard";
30
31     private static final String REGION_REGEX = "^(us|eu|ap|sa|ca|me|af)\\-\\w+\\-\\d+$";
32
33     @Override
34     public String dnsSuffix() {
35         return DNS_SUFFIX;
36     }
37
38     @Override
39     public String hostname() {
40         return HOSTNAME;
41     }
42
43     @Override
44     public String id() {
45         return ID;
46     }
47
48     @Override
49     public String name() {
50         return NAME;
51     }
52
53     @Override
54     public String regionRegex() {
55         return REGION_REGEX;
56     }
57 }
58