Class CrosstabGroup

  • All Implemented Interfaces:
    Serializable, Cloneable, Iterable<Element>, DataTarget, ReportElement

    public class CrosstabGroup
    extends Group
    A crosstab group represents the page, row, column and detail sections of a cube. The other axises are handled as regular relational groups.

    The group's header and footer can be used to print page-axis header and footer sections for the crosstab, but they will not be used as bands for the tab-header and -footers. The crosstabs column and row headers are autogenerated and part of the group-body.

    Author:
    Thomas Morgner
    See Also:
    Serialized Form
    • Method Detail

      • getHeader

        public GroupHeader getHeader()
        Returns the group header.

        The group header is a report band that contains elements that should be printed at the start of a group.

        Returns:
        the group header.
      • setHeader

        public void setHeader​(GroupHeader header)
        Sets the header for the group.
        Parameters:
        header - the header (null not permitted).
        Throws:
        NullPointerException - if the given header is null
      • getFooter

        public GroupFooter getFooter()
        Returns the group footer.
        Returns:
        the footer.
      • setFooter

        public void setFooter​(GroupFooter footer)
        Sets the footer for the group.
        Parameters:
        footer - the footer (null not permitted).
        Throws:
        NullPointerException - if the given footer is null.
      • getNoDataBand

        public NoDataBand getNoDataBand()
      • setNoDataBand

        public void setNoDataBand​(NoDataBand noDataBand)
      • derive

        public CrosstabGroup derive​(boolean preserveElementInstanceIds)
        Description copied from class: Element
        Creates a deep copy of this element and regenerates all instance-ids.
        Overrides:
        derive in class Group
        Parameters:
        preserveElementInstanceIds - defines whether this call generates new instance-ids for the derived elements. Instance-IDs are used by the report processor to recognize reoccurring elements and must not changed within the report run. Outside of the report processors new instance ids should be generated at all times to separate instances and to make them uniquely identifiable.
        Returns:
        the copy of the element.
      • removeElement

        protected void removeElement​(Element element)
        Description copied from class: Section
        Removes an element from the section.
        Overrides:
        removeElement in class Group
        Parameters:
        element - the element to be section.
      • getElementCount

        public int getElementCount()
        Description copied from class: Section
        Returns the number of elements in this section.
        Specified by:
        getElementCount in class Section
        Returns:
        the number of elements of this section.
      • getElement

        public Element getElement​(int index)
        Description copied from class: Section
        Returns the element stored add the given index.
        Specified by:
        getElement in class Section
        Parameters:
        index - the element position within this section
        Returns:
        the element
      • getPrintDetailsHeader

        public Boolean getPrintDetailsHeader()
      • setPrintDetailsHeader

        public void setPrintDetailsHeader​(Boolean printDetailsHeader)
      • getPrintColumnTitleHeader

        public Boolean getPrintColumnTitleHeader()
      • setPrintColumnTitleHeader

        public void setPrintColumnTitleHeader​(Boolean printColumnTitleHeader)
      • setPaddingFields

        public void setPaddingFields​(List<String> c)
        Sets the fields for this group. The given list must contain Strings defining the needed fields from the DataRow. Don't reference Function-Fields here, functions are not supported in th groupfield definition.
        Parameters:
        c - the list containing strings.
        Throws:
        NullPointerException - if the given list is null or the list contains null-values.
      • clearPaddingFields

        public void clearPaddingFields()
      • addPaddingField

        public void addPaddingField​(String name)
        Adds a field to the group. The field names must correspond to the column names in the report's TableModel.
        Parameters:
        name - the field name (null not permitted).
        Throws:
        NullPointerException - if the name is null
      • getPaddingFields

        public List<String> getPaddingFields()
        Returns the list of fields for this group.
        Returns:
        a list (unmodifiable) of fields for the group.
      • setPaddingFieldsArray

        public void setPaddingFieldsArray​(String[] fields)
      • getPaddingFieldsArray

        public String[] getPaddingFieldsArray()
        Returns the group fields as array.
        Returns:
        the fields as string array.