@PublicApi public interface AlluxioConfiguration
Modifier and Type | Method and Description |
---|---|
boolean |
clusterDefaultsLoaded() |
AlluxioProperties |
copyProperties()
Gets a copy of the
AlluxioProperties which back the AlluxioConfiguration . |
String |
get(PropertyKey key)
Gets the value for the given key in the
Properties ; if this key is not found, a
RuntimeException is thrown. |
String |
get(PropertyKey key,
ConfigurationValueOptions options)
Gets the value for the given key in the
Properties ; if this key is not found, a
RuntimeException is thrown. |
boolean |
getBoolean(PropertyKey key)
Gets the boolean representation of the value for the given key.
|
long |
getBytes(PropertyKey key)
Gets the bytes of the value for the given key.
|
<T> Class<T> |
getClass(PropertyKey key)
Gets the value for the given key as a class.
|
double |
getDouble(PropertyKey key)
Gets the double representation of the value for the given key.
|
java.time.Duration |
getDuration(PropertyKey key)
Gets the time of the key as a duration.
|
<T extends Enum<T>> |
getEnum(PropertyKey key,
Class<T> enumType)
Gets the value for the given key as an enum value.
|
float |
getFloat(PropertyKey key)
Gets the float representation of the value for the given key.
|
int |
getInt(PropertyKey key)
Gets the integer representation of the value for the given key.
|
List<String> |
getList(PropertyKey key,
String delimiter)
Gets the value for the given key as a list.
|
long |
getLong(PropertyKey key)
Gets the long representation of the value for the given key.
|
long |
getMs(PropertyKey key)
Gets the time of key in millisecond unit.
|
Map<String,String> |
getNestedProperties(PropertyKey prefixKey)
Gets a set of properties that share a given common prefix key as a map.
|
default String |
getOrDefault(PropertyKey key,
String defaultValue) |
default String |
getOrDefault(PropertyKey key,
String defaultValue,
ConfigurationValueOptions options) |
Source |
getSource(PropertyKey key) |
default String |
hash() |
boolean |
isSet(PropertyKey key)
Checks if the configuration contains a value for the given key.
|
boolean |
isSetByUser(PropertyKey key) |
Set<PropertyKey> |
keySet() |
default Map<String,String> |
toMap() |
Map<String,String> |
toMap(ConfigurationValueOptions opts) |
Set<PropertyKey> |
userKeySet() |
void |
validate()
Validates the configuration.
|
String get(PropertyKey key)
Properties
; if this key is not found, a
RuntimeException is thrown.key
- the key to get the value forString get(PropertyKey key, ConfigurationValueOptions options)
Properties
; if this key is not found, a
RuntimeException is thrown.key
- the key to get the value foroptions
- options for getting configuration valuedefault String getOrDefault(PropertyKey key, String defaultValue)
key
- the key to get the value fordefaultValue
- the value to return if no value is set for the specified keydefault String getOrDefault(PropertyKey key, String defaultValue, ConfigurationValueOptions options)
key
- the key to get the value fordefaultValue
- the value to return if no value is set for the specified keyoptions
- options for getting configuration valueboolean isSet(PropertyKey key)
key
- the key to checkboolean isSetByUser(PropertyKey key)
key
- the key to checkSet<PropertyKey> keySet()
Set<PropertyKey> userKeySet()
int getInt(PropertyKey key)
key
- the key to get the value forint
long getLong(PropertyKey key)
key
- the key to get the value forlong
double getDouble(PropertyKey key)
key
- the key to get the value fordouble
float getFloat(PropertyKey key)
key
- the key to get the value forfloat
boolean getBoolean(PropertyKey key)
key
- the key to get the value forboolean
List<String> getList(PropertyKey key, String delimiter)
key
- the key to get the value fordelimiter
- the delimiter to split the values<T extends Enum<T>> T getEnum(PropertyKey key, Class<T> enumType)
T
- the type of the enumkey
- the key to get the value forenumType
- the type of the enumlong getBytes(PropertyKey key)
key
- the key to get the value forlong getMs(PropertyKey key)
key
- the key to get the value forjava.time.Duration getDuration(PropertyKey key)
key
- the key to get the value for<T> Class<T> getClass(PropertyKey key)
T
- the type of the classkey
- the key to get the value forMap<String,String> getNestedProperties(PropertyKey prefixKey)
prefixKey
- the prefix keyAlluxioProperties copyProperties()
AlluxioProperties
which back the AlluxioConfiguration
.Source getSource(PropertyKey key)
key
- the property keydefault Map<String,String> toMap()
Map<String,String> toMap(ConfigurationValueOptions opts)
opts
- options for formatting the configuration valuesvoid validate()
IllegalStateException
- if invalid configuration is encounteredboolean clusterDefaultsLoaded()
default String hash()
Copyright © 2023. All Rights Reserved.