IDEMPIERE-1698 cleaner api through changed package for ReportStarter
This commit is contained in:
parent
78eccc2deb
commit
11519fb5f9
|
@ -53,7 +53,7 @@ import org.compiere.wf.MWorkflow;
|
||||||
*/
|
*/
|
||||||
public final class ProcessUtil {
|
public final class ProcessUtil {
|
||||||
|
|
||||||
public static final String JASPER_STARTER_CLASS = "org.compiere.report.ReportStarter";
|
public static final String JASPER_STARTER_CLASS = "org.adempiere.report.jasper.ReportStarter";
|
||||||
|
|
||||||
/** Logger */
|
/** Logger */
|
||||||
private static CLogger log = CLogger.getCLogger(ProcessUtil.class);
|
private static CLogger log = CLogger.getCLogger(ProcessUtil.class);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package org.compiere.report;
|
package org.adempiere.report.jasper;
|
||||||
import java.awt.Graphics2D;
|
import java.awt.Graphics2D;
|
||||||
import java.awt.geom.Rectangle2D;
|
import java.awt.geom.Rectangle2D;
|
||||||
|
|
|
@ -16,7 +16,6 @@ package org.adempiere.report.jasper;
|
||||||
import org.adempiere.base.IProcessFactory;
|
import org.adempiere.base.IProcessFactory;
|
||||||
import org.adempiere.util.ProcessUtil;
|
import org.adempiere.util.ProcessUtil;
|
||||||
import org.compiere.process.ProcessCall;
|
import org.compiere.process.ProcessCall;
|
||||||
import org.compiere.report.ReportStarter;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ProcessFactory to start the ReportStarter class.
|
* ProcessFactory to start the ReportStarter class.
|
||||||
|
@ -33,10 +32,15 @@ import org.compiere.report.ReportStarter;
|
||||||
*/
|
*/
|
||||||
public class ProcessFactory implements IProcessFactory {
|
public class ProcessFactory implements IProcessFactory {
|
||||||
|
|
||||||
|
public static final String JASPER_STARTER_CLASS_DEPRECATED = "org.compiere.report.ReportStarter";
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ProcessCall newProcessInstance(String className) {
|
public ProcessCall newProcessInstance(String className) {
|
||||||
if (ProcessUtil.JASPER_STARTER_CLASS.equals(className))
|
if (ProcessUtil.JASPER_STARTER_CLASS.equals(className))
|
||||||
return new ReportStarter();
|
return new ReportStarter();
|
||||||
|
// this is for compatibility with older installations
|
||||||
|
if (JASPER_STARTER_CLASS_DEPRECATED.equals(className))
|
||||||
|
return new ReportStarter();
|
||||||
else
|
else
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. *
|
* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. *
|
||||||
* For the text or an alternative of this public license, you may reach us *
|
* For the text or an alternative of this public license, you may reach us *
|
||||||
*****************************************************************************/
|
*****************************************************************************/
|
||||||
package org.compiere.report;
|
package org.adempiere.report.jasper;
|
||||||
|
|
||||||
import java.awt.print.PrinterJob;
|
import java.awt.print.PrinterJob;
|
||||||
import java.io.ByteArrayOutputStream;
|
import java.io.ByteArrayOutputStream;
|
||||||
|
@ -79,7 +79,6 @@ import net.sf.jasperreports.engine.xml.JRXmlWriter;
|
||||||
import org.adempiere.base.Service;
|
import org.adempiere.base.Service;
|
||||||
import org.adempiere.exceptions.AdempiereException;
|
import org.adempiere.exceptions.AdempiereException;
|
||||||
import org.adempiere.exceptions.DBException;
|
import org.adempiere.exceptions.DBException;
|
||||||
import org.adempiere.report.jasper.JRViewerProvider;
|
|
||||||
import org.adempiere.util.IProcessUI;
|
import org.adempiere.util.IProcessUI;
|
||||||
import org.compiere.model.MAttachment;
|
import org.compiere.model.MAttachment;
|
||||||
import org.compiere.model.MAttachmentEntry;
|
import org.compiere.model.MAttachmentEntry;
|
Loading…
Reference in New Issue