Hitachi Vantara Pentaho Community Wiki
Child pages
  • 3. ReportElement Model
Skip to end of metadata
Go to start of metadata

The ReportElement class and subclasses are used to model the report in the ReportDesigner. Every graphical element (Labels, Fields) and non-graphical element (Functions, Datasets) building the report structure are subclasses of

Inheritance Hierarchy

The report elements form a tree structure, and every report element inherits the capability to contain an unlimited number of child elements.
Some elements like explicitely check to contain only a certain kind of child elements. This limitation can be relaxed if required. The base class ReportElement does not impose such restrictions by default and it would be possible to add functions directly as a child element of a label.

Most subclasses are not shown in the diagram above.

  • ReportElements are Cloneable to support copy/paste. Every subclass must ensure to create deep copies of mutable fields.
  • ReportElements implement the XMLExternalizable interface to load and store the state to the <name>.report file.
  • The abstract base class ReportElement contains the required methods and data structures to visually show an element in the design area of the ReportDesigner. Elements like functions, datasets don't make use of this capability, but the elements could theoretically be placed visually on the report or a subreport element could contain a dataset

The structure tree in the ReportDesigner reflects the element structure one by one. No additional tree model holding a copy of the structure is required.

Sample report structure and the simple class name of the underlying report element.

  • No labels