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

15
16 package software.amazon.awssdk.utils;
17
18 import software.amazon.awssdk.annotations.SdkProtectedApi;
19
20 /**
21  * The system properties usually provided by the Java runtime.
22  */

23 @SdkProtectedApi
24 public enum JavaSystemSetting implements SystemSetting {
25     JAVA_VERSION("java.version"),
26     JAVA_VENDOR("java.vendor"),
27     TEMP_DIRECTORY("java.io.tmpdir"),
28     JAVA_VM_NAME("java.vm.name"),
29     JAVA_VM_VERSION("java.vm.version"),
30
31     OS_NAME("os.name"),
32     OS_VERSION("os.version"),
33
34     USER_HOME("user.home"),
35     USER_LANGUAGE("user.language"),
36     USER_REGION("user.region"),
37     USER_NAME("user.name"),
38
39     SSL_KEY_STORE("javax.net.ssl.keyStore"),
40     SSL_KEY_STORE_PASSWORD("javax.net.ssl.keyStorePassword"),
41     SSL_KEY_STORE_TYPE("javax.net.ssl.keyStoreType")
42     ;
43
44     private final String systemProperty;
45
46     JavaSystemSetting(String systemProperty) {
47         this.systemProperty = systemProperty;
48     }
49
50     @Override
51     public String property() {
52         return systemProperty;
53     }
54
55     @Override
56     public String environmentVariable() {
57         return null;
58     }
59
60     @Override
61     public String defaultValue() {
62         return null;
63     }
64 }
65