Package net.sf.jasperreports.engine

Examples of net.sf.jasperreports.engine.JRChild


    // clone the contents of the page footer in the frame
    List footerElements = pageFooter.getChildren();
    for (Iterator iterator = footerElements.iterator(); iterator
        .hasNext();)
    {
      JRChild child = (JRChild) iterator.next();
      JRChild childClone = (JRChild) child.clone(footerFrame);
      if (childClone instanceof JRElement)
      {
        footerFrame.addElement((JRElement) childClone);
      }
      else if (childClone instanceof JRElementGroup)
      {
        footerFrame.addElementGroup((JRElementGroup) childClone);
      }
      else
      {
        throw new JRRuntimeException("Uknown child type "
            + childClone.getClass().getName());
      }
    }
   
    groupFooter.addElement(footerFrame);
    ((JRDesignSection) summaryGroup.getGroupFooterSection()).addBand(groupFooter);
View Full Code Here


    frame.setStyleNameReference(cell.getStyleNameReference());
    frame.copyBox(cell.getLineBox());
   
    for (Iterator it = cell.getChildren().iterator(); it.hasNext();)
    {
      JRChild child = (JRChild) it.next();
      if (child instanceof JRElement)
      {
        JRElement element = (JRElement) child;
        // clone the element in order to set the frame as group
        element = (JRElement) element.clone(frame);
        if (width != originalWidth)
        {
          scaleCellElement(element, originalWidth, width);
         
          if (element instanceof JRElementGroup)//i.e. frame
          {
            JRElementGroup elementGroup = (JRElementGroup) element;
            for (JRElement subelement : elementGroup.getElements())
            {
              scaleCellElement(subelement, originalWidth, width);
            }
          }
        }
        frame.addElement(element);
      }
      else if (child instanceof JRElementGroup)
      {
        JRElementGroup elementGroup = (JRElementGroup) child;
        // clone the elements in order to set the frame as group
        elementGroup = (JRElementGroup) elementGroup.clone(frame);
        frame.addElementGroup(elementGroup);
       
        if (width != originalWidth)
        {
          for (JRElement element : elementGroup.getElements())
          {
            scaleCellElement(element, originalWidth, width);
          }
        }
      }
      else
      {
        throw new JRRuntimeException("Unknown JRChild type " + child.getClass().getName());
      }
    }
   
    return frame;
  }
View Full Code Here

        ConvertVisitor contentsVisitor = new ConvertVisitor(reportConverter,
            contentsFrame);
        for (Iterator it = children.iterator(); it
            .hasNext();)
        {
          JRChild child = (JRChild) it.next();
          child.visit(contentsVisitor);
        }
      }
     
      frame.addElement(contentsFrame);
View Full Code Here

  {
    if (elements != null)
    {
      for (Iterator it = elements.iterator(); it.hasNext();)
      {
        JRChild child = (JRChild) it.next();
        child.visit(this);
      }
    }
  }
View Full Code Here

      List list = elementGrp.getChildren();
      if (list != null && list.size() > 0)
      {
        for(int i = 0; i < list.size(); i++)
        {
          JRChild child = (JRChild)list.get(i);
          child = (JRChild)factory.getVisitResult(child);
          children.add(child);
        }
      }
 
View Full Code Here

    if (frameChildren != null)
    {
      children = new ArrayList(frameChildren.size());
      for (Iterator it = frameChildren.iterator(); it.hasNext();)
      {
        JRChild child = (JRChild) it.next();
        children.add(factory.getVisitResult(child));
      }
    }
   
    lineBox = frame.getLineBox().clone(this);
View Full Code Here

    List list = elementGrp.getChildren();
    if (list != null && list.size() > 0)
    {
      for(int i = 0; i < list.size(); i++)
      {
        JRChild child = (JRChild)list.get(i);
        child = (JRChild)factory.getVisitResult(child);
        children.add(child);
      }
    }
View Full Code Here

TOP

Related Classes of net.sf.jasperreports.engine.JRChild

Copyright © 2018 www.massapicom. 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.