@PublicApi public interface AlluxioConfiguration
Modifier and Type | Method and Description |
---|---|
boolean |
clusterDefaultsLoaded() |
AlluxioProperties |
copyProperties()
Gets a copy of the
AlluxioProperties which back the AlluxioConfiguration . |
Object |
get(PropertyKey key)
Gets the value for the given key in the
Properties ; if this key is not found, a
RuntimeException is thrown. |
Object |
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.
|
int |
getInt(PropertyKey key)
Gets the integer representation of the value for the given key.
|
List<String> |
getList(PropertyKey key)
Gets the value for the given key as a list.
|
long |
getLong(PropertyKey key)
Gets the long integer representation of the value for the given key.
|
long |
getMs(PropertyKey key)
Gets the time of key in millisecond unit.
|
Map<String,Object> |
getNestedProperties(PropertyKey prefixKey)
Gets a set of properties that share a given common prefix key as a map.
|
default Object |
getOrDefault(PropertyKey key,
Object defaultValue,
ConfigurationValueOptions options) |
default <T> T |
getOrDefault(PropertyKey key,
T defaultValue) |
Source |
getSource(PropertyKey key) |
String |
getString(PropertyKey key)
Gets the String value for the given 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,Object> |
toMap() |
Map<String,Object> |
toMap(ConfigurationValueOptions opts) |
Set<PropertyKey> |
userKeySet() |
void |
validate()
Validates the configuration.
|
Object get(PropertyKey key)
Properties
; if this key is not found, a
RuntimeException is thrown.key
- the key to get the value forObject 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 <T> T getOrDefault(PropertyKey key, T defaultValue)
T
- the type of default valuekey
- the key to get the value fordefaultValue
- the value to return if no value is set for the specified keydefault Object getOrDefault(PropertyKey key, Object 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()
String getString(PropertyKey key)
key
- the key to get the value forString
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
boolean getBoolean(PropertyKey key)
key
- the key to get the value forboolean
List<String> getList(PropertyKey key)
key
- the key to get the value for<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,Object> getNestedProperties(PropertyKey prefixKey)
prefixKey
- the prefix keyAlluxioProperties copyProperties()
AlluxioProperties
which back the AlluxioConfiguration
.Source getSource(PropertyKey key)
key
- the property keydefault Map<String,Object> toMap()
Map<String,Object> 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.