use of org.pentaho.jfreereport.castormodel.reportspec.ReportSpec in project pentaho-platform by pentaho.
the class JFreeReportGenerateDefinitionComponent method getReportSpec.
public ReportSpec getReportSpec() throws FileNotFoundException {
ReportSpec reportSpec = null;
if (isDefinedResource(AbstractJFreeReportComponent.REPORTGENERATEDEFN_REPORTSPECINPUT)) {
IActionSequenceResource resource = getResource(AbstractJFreeReportComponent.REPORTGENERATEDEFN_REPORTSPECINPUT);
reportSpec = loadFromZip(resource);
if (reportSpec == null) {
InputStream reportSpecInputStream = resource.getInputStream(RepositoryFilePermission.READ, LocaleHelper.getLocale());
reportSpec = (ReportSpec) CastorUtility.getInstance().readCastorObject(reportSpecInputStream, ReportSpec.class);
}
}
return reportSpec;
}
Aggregations