コード例 #1
0
 public InstanceID createSubflowPlaceholder(final ReportElement element) {
   final StyleSheet resolverStyleSheet = element.getComputedStyle();
   final RenderBox subReportBox =
       renderNodeFactory.produceSubReportPlaceholder(element, resolverStyleSheet, stateKey);
   this.context.addChild(subReportBox);
   this.context.setEmpty(false);
   return subReportBox.getInstanceId();
 }
コード例 #2
0
  public InlineSubreportMarker processSubReport(final SubReport element) {
    if (isLimitedSubReports()) {
      logger.debug("Not adding subreport: Subreports in header or footer area are not allowed.");
      return null;
    }

    final RenderBox parentBox = this.context.getRenderBox();
    if (parentBox.isAcceptInlineBoxes()) {
      logger.warn("Not adding subreport: Subreports in inline-contexts are not supported.");
      return null;
    }

    final StyleSheet resolverStyleSheet = element.getComputedStyle();
    final RenderBox subReportBox =
        renderNodeFactory.produceSubReportPlaceholder(element, resolverStyleSheet, stateKey);
    this.context.addChild(subReportBox);
    this.context.setEmpty(false);
    final InstanceID subReportBoxId = subReportBox.getInstanceId();
    // the box will be closed
    return new InlineSubreportMarker(element, subReportBoxId, SubReportProcessType.INLINE);
  }