ServiceBuilder.requires(org.jboss.msc.service.ServiceName)
method instead. This class will be removed in a future release.@Deprecated public final class EnvironmentPropertyValue extends java.lang.Object implements Value<java.lang.String>, java.security.PrivilegedAction<java.lang.String>
System.getenv(String)
Constructor and Description |
---|
EnvironmentPropertyValue(java.lang.String propertyName)
Deprecated.
Construct a new instance.
|
EnvironmentPropertyValue(java.lang.String propertyName,
java.security.AccessControlContext accessControlContext)
Deprecated.
Construct a new instance.
|
EnvironmentPropertyValue(java.lang.String propertyName,
java.security.AccessControlContext accessControlContext,
Value<?> defaultValue)
Deprecated.
Construct a new instance.
|
EnvironmentPropertyValue(java.lang.String propertyName,
Value<?> defaultValue)
Deprecated.
Construct a new instance.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getValue()
Deprecated.
Get the actual dependency value.
|
java.lang.String |
run()
Deprecated.
Fetch the property in an unprivileged context.
|
public EnvironmentPropertyValue(java.lang.String propertyName)
propertyName
- the property name to readpublic EnvironmentPropertyValue(java.lang.String propertyName, java.security.AccessControlContext accessControlContext)
propertyName
- the property name to readaccessControlContext
- the access control context in which to fetch the property valuepublic EnvironmentPropertyValue(java.lang.String propertyName, Value<?> defaultValue)
propertyName
- the property name to readdefaultValue
- the value to use if the property is unsetpublic EnvironmentPropertyValue(java.lang.String propertyName, java.security.AccessControlContext accessControlContext, Value<?> defaultValue)
propertyName
- the property name to readaccessControlContext
- the access control context in which to fetch the property valuedefaultValue
- the value to use if the property is unsetpublic java.lang.String getValue() throws java.lang.IllegalStateException, java.lang.IllegalArgumentException
getValue
in interface Value<java.lang.String>
java.lang.IllegalStateException
- if the value is time-sensitive and the current state does not allow retrieval.java.lang.IllegalArgumentException
- when the value cannot be read due to misconfigurationpublic java.lang.String run()
run
in interface java.security.PrivilegedAction<java.lang.String>
Copyright © 2012 JBoss, a division of Red Hat, Inc.