com.versionone.om
Class PrimaryWorkitem

java.lang.Object
  extended by com.versionone.om.Entity
      extended by com.versionone.om.BaseAsset
          extended by com.versionone.om.ProjectAsset
              extended by com.versionone.om.Workitem
                  extended by com.versionone.om.PrimaryWorkitem
Direct Known Subclasses:
Defect, Story, TestSet

public abstract class PrimaryWorkitem
extends Workitem

Base class for Stories and Defects.


Field Summary
 
Fields inherited from class com.versionone.om.BaseAsset
STATE_ACTIVE, STATE_CLOSED
 
Fields inherited from class com.versionone.om.Entity
ASSET_STATE_VALUE, ASSET_VALUE, CHANGE_DATE_UTC, CONTENT_TYPE_VALUE, CONTENT_VALUE, CREATE_DATE_UTC, DELETE_OPERATION, DESCRIPTION_VALUE, FILENAME_VALUE, NAME_VALUE
 
Method Summary
 Task createTask(java.lang.String name)
          Create a task that belongs to this item.
 Task createTask(java.lang.String name, java.util.Map<java.lang.String,java.lang.Object> attribute)
          Create a task that belongs to this item.
 Test createTest(java.lang.String name)
          Create a test that belongs to this item.
 Test createTest(java.lang.String name, java.util.Map<java.lang.String,java.lang.Object> attribute)
          Create a test that belongs to this item.
 java.util.Collection<Defect> getAffectedByDefects()
           
 java.util.Collection<Issue> getBlockingIssues()
           
 java.util.Collection<BuildRun> getCompletedIn()
           
 java.lang.Double getEstimate()
           
 java.util.Collection<Goal> getGoals()
           
 java.util.Collection<Issue> getIssues()
           
 Iteration getIteration()
           
 IListValueProperty getPriority()
           
 Rank<PrimaryWorkitem> getRankOrder()
           
 java.util.Collection<Request> getRequests()
           
 java.util.Collection<SecondaryWorkitem> getSecondaryWorkitems(SecondaryWorkitemFilter filter)
          Collection of Tasks and Tests that belong to this primary workitem.
 IListValueProperty getSource()
           
 IListValueProperty getStatus()
           
 Team getTeam()
           
 Theme getTheme()
           
 java.lang.Double getTotalDetailEstimate(WorkitemFilter filter)
          Gets the estimate of total effort required to implement this item.
 java.lang.Double getTotalDone(WorkitemFilter filter)
          Gets the total effort already expended to implement this item.
 java.lang.Double getTotalToDo(WorkitemFilter filter)
          Gets the total remaining effort required to complete implementation of this item.
 void setEstimate(java.lang.Double estimate)
           
 void setIteration(Iteration iteration)
           
 void setTeam(Team team)
           
 void setTheme(Theme theme)
           
 
Methods inherited from class com.versionone.om.Workitem
canTrack, createEffort, createEffort, createEffort, createEffort, createEffort, getDetailEstimate, getDone, getEffortRecords, getOwners, getReference, getToDo, setDetailEstimate, setReference, setToDo
 
Methods inherited from class com.versionone.om.ProjectAsset
getDisplayID, getProject, setProject
 
Methods inherited from class com.versionone.om.BaseAsset
canClose, canDelete, canReactivate, close, createAttachment, createAttachment, createConversation, createConversation, createLink, createLink, createNote, createNote, delete, getAttachments, getCustomDropdown, getCustomField, getDescription, getLinks, getName, getNotes, getReferencedInExpressions, getURL, isActive, isClosed, reactivate, setDescription, setName
 
Methods inherited from class com.versionone.om.Entity
equals, get, getChangeComment, getChangeDate, getChangedBy, getCreateComment, getCreateDate, getCreatedBy, getID, getInstance, hashCode, save, save, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Method Detail

getTeam

public Team getTeam()
Returns:
The Team this item is assigned to.

setTeam

public void setTeam(Team team)
Parameters:
team - The Team this item is assigned to.

getIteration

public Iteration getIteration()
Returns:
The Iteration this item is assigned to.

setIteration

public void setIteration(Iteration iteration)
Parameters:
iteration - The Iteration this item is assigned to.

getTheme

public Theme getTheme()
Returns:
The Theme this item is assigned to.

setTheme

public void setTheme(Theme theme)
Parameters:
theme - The Theme this item is assigned to.

getStatus

public IListValueProperty getStatus()
Returns:
This item's Status.

getPriority

public IListValueProperty getPriority()
Returns:
This Item's Priority.

getSource

public IListValueProperty getSource()
Returns:
This Item's Source.

getRankOrder

public Rank<PrimaryWorkitem> getRankOrder()
Returns:
This item's order.

getEstimate

public java.lang.Double getEstimate()
Returns:
High-level estimate (in story points) of this item.

setEstimate

public void setEstimate(java.lang.Double estimate)
Parameters:
estimate - High-level estimate (in story points) of this item.

getGoals

public java.util.Collection<Goal> getGoals()
Returns:
Goals this item is assigned to.

getRequests

public java.util.Collection<Request> getRequests()
Returns:
Requests associated with this item.

getIssues

public java.util.Collection<Issue> getIssues()
Returns:
Issues associated with this item.

getBlockingIssues

public java.util.Collection<Issue> getBlockingIssues()
Returns:
Issues that are preventing the completion of this item.

getAffectedByDefects

public java.util.Collection<Defect> getAffectedByDefects()
Returns:
Defects affecting this item.

getCompletedIn

public java.util.Collection<BuildRun> getCompletedIn()
Returns:
Build Run's this Primary Workitem was completed in.

createTask

public Task createTask(java.lang.String name)
Create a task that belongs to this item.

Parameters:
name - The name of the task.
Returns:
created task.

createTask

public Task createTask(java.lang.String name,
                       java.util.Map<java.lang.String,java.lang.Object> attribute)
Create a task that belongs to this item.

Parameters:
name - The name of the task.
attributes - additional attributes for task.
Returns:
created task.

createTest

public Test createTest(java.lang.String name)
Create a test that belongs to this item.

Parameters:
name - The name of the test.
Returns:
created test.

createTest

public Test createTest(java.lang.String name,
                       java.util.Map<java.lang.String,java.lang.Object> attribute)
Create a test that belongs to this item.

Parameters:
name - The name of the test.
attributes - additional attributes for test.
Returns:
created test.

getTotalDetailEstimate

public java.lang.Double getTotalDetailEstimate(WorkitemFilter filter)
Gets the estimate of total effort required to implement this item.

Parameters:
filter - filter for Workitems (If null, then all items returned).
Returns:
estimate of total effort required to implement this item.

getTotalDone

public java.lang.Double getTotalDone(WorkitemFilter filter)
Gets the total effort already expended to implement this item.

Parameters:
filter - restriction for the work items which have to be counted. If null, then all items counted.
Returns:
total effort already expended to implement this item.

getTotalToDo

public java.lang.Double getTotalToDo(WorkitemFilter filter)
Gets the total remaining effort required to complete implementation of this item.

Parameters:
filter - restriction for the work items which have to be counted. If null, then all items counted.
Returns:
total remaining effort required to complete implementation of this item.

getSecondaryWorkitems

public java.util.Collection<SecondaryWorkitem> getSecondaryWorkitems(SecondaryWorkitemFilter filter)
Collection of Tasks and Tests that belong to this primary workitem.

Parameters:
filter - How to filter the secondary workitems. To get only Tasks, pass a TaskFilter. To get only Tests, pass a TestFilter.
Returns:
Collection of Tasks and Tests that belong to this primary workitem.