org.hackystat.projectbrowser.page.dailyprojectdata.build
Class BuildDataModel

java.lang.Object
  extended by org.hackystat.projectbrowser.page.dailyprojectdata.build.BuildDataModel
All Implemented Interfaces:
java.io.Serializable

public class BuildDataModel
extends java.lang.Object
implements java.io.Serializable

The data model for Build DPD display. This data model accommodates multiple Projects. For each project, the data model indicates the number of classes whose method-level percentage falls into each of five buckets, from 0-20% to 80-100%.

Author:
Philip Johnson, Shaoxuan Zhang
See Also:
Serialized Form

Constructor Summary
BuildDataModel()
          The default BuildDataModel, which contains no build information.
 
Method Summary
 void clear()
          Sets this model to its empty state.
 BuildData getBuildData(org.hackystat.sensorbase.resource.projects.jaxb.Project project)
          Return the BuildData instance associated with the specified project.
 java.util.List<BuildData> getBuildDataList()
          Returns the list of BuildData instances, needed for markup.
 boolean isEmpty()
          Returns true if this data model contains no information.
 void update()
          Updates this data model to reflect the build information associated with the selected projects.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BuildDataModel

public BuildDataModel()
The default BuildDataModel, which contains no build information.

Method Detail

update

public void update()
Updates this data model to reflect the build information associated with the selected projects.


clear

public void clear()
Sets this model to its empty state.


isEmpty

public boolean isEmpty()
Returns true if this data model contains no information. Used to figure out if the associated panel should be visible.

Returns:
True if the data model is empty.

getBuildData

public BuildData getBuildData(org.hackystat.sensorbase.resource.projects.jaxb.Project project)
Return the BuildData instance associated with the specified project. Creates and returns a new BuildData instance if one is not yet present.

Parameters:
project - The project.
Returns:
The BuildData instance for this project.

getBuildDataList

public java.util.List<BuildData> getBuildDataList()
Returns the list of BuildData instances, needed for markup.

Returns:
The list of BuildData instances.