|
Re: IReportContext [message #721164 is a reply to message #721064] |
Thu, 01 September 2011 04:38 |
|
Marc,
Are you using 3.7? If you are using the POJO runtime you can do
something like:
RunAndRenderTask task = (RunAndRenderTask)
engine.createRunAndRenderTask(design);
..
..
task.setRenderOption(options);
task.run();
IReportContext irc = task.getReportContext();
task.close
If you are using previous version the only easy way I can see to do this
is to modify the engineapi.jar to have the RunAndRenderTask or implement
a JavaEventHandler for the report and when it is called it will pass the
report context to the event handler.
Jason
On 8/31/2011 3:56 PM, marc.marshall wrote:
> Hi,
>
> I am unit testing a Birt Report using JUnit. The method that I am
> testing requires a IReportContext object. Is there an easy way of
> creating this object? I know that I can't instantiate the object but is
> there any method of another object that allows me to create a
> IReportContext with an existing *.rptdesign? Thanks in advance for any
> help that you can offer.
>
> Thanks,
>
> Marc
|
|
|
|
Re: IReportContext [message #721727 is a reply to message #721698] |
Fri, 02 September 2011 16:30 |
|
Marc,
It does have it but it is not exported to the engine-api jar file.
Jason
On 9/2/2011 11:46 AM, marc.marshall wrote:
> Jason,
>
> Thanks for the reply. I am using Birt 2.6. I guess Birt 2.6
> RunAndRenderTask object does not have the getReportContext(). Is this
> true? I think maybe I should move up to the 3.7 version.
>
> Thanks,
>
> Marc
|
|
|
Powered by
FUDForum. Page generated in 0.02763 seconds