Class DefaultJasperReportCacheService
java.lang.Object
de.hybris.platform.cockpit.reports.impl.DefaultJasperReportCacheService
- All Implemented Interfaces:
JasperReportCacheService
Default implementation for
JasperReportCacheService-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionnet.sf.jasperreports.engine.JasperReportReturns cached report.org.zkoss.image.AImageReturns cached image for widget.voidClears cachebooleanremove(JasperWidgetPreferencesModel widget) Removes widget from cache.voidsetJasperMediaService(JasperMediaService jasperMediaService) voidsetJasperReportCompileService(JasperReportCompileService jasperReportCompileService) voidsetJasperReportExportService(JasperReportExportService jasperReportExportService) voidsetJasperReportFillService(JasperReportFillService jasperReportFillService) booleanupdate(JasperWidgetPreferencesModel widget) Updates cached report for specific widget.
-
Constructor Details
-
DefaultJasperReportCacheService
public DefaultJasperReportCacheService()
-
-
Method Details
-
getCompiledReport
public net.sf.jasperreports.engine.JasperReport getCompiledReport(JasperWidgetPreferencesModel widget) Returns cached report. If no report is in the cache, the implementing class must create one, add it to the cache and return it.- Specified by:
getCompiledReportin interfaceJasperReportCacheService- Parameters:
widget- for which report is cached.
-
remove
Removes widget from cache.- Specified by:
removein interfaceJasperReportCacheService- Parameters:
widget- to be removed from cache- Returns:
- true if widget has been removed, false otherwise
-
getImageForJasperWidgetPreferences
public org.zkoss.image.AImage getImageForJasperWidgetPreferences(JasperWidgetPreferencesModel widget) throws JasperWidgetException Returns cached image for widget. If no image is in the cache, the implementing class must create one, add it to the cache and return it.- Specified by:
getImageForJasperWidgetPreferencesin interfaceJasperReportCacheService- Parameters:
widget- for which image is cached- Throws:
JasperWidgetException- when problem with export report to image occurred
-
update
Updates cached report for specific widget.- Specified by:
updatein interfaceJasperReportCacheService- Parameters:
widget- to be updated
-
invalidateAll
public void invalidateAll()Clears cache- Specified by:
invalidateAllin interfaceJasperReportCacheService
-
setJasperMediaService
- Parameters:
jasperMediaService- the jasperMediaService to set
-
setJasperReportCompileService
- Parameters:
jasperReportCompileService- the jasperReportCompileService to set
-
setJasperReportFillService
- Parameters:
jasperReportFillService- the jasperReportFillService to set
-
setJasperReportExportService
- Parameters:
jasperReportExportService- the jasperReportExportService to set
-