iReport Ultimate Guide - Nimsoft Library

iReport Ultimate Guide - Nimsoft Library iReport Ultimate Guide - Nimsoft Library

13.07.2015 Views

iReport Ultimate GuideFigure 13-45 shows the Category Sets tab and the Category Set window.Figure 13-45 Specifying category sets in a Gantt chartSince the definition of each category can be a tedious operation, it’s possible to generate the categories using an expressionthat calls a scriptlet method or a custom class to generate your list of categories. Select the Use a bulk expression for thecategories check box on the Categories tab of the Category Set window, and specify your expression. The result of theexpression must be a java.util.Collection or an array of com.jaspersoft.fusion.jasperreports.widgets.Gantt.Category objects.13.4.3.6 Processes and TasksAfter defining the categories, you must define the processes on the Processes tab of the Gantt Properties window. A processis defined by an ID, a name for the label, and a set of optional properties that control its appearance in the chart.The next step is to define the tasks that make up each process. A task is always associated with a single process ID, but anynumber of tasks can be associated with the same process.Tasks are listed on the Tasks tab of the Gantt Properties window. The Task window for defining the tasks is shown in.Figure 13-46.272

Flash ChartsFigure 13-46 Specifying tasks in a Gantt chartA task is defined by its ID, the ID of the process to which it belongs, a label, and a date range. Optionally, you can enter anexpression to display the percent of completion of the task and another expression to show the task as part of a group.Figure 13-47 show how a task group is displayed.Figure 13-47 Output of a task group on a Gantt chartFor each task, you can also define a milestone and a process. Milestones can be defined from the task window or on theMilestone tab of the main Gantt Properties window. Milestones are further explained in section 13.4.3.7.The process definition on a task is generally not required because the task is already associated with a process through theProcess ID Expression. However, sometimes a task contains the information to define the process it should belong to.For example, in a simple Gantt chart it might be possible to define only tasks that are self-contained within their ownprocesses, which might be quicker than defining the processes separately. In this case, you can use the Task window instead ofthe Processes tab of the Gantt Properties window.If a process is defined directly from a task, the Process ID Expression is ignored.13.4.3.7 MilestonesUp to now we have seen the mandatory components of the Gantt chart. But many other components can be defined.A milestone is a symbol that appears in the tasks portion of the Gantt chart, in the same row as the task to which the milestonebelongs. A milestone is always tied to a task and can be created in the Milestones tab in the Gantt Properties window ordirectly in the task properties. It is defined by a task ID and a date that identifies the position of the milestone in the time line.The properties of a milestone include the shape of the milestone in the chart, its color, its border, and so on.273

Flash ChartsFigure 13-46 Specifying tasks in a Gantt chartA task is defined by its ID, the ID of the process to which it belongs, a label, and a date range. Optionally, you can enter anexpression to display the percent of completion of the task and another expression to show the task as part of a group.Figure 13-47 show how a task group is displayed.Figure 13-47 Output of a task group on a Gantt chartFor each task, you can also define a milestone and a process. Milestones can be defined from the task window or on theMilestone tab of the main Gantt Properties window. Milestones are further explained in section 13.4.3.7.The process definition on a task is generally not required because the task is already associated with a process through theProcess ID Expression. However, sometimes a task contains the information to define the process it should belong to.For example, in a simple Gantt chart it might be possible to define only tasks that are self-contained within their ownprocesses, which might be quicker than defining the processes separately. In this case, you can use the Task window instead ofthe Processes tab of the Gantt Properties window.If a process is defined directly from a task, the Process ID Expression is ignored.13.4.3.7 MilestonesUp to now we have seen the mandatory components of the Gantt chart. But many other components can be defined.A milestone is a symbol that appears in the tasks portion of the Gantt chart, in the same row as the task to which the milestonebelongs. A milestone is always tied to a task and can be created in the Milestones tab in the Gantt Properties window ordirectly in the task properties. It is defined by a task ID and a date that identifies the position of the milestone in the time line.The properties of a milestone include the shape of the milestone in the chart, its color, its border, and so on.273

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!