Examples of GraphicsOutputProcessor


Examples of org.jfree.layouting.modules.output.graphics.GraphicsOutputProcessor

  private ReportJob job;
  private Throwable error;

  public PrintReportProcessor(final ReportJob job)
  {
    super(new GraphicsOutputProcessor(job.getConfiguration()));
    this.job = job;

    synchronized(job)
    {
      final ReportDataFactory dataFactory = job.getDataFactory();
View Full Code Here

Examples of org.jfree.layouting.modules.output.graphics.GraphicsOutputProcessor

    {
      // set up the scene
      final PageState state = getPhysicalPageState(page);

      final ReportTargetState targetState = state.getTargetState();
      final GraphicsOutputProcessor outputProcessor = getGraphicsProcessor();
      outputProcessor.setPageCursor(state.getPageCursor());
      final QueryPhysicalPageInterceptor interceptor =
          new QueryPhysicalPageInterceptor(outputProcessor.getPhysicalPage(page));
      outputProcessor.setInterceptor(interceptor);

      final LibLayoutReportTarget target =
          (LibLayoutReportTarget) targetState.restore(outputProcessor);

      LayoutController position = state.getLayoutController();

      // we have the data and we have our position inside the report.
      // lets generate something ...
      while (position.isAdvanceable())
      {
        position = position.advance(target);
        target.commit();

        while (position.isAdvanceable() == false &&
               position.getParent() != null)
        {
          final LayoutController parent = position.getParent();
          position = parent.join(position.getFlowController());
        }

        if (interceptor.isMoreContentNeeded() == false)
        {
          outputProcessor.setInterceptor(null);
          return interceptor.getDrawable();
        }

      }

      outputProcessor.setInterceptor(null);
      return interceptor.getDrawable();
    }
  }
View Full Code Here

Examples of org.jfree.layouting.modules.output.graphics.GraphicsOutputProcessor

  public static void main(final String[] args) throws InputFeedException
  {
    final LibLayoutBoot instance = LibLayoutBoot.getInstance();
    instance.start();
    final GraphicsOutputProcessor op = new GraphicsOutputProcessor(instance.getGlobalConfig());
    final DefaultLayoutProcess dlp = new DefaultLayoutProcess(op);
    final InputFeed inputFeed = dlp.getInputFeed();
    inputFeed.startDocument();
      inputFeed.startElement(NAMESPACE, "body");
      inputFeed.addContent(" ");
View Full Code Here

Examples of org.jfree.layouting.modules.output.graphics.GraphicsOutputProcessor



  public void testMixing () throws InputFeedException, StateException
  {
    final GraphicsOutputProcessor gop = new GraphicsOutputProcessor
        (LibLayoutBoot.getInstance().getGlobalConfig());

    // Stage one: Global values ..
    final LayoutProcess dlpPrep1 = new ChainingLayoutProcess(new DefaultLayoutProcess(gop));
    executeFirst(dlpPrep1);
View Full Code Here

Examples of org.jfree.layouting.modules.output.graphics.GraphicsOutputProcessor

  private ReportJob job;
  private Throwable error;

  public PrintReportProcessor(final ReportJob job)
  {
    super(new GraphicsOutputProcessor(job.getConfiguration()));
    this.job = job;

    synchronized(job)
    {
      final ReportDataFactory dataFactory = job.getDataFactory();
View Full Code Here

Examples of org.jfree.layouting.modules.output.graphics.GraphicsOutputProcessor

    {
      // set up the scene
      final PageState state = getPhysicalPageState(page);

      final ReportTargetState targetState = state.getTargetState();
      final GraphicsOutputProcessor outputProcessor = getGraphicsProcessor();
      outputProcessor.setPageCursor(state.getPageCursor());
      final QueryPhysicalPageInterceptor interceptor =
          new QueryPhysicalPageInterceptor(outputProcessor.getPhysicalPage(page));
      outputProcessor.setInterceptor(interceptor);

      final LibLayoutReportTarget target =
          (LibLayoutReportTarget) targetState.restore(outputProcessor);

      LayoutController position = state.getLayoutController();

      // we have the data and we have our position inside the report.
      // lets generate something ...
      while (position.isAdvanceable())
      {
        position = position.advance(target);
        target.commit();

        while (position.isAdvanceable() == false &&
               position.getParent() != null)
        {
          final LayoutController parent = position.getParent();
          position = parent.join(position.getFlowController());
        }

        if (interceptor.isMoreContentNeeded() == false)
        {
          outputProcessor.setInterceptor(null);
          return interceptor.getDrawable();
        }

      }

      outputProcessor.setInterceptor(null);
      return interceptor.getDrawable();
    }
  }
View Full Code Here

Examples of org.jfree.layouting.modules.output.graphics.GraphicsOutputProcessor

  public static void main(String[] args) throws InputFeedException
  {
    final LibLayoutBoot instance = LibLayoutBoot.getInstance();
    instance.start();
    GraphicsOutputProcessor op = new GraphicsOutputProcessor(instance.getGlobalConfig());
    DefaultLayoutProcess dlp = new DefaultLayoutProcess(op);
    InputFeed inputFeed = dlp.getInputFeed();
    inputFeed.startDocument();
      inputFeed.startElement(NAMESPACE, "body");
      inputFeed.addContent(" ");
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.internal.GraphicsOutputProcessor

      final String mimeType = computeMimeType(configuration);
      final float quality = ParserUtil.parseFloat(configuration.getConfigProperty
          ("org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.Quality"), 0.9f);


      final GraphicsOutputProcessor outputProcessor = new GraphicsOutputProcessor
          (new StreamGraphicsOutputProcessorMetaData(configuration), masterReport.getResourceManager());
      final StreamReportProcessor streamReportProcessor = new StreamReportProcessor(masterReport, outputProcessor);
      final ReportProgressListener[] progressListeners = getReportProgressListeners();
      for (int i = 0; i < progressListeners.length; i++)
      {
        final ReportProgressListener listener = progressListeners[i];
        streamReportProcessor.addReportProgressListener(listener);
      }

      final ImageGeneratorInterceptor interceptor = new ImageGeneratorInterceptor();
      outputProcessor.setInterceptor(interceptor);
      streamReportProcessor.processReport();
      streamReportProcessor.close();

      final ContentLocation contentLocation = getBodyContentLocation();
      final NameGenerator nameGenerator = getBodyNameGenerator();
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.internal.GraphicsOutputProcessor

  private Throwable error;

  public PrintReportProcessor(final MasterReport report)
      throws ReportProcessingException
  {
    super(report, new GraphicsOutputProcessor(report.getConfiguration(), report.getResourceManager()));
    setFullStreamingProcessor(false);
  }
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.internal.GraphicsOutputProcessor

   * @throws ReportProcessingException if a report processing error occured.
   */
  protected PageDrawable processPage(final int page)
      throws ReportProcessingException
  {
    final GraphicsOutputProcessor outputProcessor = getGraphicsProcessor();
    try
    {
      // set up the scene. We can assume that the report has been paginated by now ..
      PageState state = getPhysicalPageState(page);
      final QueryPhysicalPageInterceptor interceptor =
          new QueryPhysicalPageInterceptor(outputProcessor.getPhysicalPage(page));
      outputProcessor.setInterceptor(interceptor);
      while (interceptor.isMoreContentNeeded())
      {
        state = processPage(state, true);
      }
      return interceptor.getDrawable();
    }
    finally
    {
      outputProcessor.setInterceptor(null);
    }
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.