Package org.pentaho.reporting.engine.classic.core

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


    return definition;
  }

  private void clearCrosstab()
  {
    final CrosstabGroup crosstabGroup = lookupCrosstab();
    if (crosstabGroup != null)
    {
      if (definition.getRootGroup() == crosstabGroup)
      {
        definition.setRootGroup(new RelationalGroup());
      }
      else
      {
        final Section parentSection = crosstabGroup.getParentSection();
        if (parentSection instanceof SubGroupBody)
        {
          final SubGroupBody sgb = (SubGroupBody) parentSection;
          sgb.setGroup(new RelationalGroup());
        }
View Full Code Here


   *
   * @throws ReportProcessingException if an error occurs.
   */
  private void setupCrosstab() throws ReportProcessingException
  {
    CrosstabGroup crosstab = lookupCrosstab();
    if (crosstab == null)
    {
      crosstab = new CrosstabGroup();
      insertCrosstab(crosstab);
    }

    Group insertGroup = crosstab;
    final GroupDefinition[] groupDefinitions = wizardSpecification.getGroupDefinitions();
View Full Code Here

    GroupBody body = createColumnGroups(cellBody);
    body = createRowGroups(cellBody, body);
    body = createOtherGroups(body);

    return new CrosstabGroup(body);
  }
View Full Code Here

    if (event.getLevel() == getDependencyLevel())
    {
      final Group group = event.getReport().getGroup(state.getCurrentGroupIndex());
      if (group instanceof CrosstabGroup)
      {
        final CrosstabGroup crosstabGroup = (CrosstabGroup) group;
        // yeay! we encountered a crosstab.
        if (processingStack == null)
        {
          processingStack = new FastStack<CrosstabSpecification>();
        }
View Full Code Here

    assertEquals("Default-Group detector", 0, defaultGroup.getFieldsArray().length);
    final SubGroupBody body = (SubGroupBody) defaultGroup.getBody();
    final RelationalGroup group1 = (RelationalGroup) body.getGroup();
    assertEquals("Rel-Group", "group-field1", group1.getFieldsArray()[0]);
    final SubGroupBody body1 = (SubGroupBody) group1.getBody();
    final CrosstabGroup ctGroup = (CrosstabGroup) body1.getGroup();
    final CrosstabRowGroupBody body2 = (CrosstabRowGroupBody) ctGroup.getBody();
    final CrosstabRowGroup rowGroup = body2.getGroup();
    assertEquals("Row-Group", "group-field2", rowGroup.getField());

    final CrosstabColumnGroupBody body3 = (CrosstabColumnGroupBody) rowGroup.getBody();
    final CrosstabColumnGroup colGroup = body3.getGroup();
View Full Code Here

        activeContext.getUndo().addChange(ActionMessages.getString("InsertCrosstabOtherGroupAction.UndoName"),
            new InsertGroupBodyOnGroupUndoEntry(selectedGroup.getObjectID(), oldGroupBody, newGroupBody));
      }
      if (selectedElement instanceof CrosstabGroup)
      {
        final CrosstabGroup selectedGroup = (CrosstabGroup) selectedElement;
        final GroupBody oldGroupBody = selectedGroup.getBody();
        final CrosstabOtherGroupBody newGroupBody = new CrosstabOtherGroupBody(newGroup);
        selectedGroup.setBody(newGroupBody);
        newGroup.setBody(oldGroupBody);

        activeContext.getUndo().addChange(ActionMessages.getString("InsertCrosstabOtherGroupAction.UndoName"),
            new InsertGroupBodyOnGroupUndoEntry(selectedGroup.getObjectID(), oldGroupBody, newGroupBody));
      }
    }
    catch (Exception ex)
    {
      UncaughtExceptionsModel.getInstance().addException(ex);
View Full Code Here

    if (activeContext == null)
    {
      return;
    }

    final CrosstabGroup newGroup = new CrosstabGroup();
    try
    {
      final AbstractReportDefinition report = activeContext.getReportDefinition();
      Object selectedElement = report;
      if (getSelectionModel().getSelectionCount() > 0)
View Full Code Here

TOP

Related Classes of org.pentaho.reporting.engine.classic.core.CrosstabGroup

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.