public class OsgiPropertyUtils
extends java.lang.Object
BundleContext.getProperty does
not check any values that are bundle-specific: it first checks
the list of properties used to start the framework, and then checks
system properties to retrieve the property value.FrameworkUtil.getBundle(Class),
BundleContext.getProperty(String)| Constructor and Description |
|---|
OsgiPropertyUtils() |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
getBoolean(java.lang.String propertyName)
Retrieve the value of the specified property from framework/system properties.
|
static int |
getInteger(java.lang.String propertyName,
int defaultValue)
Retrieve the value of the specified property from framework/system properties.
|
static long |
getLong(java.lang.String propertyName,
long defaultValue)
Retrieve the value of the specified property from framework/system properties.
|
static java.lang.String |
getProperty(java.lang.String propertyName,
java.lang.String defaultValue)
Retrieve the value of the specified property from framework/system properties.
|
public static java.lang.String getProperty(java.lang.String propertyName,
java.lang.String defaultValue)
propertyName - Name of propertydefaultValue - Default value to return if property is not setpublic static int getInteger(java.lang.String propertyName,
int defaultValue)
propertyName - Name of propertydefaultValue - Default value to return if property is not setpublic static long getLong(java.lang.String propertyName,
long defaultValue)
propertyName - Name of propertydefaultValue - Default value to return if property is not setpublic static boolean getBoolean(java.lang.String propertyName)
propertyName - Name of propertydefaultValue - Default value to return if property is not set