com.atlassian.jira.project
Class AbstractProjectManager

java.lang.Object
  extended bycom.atlassian.jira.project.AbstractProjectManager
All Implemented Interfaces:
ProjectManager
Direct Known Subclasses:
CachingProjectManager, DefaultProjectManager

public abstract class AbstractProjectManager
extends java.lang.Object
implements ProjectManager


Constructor Summary
AbstractProjectManager()
           
 
Method Summary
abstract  void decreaseVersionSequence(GenericValue version)
          .
abstract  GenericValue getComponent(GenericValue project, java.lang.String name)
           
abstract  GenericValue getComponent(java.lang.Long id)
           
abstract  java.util.Collection getComponents(GenericValue project)
           
 User getDefaultAssignee(GenericValue project, GenericValue component)
          This function returns the default assignee if the system has been setup incorrectly then it will throw an error The isDefaultAssignee(GenericValue, GenericValue) checks if there is a valid default assignee
 GenericValue getProject(GenericValue issue)
           
abstract  GenericValue getProjectByKey(java.lang.String key)
           
abstract  GenericValue getProjectByName(java.lang.String name)
           
abstract  java.util.Collection getProjectCategories()
          Get all ProjectCategories.
abstract  GenericValue getProjectCategory(java.lang.Long id)
           
abstract  GenericValue getProjectCategoryFromProject(GenericValue project)
           
abstract  java.util.Collection getProjects()
          Return all projects
abstract  java.util.Collection getProjectsFromProjectCategory(GenericValue projectCategory)
           
abstract  java.util.Collection getProjectsWithNoCategory()
           
abstract  GenericValue getVersion(GenericValue project, java.lang.String name)
           
abstract  GenericValue getVersion(java.lang.Long id)
           
abstract  java.util.Collection getVersions(GenericValue project)
           
abstract  java.util.Collection getVersionsReleased(GenericValue project, boolean includeArchived)
           
 java.util.Collection getVersionsReleasedDesc(GenericValue project, boolean includeArchived)
           
abstract  java.util.Collection getVersionsUnreleased(GenericValue project, boolean includeArchived)
           
abstract  void increaseVersionSequence(GenericValue version)
          Move a version to have a lower sequence number - ie make it earlier
 boolean isDefaultAssignee(GenericValue project)
           
 boolean isDefaultAssignee(GenericValue project, GenericValue component)
          This function checks if there is a valid default assignee set in the system
If this returns false then the getDefaultAssignee(GenericValue, GenericValue) will throw an exception
abstract  void moveToEndVersionSequence(GenericValue version)
          .
abstract  void moveToStartVersionSequence(GenericValue version)
          Move a version to the start of the version list
abstract  void setProjectCategory(GenericValue project, GenericValue category)
           
abstract  void updateProject(GenericValue updatedProject)
           
abstract  void updateProjectCategory(GenericValue projectCat)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.atlassian.jira.project.ProjectManager
getNextId, getVersionsArchived, getVersionsReleased, getVersionsReleasedDesc, getVersionsUnarchived, getVersionsUnreleased, refresh, refresh, releaseVersions
 

Constructor Detail

AbstractProjectManager

public AbstractProjectManager()
Method Detail

updateProject

public abstract void updateProject(GenericValue updatedProject)
                            throws GenericEntityException
Specified by:
updateProject in interface ProjectManager
Throws:
GenericEntityException

getProject

public GenericValue getProject(GenericValue issue)
                        throws GenericEntityException
Specified by:
getProject in interface ProjectManager
Throws:
GenericEntityException

getProjectByName

public abstract GenericValue getProjectByName(java.lang.String name)
                                       throws GenericEntityException
Specified by:
getProjectByName in interface ProjectManager
Throws:
GenericEntityException

getProjectByKey

public abstract GenericValue getProjectByKey(java.lang.String key)
                                      throws GenericEntityException
Specified by:
getProjectByKey in interface ProjectManager
Throws:
GenericEntityException

getComponent

public abstract GenericValue getComponent(java.lang.Long id)
                                   throws GenericEntityException
Specified by:
getComponent in interface ProjectManager
Throws:
GenericEntityException

getComponent

public abstract GenericValue getComponent(GenericValue project,
                                          java.lang.String name)
                                   throws GenericEntityException
Specified by:
getComponent in interface ProjectManager
Throws:
GenericEntityException

getComponents

public abstract java.util.Collection getComponents(GenericValue project)
                                            throws GenericEntityException
Specified by:
getComponents in interface ProjectManager
Throws:
GenericEntityException

getVersion

public abstract GenericValue getVersion(java.lang.Long id)
                                 throws GenericEntityException
Specified by:
getVersion in interface ProjectManager
Throws:
GenericEntityException

getVersion

public abstract GenericValue getVersion(GenericValue project,
                                        java.lang.String name)
                                 throws GenericEntityException
Specified by:
getVersion in interface ProjectManager
Throws:
GenericEntityException

getVersions

public abstract java.util.Collection getVersions(GenericValue project)
                                          throws GenericEntityException
Specified by:
getVersions in interface ProjectManager
Throws:
GenericEntityException

getVersionsReleased

public abstract java.util.Collection getVersionsReleased(GenericValue project,
                                                         boolean includeArchived)
                                                  throws GenericEntityException
Specified by:
getVersionsReleased in interface ProjectManager
Throws:
GenericEntityException

getVersionsReleasedDesc

public java.util.Collection getVersionsReleasedDesc(GenericValue project,
                                                    boolean includeArchived)
                                             throws GenericEntityException
Specified by:
getVersionsReleasedDesc in interface ProjectManager
Throws:
GenericEntityException

getVersionsUnreleased

public abstract java.util.Collection getVersionsUnreleased(GenericValue project,
                                                           boolean includeArchived)
                                                    throws GenericEntityException
Specified by:
getVersionsUnreleased in interface ProjectManager
Throws:
GenericEntityException

getProjects

public abstract java.util.Collection getProjects()
                                          throws GenericEntityException
Description copied from interface: ProjectManager
Return all projects

Specified by:
getProjects in interface ProjectManager
Throws:
GenericEntityException

moveToStartVersionSequence

public abstract void moveToStartVersionSequence(GenericValue version)
                                         throws GenericEntityException
Description copied from interface: ProjectManager
Move a version to the start of the version list

Specified by:
moveToStartVersionSequence in interface ProjectManager
Throws:
GenericEntityException

increaseVersionSequence

public abstract void increaseVersionSequence(GenericValue version)
                                      throws GenericEntityException
Description copied from interface: ProjectManager
Move a version to have a lower sequence number - ie make it earlier

Specified by:
increaseVersionSequence in interface ProjectManager
Throws:
GenericEntityException

decreaseVersionSequence

public abstract void decreaseVersionSequence(GenericValue version)
                                      throws GenericEntityException
Description copied from interface: ProjectManager
. Move a version to have a higher sequence number - ie make it later

Specified by:
decreaseVersionSequence in interface ProjectManager
Throws:
GenericEntityException

moveToEndVersionSequence

public abstract void moveToEndVersionSequence(GenericValue version)
                                       throws GenericEntityException
Description copied from interface: ProjectManager
. Move a version to to the end of the version sequence

Specified by:
moveToEndVersionSequence in interface ProjectManager
Throws:
GenericEntityException

getProjectCategories

public abstract java.util.Collection getProjectCategories()
                                                   throws GenericEntityException
Description copied from interface: ProjectManager
Get all ProjectCategories.

Specified by:
getProjectCategories in interface ProjectManager
Throws:
GenericEntityException

getProjectCategory

public abstract GenericValue getProjectCategory(java.lang.Long id)
                                         throws GenericEntityException
Specified by:
getProjectCategory in interface ProjectManager
Throws:
GenericEntityException

updateProjectCategory

public abstract void updateProjectCategory(GenericValue projectCat)
                                    throws GenericEntityException
Specified by:
updateProjectCategory in interface ProjectManager
Throws:
GenericEntityException

getProjectsFromProjectCategory

public abstract java.util.Collection getProjectsFromProjectCategory(GenericValue projectCategory)
                                                             throws GenericEntityException
Specified by:
getProjectsFromProjectCategory in interface ProjectManager
Throws:
GenericEntityException

getProjectsWithNoCategory

public abstract java.util.Collection getProjectsWithNoCategory()
                                                        throws GenericEntityException
Specified by:
getProjectsWithNoCategory in interface ProjectManager
Throws:
GenericEntityException

getProjectCategoryFromProject

public abstract GenericValue getProjectCategoryFromProject(GenericValue project)
                                                    throws GenericEntityException
Specified by:
getProjectCategoryFromProject in interface ProjectManager
Throws:
GenericEntityException

setProjectCategory

public abstract void setProjectCategory(GenericValue project,
                                        GenericValue category)
                                 throws GenericEntityException
Specified by:
setProjectCategory in interface ProjectManager
Throws:
GenericEntityException

isDefaultAssignee

public boolean isDefaultAssignee(GenericValue project,
                                 GenericValue component)
This function checks if there is a valid default assignee set in the system
If this returns false then the getDefaultAssignee(GenericValue, GenericValue) will throw an exception

Specified by:
isDefaultAssignee in interface ProjectManager
Parameters:
project -
component -
Returns:

isDefaultAssignee

public boolean isDefaultAssignee(GenericValue project)
Specified by:
isDefaultAssignee in interface ProjectManager

getDefaultAssignee

public User getDefaultAssignee(GenericValue project,
                               GenericValue component)
This function returns the default assignee if the system has been setup incorrectly then it will throw an error The isDefaultAssignee(GenericValue, GenericValue) checks if there is a valid default assignee

Specified by:
getDefaultAssignee in interface ProjectManager
Parameters:
project -
component -
Returns: