com.atlassian.greenhopper.service.project
Interface ProjectService

All Known Implementing Classes:
ProjectServiceImpl

public interface ProjectService

Wrapper for JIRA's ProjectService, since it's not that trivial to actually create a usable project. JIRA's service does only half the job.

Author:
ahennecke

Method Summary
 ServiceOutcome<java.lang.Boolean> canCreateProject(com.atlassian.crowd.embedded.api.User user)
           
 ServiceOutcome<com.atlassian.jira.project.Project> createProject(com.atlassian.crowd.embedded.api.User user, java.lang.String name, java.lang.String key, java.lang.String description, java.lang.String leadUserName, java.lang.String url, java.lang.Long assigneeType, java.lang.Long avatarId)
          Create a project with all the necessary bells and whistles (schemas of various kinds, all default).
 ServiceOutcome<java.lang.Void> deleteProject(com.atlassian.crowd.embedded.api.User user, com.atlassian.jira.project.Project project)
           
 ServiceOutcome<java.lang.Void> validateCreateProject(com.atlassian.crowd.embedded.api.User user, java.lang.String name, java.lang.String key, java.lang.String description, java.lang.String leadUserName, java.lang.String url, java.lang.Long assigneeType, java.lang.Long avatarId)
          Validate the creation of a project with the given parameters.
 

Method Detail

createProject

@NotNull
ServiceOutcome<com.atlassian.jira.project.Project> createProject(com.atlassian.crowd.embedded.api.User user,
                                                                         java.lang.String name,
                                                                         java.lang.String key,
                                                                         java.lang.String description,
                                                                         java.lang.String leadUserName,
                                                                         java.lang.String url,
                                                                         java.lang.Long assigneeType,
                                                                         java.lang.Long avatarId)
Create a project with all the necessary bells and whistles (schemas of various kinds, all default). If one of the steps fails, it'll try to delete the previously created data again (pseudo-transactionality).

Returns:
Outcome of the operation (either valid Value or Errors).

validateCreateProject

@NotNull
ServiceOutcome<java.lang.Void> validateCreateProject(com.atlassian.crowd.embedded.api.User user,
                                                             java.lang.String name,
                                                             java.lang.String key,
                                                             java.lang.String description,
                                                             java.lang.String leadUserName,
                                                             java.lang.String url,
                                                             java.lang.Long assigneeType,
                                                             java.lang.Long avatarId)
Validate the creation of a project with the given parameters.

Returns:
Outcome containing Errors if encountered

deleteProject

@NotNull
ServiceOutcome<java.lang.Void> deleteProject(com.atlassian.crowd.embedded.api.User user,
                                                     com.atlassian.jira.project.Project project)

canCreateProject

@NotNull
ServiceOutcome<java.lang.Boolean> canCreateProject(com.atlassian.crowd.embedded.api.User user)


Copyright © 2007-2012 Atlassian. All Rights Reserved.