Package org.jboss.netty.util.internal
Class SystemPropertyUtil
java.lang.Object
org.jboss.netty.util.internal.SystemPropertyUtil
A collection of utility methods to retrieve and parse the values of the Java system properties.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static boolean
private static final Pattern
private static boolean
private static final InternalLogger
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
Returnstrue
if and only if the system property with the specifiedkey
exists.static String
Returns the value of the Java system property with the specifiedkey
, while falling back tonull
if the property access fails.static String
Returns the value of the Java system property with the specifiedkey
, while falling back to the specified default value if the property access fails.static boolean
getBoolean
(String key, boolean def) Returns the value of the Java system property with the specifiedkey
, while falling back to the specified default value if the property access fails.static int
Returns the value of the Java system property with the specifiedkey
, while falling back to the specified default value if the property access fails.static long
Returns the value of the Java system property with the specifiedkey
, while falling back to the specified default value if the property access fails.private static void
private static void
-
Field Details
-
initializedLogger
private static boolean initializedLogger -
logger
-
loggedException
private static boolean loggedException -
INTEGER_PATTERN
-
-
Constructor Details
-
SystemPropertyUtil
private SystemPropertyUtil()
-
-
Method Details
-
contains
Returnstrue
if and only if the system property with the specifiedkey
exists. -
get
Returns the value of the Java system property with the specifiedkey
, while falling back tonull
if the property access fails.- Returns:
- the property value or
null
-
get
Returns the value of the Java system property with the specifiedkey
, while falling back to the specified default value if the property access fails.- Returns:
- the property value.
def
if there's no such property or if an access to the specified property is not allowed.
-
getBoolean
Returns the value of the Java system property with the specifiedkey
, while falling back to the specified default value if the property access fails.- Returns:
- the property value.
def
if there's no such property or if an access to the specified property is not allowed.
-
getInt
Returns the value of the Java system property with the specifiedkey
, while falling back to the specified default value if the property access fails.- Returns:
- the property value.
def
if there's no such property or if an access to the specified property is not allowed.
-
getLong
Returns the value of the Java system property with the specifiedkey
, while falling back to the specified default value if the property access fails.- Returns:
- the property value.
def
if there's no such property or if an access to the specified property is not allowed.
-
log
-
log
-