Enum DefaultLookups
- All Implemented Interfaces:
Serializable
,Comparable<DefaultLookups>
An enumeration class defining constants for built-in Lookup
objects available for
Configuration
instances.
When a new configuration object derived from AbstractConfiguration
is created, it installs a
ConfigurationInterpolator
containing a default set of Lookup
objects. These lookups are
defined by this enumeration class, however not all lookups may be included in the defaults. See
ConfigurationInterpolator.getDefaultPrefixLookups()
for details.
All the Lookup
s defined here are state-less, thus their instances can be shared between multiple
configuration objects. Therefore, it makes sense to keep shared instances in this enumeration class.
- "base64Decoder" for the
Base64DecoderStringLookup
since Apache Commons Text 1.6. - "base64Encoder" for the
Base64EncoderStringLookup
since Apache Commons Text 1.6. - "const" for the
ConstantStringLookup
since Apache Commons Text 1.5. - "date" for the
DateStringLookup
. - "env" for the
EnvironmentVariableStringLookup
. - "file" for the
FileStringLookup
since Apache Commons Text 1.5. - "java" for the
JavaPlatformStringLookup
. - "localhost" for the
LocalHostStringLookup
, see#localHostStringLookup()
for key names; since Apache Commons Text 1.3. - "properties" for the
PropertiesStringLookup
since Apache Commons Text 1.5. - "resourceBundle" for the
ResourceBundleStringLookup
since Apache Commons Text 1.5. - "script" for the
ScriptStringLookup
since Apache Commons Text 1.5. - "sys" for the
SystemPropertyStringLookup
. - "url" for the
UrlStringLookup
since Apache Commons Text 1.5. - "urlDecoder" for the
UrlDecoderStringLookup
since Apache Commons Text 1.6. - "urlEncoder" for the
UrlEncoderStringLookup
since Apache Commons Text 1.6. - "xml" for the
XmlStringLookup
since Apache Commons Text 1.5.
- Since:
- 2.0
-
Enum Constant Summary
Enum ConstantDescriptionThe lookup for Base64 decoding, accessed using the prefix"base64Decoder"
.The lookup for Base64 encoding, accessed using the prefix"base64Encoder"
.The lookup for Java constants, accessed using the prefix"const"
.The lookup for the current date in a specified format, accessed using the prefix"date"
.The lookup for DNS, accessed using the prefix"dns"
.The lookup for environment properties, accessed using the prefix"env"
.The lookup for file content, accessed using the prefix"file"
.The lookup for Java platform information, accessed using the prefix"java"
.The lookup for localhost information, accessed using the prefix"localhost"
.The lookup for properties, accessed using the prefix"properties"
.The lookup for resource bundles, accessed using the prefix"resourceBundle"
.The lookup for scripts, accessed using the prefix"script"
.The lookup for system properties, accessed using the prefix"sys"
.The lookup for URLs, accessed using the prefix"url"
.The lookup for URL decoding, accessed using the prefix"urlDecoder"
.The lookup for URL encoding, accessed using the prefix"urlEncoder"
.The lookup for XML content, accessed using the prefix"xml"
. -
Method Summary
Modifier and TypeMethodDescriptionGets the standardLookup
instance of this kind.Gets the standard prefix for the lookup object of this kind.static DefaultLookups
Returns the enum constant of this type with the specified name.static DefaultLookups[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
BASE64_DECODER
The lookup for Base64 decoding, accessed using the prefix"base64Decoder"
.- Since:
- 2.4
- See Also:
-
BASE64_ENCODER
The lookup for Base64 encoding, accessed using the prefix"base64Encoder"
.- Since:
- 2.4
- See Also:
-
CONST
The lookup for Java constants, accessed using the prefix"const"
.- Since:
- 2.4
- See Also:
-
DATE
The lookup for the current date in a specified format, accessed using the prefix"date"
.- Since:
- 2.4
- See Also:
-
DNS
The lookup for DNS, accessed using the prefix"dns"
.- Since:
- 2.6
- See Also:
-
ENVIRONMENT
The lookup for environment properties, accessed using the prefix"env"
. -
FILE
The lookup for file content, accessed using the prefix"file"
.- Since:
- 2.4
- See Also:
-
JAVA
The lookup for Java platform information, accessed using the prefix"java"
.- Since:
- 2.4
- See Also:
-
LOCAL_HOST
The lookup for localhost information, accessed using the prefix"localhost"
.- Since:
- 2.4
- See Also:
-
PROPERTIES
The lookup for properties, accessed using the prefix"properties"
.- Since:
- 2.4
- See Also:
-
RESOURCE_BUNDLE
The lookup for resource bundles, accessed using the prefix"resourceBundle"
.- Since:
- 2.4
- See Also:
-
SCRIPT
The lookup for scripts, accessed using the prefix"script"
.- Since:
- 2.4
- See Also:
-
SYSTEM_PROPERTIES
The lookup for system properties, accessed using the prefix"sys"
. -
URL
The lookup for URLs, accessed using the prefix"url"
.- Since:
- 2.4
- See Also:
-
URL_DECODER
The lookup for URL decoding, accessed using the prefix"urlDecoder"
.- Since:
- 2.4
- See Also:
-
URL_ENCODER
The lookup for URL encoding, accessed using the prefix"urlEncoder"
.- Since:
- 2.4
- See Also:
-
XML
The lookup for XML content, accessed using the prefix"xml"
.- Since:
- 2.4
- See Also:
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
getLookup
Gets the standardLookup
instance of this kind.- Returns:
- the associated
Lookup
object
-
getPrefix
Gets the standard prefix for the lookup object of this kind.- Returns:
- the prefix
-