public class SystemUtil extends Object
| Type Params | Return Type | Name and description |
|---|---|---|
|
public static boolean |
getBooleanSafe(String name)Retrieves a Boolean System property, or returns false if:
|
|
public static Integer |
getIntegerSafe(String name, Integer def)Retrieves an Integer System property |
|
public static Long |
getLongSafe(String name, Long def)Retrieves a Long System property |
|
public static String |
getSystemPropertySafe(String name, String defaultValue)Retrieves a System property, or returns some default value if:
|
|
public static String |
getSystemPropertySafe(String name)Retrieves a System property, or null if:
|
|
public static String |
setSystemPropertyFrom(String nameValue)Sets a system property from a name=value String.
|
|
public static String |
setSystemPropertyFromSafe(String nameValue)Sets a system property from a name=value String.
|
Retrieves a Boolean System property, or returns false if:
name - the name of the system property.Retrieves an Integer System property
name - the name of the system property.def - the default valueRetrieves a Long System property
name - the name of the system property.def - the default valueRetrieves a System property, or returns some default value if:
name - the name of the system property.defaultValue - a default value.Retrieves a System property, or null if:
name - the name of the system property. Sets a system property from a name=value String.
If no '=' is found, the property is assumed to be a Boolean flag with value true.
nameValue - the non-null name=value String Sets a system property from a name=value String.
If no '=' is found, the property is assumed to be a Boolean flag with value true.
Does nothing if a Security manager is in place which doesn't allow the operation.
nameValue - the non-null name=value String