Examples of ReportDefinition


Examples of org.pentaho.reporting.engine.classic.core.ReportDefinition


    if (event.getState().isSubReportEvent() == false)
    {
      // only evaluate master-reports. Subreports are evaluated when their parent-band is evaluated.
      final ReportDefinition definition = event.getReport();
      evaluateElement(definition);
    }
  }
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.ReportDefinition

    super.reportInitialized(event);

    if (event.getState().isSubReportEvent() == false)
    {
      // only evaluate master-reports. Subreports are evaluated when their parent-band is evaluated.
      final ReportDefinition definition = event.getReport();
      evaluateElement(definition);
    }
  }
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.ReportDefinition

    {
      // dont do anything if there is no printing done ...
      return;
    }

    ReportDefinition reportDefinition = locateMasterReport(event.getState());
    resolver = createStyleResolver(reportDefinition, getRuntime().getProcessingContext());
    styleSheet = new ResolverStyleSheet();
    super.reportInitialized(event);
  }
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.ReportDefinition

  public void reportInitialized(final ReportEvent event)
  {
    final boolean isTable = exportDescriptor != null &&
        getRuntime().getExportDescriptor().startsWith(exportDescriptor);

    final ReportDefinition report = event.getReport();
    if (isHidePageBands())
    {
      report.getPageHeader().setVisible(isTable == false);
      report.getPageFooter().setVisible(isTable == false);
    }
    if (isDisableRepeatingHeader())
    {
      final int gc = report.getGroupCount();
      for (int i = 0; i < gc; i++)
      {
        final Group g = report.getGroup(i);
        if (g instanceof RelationalGroup)
        {
          final RelationalGroup rg = (RelationalGroup) g;
          if (rg.getHeader().isRepeat())
          {
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.ReportDefinition

    this.groupList = new GroupList();
  }

  protected void startParsing(final PropertyAttributes attrs) throws SAXException
  {
    final ReportDefinition report = (ReportDefinition)
        getRootHandler().getHelperObject(ReportParserUtil.HELPER_OBJ_REPORT_NAME);

    final int groupCount = report.getGroupCount();
    for (int i = 0; i < groupCount; i++)
    {
      final Group g = report.getGroup(i);
      if (g instanceof RelationalGroup)
      {
        groupList.add((RelationalGroup) g);
      }
      else
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.ReportDefinition

    if (isSameNamespace(uri) == false)
    {
      return null;
    }

    final ReportDefinition report = (ReportDefinition)
        getRootHandler().getHelperObject(ReportParserUtil.HELPER_OBJ_REPORT_NAME);

    if ("report-header".equals(tagName))
    {
      return new RootBandReadHandler(report.getReportHeader());
    }
    else if ("report-footer".equals(tagName))
    {
      return new RootBandReadHandler(report.getReportFooter());
    }
    else if ("page-header".equals(tagName))
    {
      return new BandReadHandler(report.getPageHeader());
    }
    else if ("page-footer".equals(tagName))
    {
      return new BandReadHandler(report.getPageFooter());
    }
    else if ("watermark".equals(tagName))
    {
      return new BandReadHandler(report.getWatermark());
    }
    else if ("no-data-band".equals(tagName))
    {
      final NoDataBand noDataBand = (NoDataBand) report.getChildElementByType(NoDataBandType.INSTANCE);
      if (noDataBand == null)
      {
        throw new ParseException("Not a relational report");
      }
      return new RootBandReadHandler(noDataBand);
    }
    else if ("groups".equals(tagName))
    {
      return new GroupsReadHandler(groupList);
    }
    else if ("itemband".equals(tagName))
    {
      final ItemBand itemBand = (ItemBand) report.getChildElementByType(ItemBandType.INSTANCE);
      if (itemBand == null)
      {
        throw new ParseException("Not a relational report");
      }
      return new RootBandReadHandler(itemBand);
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.ReportDefinition

    rootAttributes.addNamespaceDeclaration("table", AttributeNames.Table.NAMESPACE);
    rootAttributes.addNamespaceDeclaration("page", ExtParserModule.NAMESPACE);

    writer.writeTag(BundleNamespaces.STYLE, "style", rootAttributes, XmlWriterSupport.OPEN);

    final ReportDefinition report = styleFileState.getReport();
    if (report instanceof MasterReport)
    {
      // only the master report can carry page-definitions ..
      final PageDefinition definition = report.getPageDefinition();
      writePageDefinition(writer, definition);

      final MasterReport master = (MasterReport) report;
      final ElementStyleDefinition styleDefinition = master.getStyleDefinition();
      if (styleDefinition != null)
      {
        writer.writeTag(BundleNamespaces.STYLE, "style-definition", XmlWriter.OPEN);
        writeStyleDefinition(writer, styleDefinition);
        writer.writeCloseTag();
      }
    }

    // write layout processor section
    if (ExpressionWriterUtility.isGlobalLayoutExpressionActive(styleFileState))
    {
      writer.writeTag(BundleNamespaces.LAYOUT, "layout-processors", XmlWriterSupport.OPEN);
      ExpressionWriterUtility.writeGlobalLayoutExpressions(bundle, styleFileState, writer);
      writer.writeCloseTag();
    }

    // write watermark
    final Watermark watermark = report.getWatermark();
    final BundleElementWriteHandler watermarkHandler = BundleElementRegistry.getInstance().getWriteHandler(watermark);
    watermarkHandler.writeElement(bundle, styleFileState, writer, watermark);

    // write page-header
    final PageHeader pageHeader = report.getPageHeader();
    final BundleElementWriteHandler pageHeaderHandler = BundleElementRegistry.getInstance().getWriteHandler(pageHeader);
    pageHeaderHandler.writeElement(bundle, styleFileState, writer, pageHeader);

    // write page-footer
    final PageFooter pageFooter = report.getPageFooter();
    final BundleElementWriteHandler pageFooterHandler = BundleElementRegistry.getInstance().getWriteHandler(pageFooter);
    pageFooterHandler.writeElement(bundle, styleFileState, writer, pageFooter);


    writer.writeCloseTag();
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.ReportDefinition

    final BitSet bits = computingSignature;
    bits.clear();

    int count = 0;

    final ReportDefinition report = event.getReport();
    final ReportState state = event.getState();
    final int groupsPrinted = state.getPresentationGroupIndex();
    final int levelCount = levels.length;

    for (int i = 0; i < levelCount; i++)
    {
      final LayouterLevel level = levels[i];
      final ReportDefinition def = level.getReportDefinition();

      for (int gidx = level.getGroupIndex(); gidx >= 0; gidx -= 1)
      {
        final Group g = def.getGroup(gidx);
        if (g instanceof RelationalGroup)
        {
          final RelationalGroup rg = (RelationalGroup) g;
          final GroupFooter footer = rg.getFooter();
          bits.set(count, DefaultOutputFunction.isGroupSectionPrintable(footer, true, true));
          count += 1;
        }
      }

      if (level.isInItemGroup())
      {
        final DetailsFooter detailsFooter = def.getDetailsFooter();
        if (detailsFooter != null)
        {
          bits.set(count, DefaultOutputFunction.isGroupSectionPrintable(detailsFooter, true, true));
          count += 1;
        }
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.ReportDefinition

    // activating this state after the page has ended is invalid.
    setCurrentEvent(event);
    try
    {
      // activating this state after the page has ended is invalid.
      final ReportDefinition report = event.getReport();
      if (event.getState().isSubReportEvent() == false)
      {
        renderer.startReport(report, getRuntime().getProcessingContext(), event.getState().getPerformanceMonitorContext());

        final ReportState reportState = event.getState();
View Full Code Here

Examples of org.pentaho.reporting.engine.classic.core.ReportDefinition

    try
    {
      // activating this state after the page has ended is invalid.
      updateFooterArea(event);

      final ReportDefinition report = event.getReport();

      renderer.startSection(Renderer.SectionType.NORMALFLOW);
      print(getRuntime(), report.getReportHeader());
      addSubReportMarkers(renderer.endSection());

      printDesigntimeHeader(event);

    }
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.