Package org.pentaho.reporting.engine.classic.wizard.model

Examples of org.pentaho.reporting.engine.classic.wizard.model.GroupDefinition


      final List<FieldWrapper> groups = getGroupFields();
      final DataSchema schema = getEditorModel().getDataSchema().getDataSchema();
      for (final int i : selectedIndices)
      {
        final SourceFieldDefinition group = getSelectableFields().get(i);
        final GroupDefinition xulGroup = new DefaultGroupDefinition();
        xulGroup.setField(group.getFieldName());
        FieldWrapper wrapper = new FieldWrapper(xulGroup, schema);
        groups.add(wrapper);
        final DefaultGroupDefinition definition = (DefaultGroupDefinition) wrapper.getFieldDefinition();
        new XulGroupDefinition(definition, schema);
View Full Code Here


        definition.setHorizontalAlignment(ElementAlignment.LEFT);
        updateAlignmentButtons(ElementAlignment.LEFT);
      }
      else if (fieldDefinition instanceof GroupDefinition)
      {
        final GroupDefinition groupDefinition = (GroupDefinition) fieldDefinition;
        groupDefinition.setTotalsHorizontalAlignment(ElementAlignment.LEFT);
        updateAlignmentButtons(ElementAlignment.LEFT);
      }
    }
View Full Code Here

        definition.setHorizontalAlignment(ElementAlignment.CENTER);
        updateAlignmentButtons(ElementAlignment.CENTER);
      }
      else if (fieldDefinition instanceof GroupDefinition)
      {
        final GroupDefinition groupDefinition = (GroupDefinition) fieldDefinition;
        groupDefinition.setTotalsHorizontalAlignment(ElementAlignment.CENTER);
        updateAlignmentButtons(ElementAlignment.CENTER);
      }
    }
View Full Code Here

        definition.setHorizontalAlignment(ElementAlignment.RIGHT);
        updateAlignmentButtons(ElementAlignment.RIGHT);
      }
      else if (fieldDefinition instanceof GroupDefinition)
      {
        final GroupDefinition groupDefinition = (GroupDefinition) fieldDefinition;
        groupDefinition.setTotalsHorizontalAlignment(ElementAlignment.RIGHT);
        updateAlignmentButtons(ElementAlignment.RIGHT);
      }
    }
View Full Code Here

    final int count = Math.min(groupCount, wizardCount);
    for (int i = 0; i < count; i++)
    {
      final int groupIdx = groupCount - i - 1;
      final int wizGroupIdx = wizardCount - i - 1;
      final GroupDefinition gd = groupDefinitions[wizGroupIdx];
      final Group g = definition.getGroup(groupIdx);
      final Band groupHeader = g.getHeader();
      final Band groupFooter = g.getFooter();

      iterateSection(groupHeader, new UpdateHeaderTask(gd));
View Full Code Here

    Group insertGroup = crosstab;
    final GroupDefinition[] groupDefinitions = wizardSpecification.getGroupDefinitions();
    for (int i = 0; i < groupDefinitions.length; i++)
    {
      final GroupDefinition groupDefinition = groupDefinitions[i];
      if (GroupType.CT_OTHER.equals(groupDefinition.getGroupType()) == false)
      {
        continue;
      }

      // create a new group and insert it at the end
      final CrosstabOtherGroup relationalGroup = new CrosstabOtherGroup();
      if (groupDefinition.getGroupName() != null)
      {
        relationalGroup.setName(groupDefinition.getGroupName());
      }
      configureCrosstabOtherGroup(relationalGroup, groupDefinition);
      insertGroup.setBody(new CrosstabOtherGroupBody(relationalGroup));
      insertGroup = relationalGroup;
    }

    for (int i = 0; i < groupDefinitions.length; i++)
    {
      final GroupDefinition groupDefinition = groupDefinitions[i];
      if (GroupType.CT_ROW.equals(groupDefinition.getGroupType()) == false)
      {
        continue;
      }

      // create a new group and insert it at the end
      final CrosstabRowGroup relationalGroup = new CrosstabRowGroup();
      if (groupDefinition.getGroupName() != null)
      {
        relationalGroup.setName(groupDefinition.getGroupName());
      }
      configureCrosstabRowGroup(relationalGroup, groupDefinition);
      insertGroup.setBody(new CrosstabRowGroupBody(relationalGroup));
      insertGroup = relationalGroup;
    }

    for (int i = 0; i < groupDefinitions.length; i++)
    {
      final GroupDefinition groupDefinition = groupDefinitions[i];
      if (GroupType.CT_COLUMN.equals(groupDefinition.getGroupType()) == false)
      {
        continue;
      }

      // create a new group and insert it at the end
      final CrosstabColumnGroup relationalGroup = new CrosstabColumnGroup();
      if (groupDefinition.getGroupName() != null)
      {
        relationalGroup.setName(groupDefinition.getGroupName());
      }
      configureCrosstabColumnGroup(relationalGroup, groupDefinition);
      insertGroup.setBody(new CrosstabColumnGroupBody(relationalGroup));
      insertGroup = relationalGroup;
    }
View Full Code Here

    final RelationalGroup template = findInnermostRelationalGroup(definition);

    final GroupDefinition[] groupDefinitions = wizardSpecification.getGroupDefinitions();
    for (int i = 0; i < groupDefinitions.length; i++)
    {
      final GroupDefinition groupDefinition = groupDefinitions[i];
      final GroupType type = groupDefinition.getGroupType();
      if (type != null && GroupType.RELATIONAL.equals(type) == false)
      {
        continue;
      }

      if (group == null)
      {
        // create a new group and insert it at the end
        RelationalGroup relationalGroup;
        if (template != null)
        {
          try
          {
            relationalGroup = (RelationalGroup) template.derive();
          }
          catch (CloneNotSupportedException e)
          {
            relationalGroup = new RelationalGroup();
          }
        }
        else
        {
          relationalGroup = new RelationalGroup();
        }

        if (groupDefinition.getGroupName() != null)
        {
          relationalGroup.setName(groupDefinition.getGroupName());
        }
        configureRelationalGroup(relationalGroup, groupDefinition);
        insertGroup(relationalGroup);
      }
      else
View Full Code Here

  private boolean isCrosstab()
  {
    final GroupDefinition[] groupDefinitions = wizardSpecification.getGroupDefinitions();
    for (int i = 0; i < groupDefinitions.length; i++)
    {
      final GroupDefinition groupDefinition = groupDefinitions[i];
      final GroupType groupType = groupDefinition.getGroupType();
      if (GroupType.CT_COLUMN.equals(groupType) ||
          GroupType.CT_ROW.equals(groupType))
      {
        return true;
      }
View Full Code Here

      xmlWriter.writeTag(WizardCoreModule.NAMESPACE, "group-definitions", XmlWriter.OPEN);
      final GroupDefinition[] groupDefinitions = specification.getGroupDefinitions();
      final GroupDefinitionWriteHandler groupDefinitionWriteHandler = new GroupDefinitionWriteHandler();
      for (int i = 0; i < groupDefinitions.length; i++)
      {
        final GroupDefinition definition = groupDefinitions[i];
        groupDefinitionWriteHandler.writeReport(bundle, wizardFileState, xmlWriter, definition);
      }
      xmlWriter.writeCloseTag();

      final WatermarkDefinitionWriterHandler watermarkDefinitionWriterHandler = new WatermarkDefinitionWriterHandler();
View Full Code Here

        definition.setHorizontalAlignment(ElementAlignment.LEFT);
        updateAlignmentButtons(ElementAlignment.LEFT);
      }
      else if (fieldDefinition instanceof GroupDefinition)
      {
        final GroupDefinition groupDefinition = (GroupDefinition) fieldDefinition;
        groupDefinition.setTotalsHorizontalAlignment(ElementAlignment.LEFT);
        updateAlignmentButtons(ElementAlignment.LEFT);
      }
    }
View Full Code Here

TOP

Related Classes of org.pentaho.reporting.engine.classic.wizard.model.GroupDefinition

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.