public class DefaultJasperReportsContext extends Object implements JasperReportsContext
| Modifier and Type | Field and Description |
|---|---|
static String |
DEFAULT_PROPERTIES_FILE
The default properties file.
|
static String |
EXCEPTION_MESSAGE_KEY_DEFAULT_PROPERTIES_FILE_NOT_FOUND |
static String |
EXCEPTION_MESSAGE_KEY_LOAD_DEFAULT_PROPERTIES_FAILURE |
static String |
EXCEPTION_MESSAGE_KEY_LOAD_PROPERTIES_FAILURE |
static String |
EXCEPTION_MESSAGE_KEY_LOAD_PROPERTIES_FILE_FAILURE |
protected ConcurrentHashMap<String,String> |
properties |
static String |
PROPERTIES_FILE
The name of the system property that specifies the properties file name.
|
| Modifier and Type | Method and Description |
|---|---|
protected static Properties |
getDefaultProperties()
Sets the default properties.
|
<T> List<T> |
getExtensions(Class<T> extensionType)
Returns a list of extension objects for a specific extension type.
|
static DefaultJasperReportsContext |
getInstance() |
Object |
getOwnValue(String key) |
Map<String,String> |
getProperties() |
String |
getProperty(String key)
Returns the value of the property.
|
protected static String |
getSystemProperty(String propertyName) |
Object |
getValue(String key) |
protected void |
initProperties()
Loads the properties.
|
protected void |
loadSystemProperties() |
protected void |
loadSystemProperty(String sysKey,
String propKey) |
void |
removeProperty(String key) |
void |
setProperty(String key,
String value) |
void |
setValue(String key,
Object value) |
public static final String DEFAULT_PROPERTIES_FILE
public static final String PROPERTIES_FILE
public static final String EXCEPTION_MESSAGE_KEY_LOAD_DEFAULT_PROPERTIES_FAILURE
public static final String EXCEPTION_MESSAGE_KEY_LOAD_PROPERTIES_FAILURE
public static final String EXCEPTION_MESSAGE_KEY_LOAD_PROPERTIES_FILE_FAILURE
public static final String EXCEPTION_MESSAGE_KEY_DEFAULT_PROPERTIES_FILE_NOT_FOUND
protected volatile ConcurrentHashMap<String,String> properties
public static DefaultJasperReportsContext getInstance()
protected void initProperties()
protected void loadSystemProperties()
protected static Properties getDefaultProperties() throws JRException
JRExceptionpublic Object getValue(String key)
getValue in interface JasperReportsContextpublic Object getOwnValue(String key)
getOwnValue in interface JasperReportsContextpublic void setValue(String key, Object value)
setValue in interface JasperReportsContextpublic <T> List<T> getExtensions(Class<T> extensionType)
getExtensions in interface JasperReportsContextT - generic extension typeextensionType - the extension typepublic String getProperty(String key)
getProperty in interface JasperReportsContextkey - the keypublic void setProperty(String key, String value)
setProperty in interface JasperReportsContextpublic void removeProperty(String key)
removeProperty in interface JasperReportsContextpublic Map<String,String> getProperties()
getProperties in interface JasperReportsContextCopyright © 2017. All rights reserved.