diff options
author | Rüdiger Timm <rt@openoffice.org> | 2008-06-16 12:07:17 +0000 |
---|---|---|
committer | Rüdiger Timm <rt@openoffice.org> | 2008-06-16 12:07:17 +0000 |
commit | 043917166ac8bdd89cbda28341d86ac4fce13908 (patch) | |
tree | 4badc96fb2092c9e3a77271e9933334d0bab9e04 /reportdesign/java | |
parent | 93d502a893b57d90e552fad75b5a6491de63dd10 (diff) |
INTEGRATION: CWS rptchart02 (1.3.4); FILE MERGED
2008/06/09 10:52:10 oj 1.3.4.5: #i89437# check if command is not null
2008/05/22 08:04:53 oj 1.3.4.4: #i86902# impl author and title functions
2008/04/21 09:58:30 oj 1.3.4.3: make usable for 2.4
2008/04/16 06:21:18 oj 1.3.4.2: RESYNC: (1.3-1.4); FILE MERGED
2008/03/12 09:42:44 oj 1.3.4.1: impl chart handling and some code refactoring
Diffstat (limited to 'reportdesign/java')
-rw-r--r-- | reportdesign/java/com/sun/star/report/pentaho/SOReportJobFactory.java | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/reportdesign/java/com/sun/star/report/pentaho/SOReportJobFactory.java b/reportdesign/java/com/sun/star/report/pentaho/SOReportJobFactory.java index 5951e952839b..4a4b1867b0a0 100644 --- a/reportdesign/java/com/sun/star/report/pentaho/SOReportJobFactory.java +++ b/reportdesign/java/com/sun/star/report/pentaho/SOReportJobFactory.java @@ -7,7 +7,7 @@ * OpenOffice.org - a multi-platform office productivity suite * * $RCSfile: SOReportJobFactory.java,v $ - * $Revision: 1.5 $ + * $Revision: 1.6 $ * * This file is part of OpenOffice.org. * @@ -176,8 +176,7 @@ public class SOReportJobFactory catch (java.lang.IncompatibleClassChangeError e2) { Log.error("Detected an IncompatibleClassChangeError"); - e2.printStackTrace(System.err); - System.err.println(e2); + throw new com.sun.star.lang.WrappedTargetException("caught a " + e2.getClass().getName(), this, new com.sun.star.uno.Exception(e2.getLocalizedMessage())); } Thread.currentThread().setContextClassLoader(cl); @@ -190,6 +189,8 @@ public class SOReportJobFactory XStorage output = null; XRowSet rowSet = null; String mimetype = null; + String author = null; + String title = null; for (int i = 0; i < namedValue.length; ++i) { @@ -218,6 +219,14 @@ public class SOReportJobFactory { mimetype = (String) aProps.Value; } + else if (ReportEngineParameterNames.AUTHOR.equalsIgnoreCase(aProps.Name)) + { + author = (String) aProps.Value; + } + else if (ReportEngineParameterNames.TITLE.equalsIgnoreCase(aProps.Name)) + { + title = (String) aProps.Value; + } } if (input == null || output == null) @@ -257,7 +266,6 @@ public class SOReportJobFactory final ReportJobDefinition definition = engine.createJobDefinition(); final JobProperties procParms = definition.getProcessingParameters(); procParms.setProperty(ReportEngineParameterNames.INPUT_REPOSITORY, storageRepository); - procParms.setProperty(ReportEngineParameterNames.OUTPUT_REPOSITORY, storageRepository); procParms.setProperty(ReportEngineParameterNames.INPUT_NAME, inputName); procParms.setProperty(ReportEngineParameterNames.OUTPUT_NAME, outputName); @@ -265,6 +273,10 @@ public class SOReportJobFactory procParms.setProperty(ReportEngineParameterNames.INPUT_DATASOURCE_FACTORY, dataFactory); procParms.setProperty(ReportEngineParameterNames.IMAGE_SERVICE, new SOImageService(m_cmpCtx)); procParms.setProperty(ReportEngineParameterNames.INPUT_REPORTJOB_FACTORY, this); + if ( author != null) + procParms.setProperty(ReportEngineParameterNames.AUTHOR, author); + if ( title != null) + procParms.setProperty(ReportEngineParameterNames.TITLE, title); return engine.createJob(definition); } @@ -335,8 +347,6 @@ public class SOReportJobFactory } catch (java.lang.IncompatibleClassChangeError e2) { - e2.printStackTrace(System.err); - System.err.println(e2); } return xFactory; |