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 booleanprivate static final Patternprivate static booleanprivate static final InternalLogger -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanReturnstrueif and only if the system property with the specifiedkeyexists.static StringReturns the value of the Java system property with the specifiedkey, while falling back tonullif the property access fails.static StringReturns the value of the Java system property with the specifiedkey, while falling back to the specified default value if the property access fails.static booleangetBoolean(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 intReturns the value of the Java system property with the specifiedkey, while falling back to the specified default value if the property access fails.static longReturns 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 voidprivate 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
Returnstrueif and only if the system property with the specifiedkeyexists. -
get
Returns the value of the Java system property with the specifiedkey, while falling back tonullif 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.
defif 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.
defif 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.
defif 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.
defif there's no such property or if an access to the specified property is not allowed.
-
log
-
log
-