org.squashtest.csp.tm.service
Interface BugTrackerLocalService

All Known Implementing Classes:
BugTrackerLocalServiceImpl

public interface BugTrackerLocalService


Method Summary
 BugTrackerStatus checkBugTrackerStatus()
          tests if the bugtracker is ready for use
 org.squashtest.csp.core.bugtracker.domain.BTIssue createIssue(Bugged entity, org.squashtest.csp.core.bugtracker.domain.BTIssue issue)
          adds a new Issue to the entity.
<X extends Bugged>
X
findBuggedEntity(Long entityId, Class<X> entityClass)
          returns an instance of an entity that implements Bugged, provided its id and actual class.
 FilteredCollectionHolder<List<IssueOwnership<org.squashtest.csp.core.bugtracker.domain.BTIssue>>> findBugTrackerIssues(Bugged buggedEntity, CollectionSorting sorter)
          Given a Bugged Entity, returns a list of BTIssue (not Issue).
 org.squashtest.csp.core.bugtracker.domain.BTProject findRemoteProject(String name)
          returns an instance of the remote project.
 FilteredCollectionHolder<List<IssueOwnership<Issue>>> findSquashIssues(Bugged buggedEntity, CollectionSorting sorter)
          Given a Bugged Entity, returns a list of Issue (not BTIssue).
 org.squashtest.csp.core.bugtracker.spi.BugTrackerInterfaceDescriptor getInterfaceDescriptor()
          An InterfaceDescriptor contains informations relevant to the generation of a view/GUI.
 List<org.squashtest.csp.core.bugtracker.domain.BTIssue> getIssues(List<String> issueKeyList)
          returns a list of BTIssu corresponding to the given string keys
 URL getIssueUrl(String btIssueId)
          Gets the url of a remote Issue given its Id
 List<org.squashtest.csp.core.bugtracker.domain.Priority> getRemotePriorities()
          returns the list of priorities .
 void setCredentials(String username, String password)
          sets the credentials of an user for authentication bugtracker-side.
 

Method Detail

findBuggedEntity

<X extends Bugged> X findBuggedEntity(Long entityId,
                                      Class<X> entityClass)
returns an instance of an entity that implements Bugged, provided its id and actual class.

Type Parameters:
X - : a .class of an implementor of bugged.
Parameters:
entityId - : the id of that entity.
entityClass - : the actual class of that entity.
Returns:
: the entity if found, null if not found.

createIssue

org.squashtest.csp.core.bugtracker.domain.BTIssue createIssue(Bugged entity,
                                                              org.squashtest.csp.core.bugtracker.domain.BTIssue issue)
adds a new Issue to the entity. The entity must implement Bugged.

Parameters:
entityId - : the id of that entity.
entityClass - : the actual class of that entity, that implements Bugged.
issue - : the issue to add
Returns:
the BTIssue corresponding to the bug remotely created

getIssueUrl

URL getIssueUrl(String btIssueId)
Gets the url of a remote Issue given its Id

Parameters:
btIssueId - the id of that issue
Returns:
the URL where you may find that issue.

getInterfaceDescriptor

org.squashtest.csp.core.bugtracker.spi.BugTrackerInterfaceDescriptor getInterfaceDescriptor()
An InterfaceDescriptor contains informations relevant to the generation of a view/GUI. See the class for more details.

Returns:
an InterfaceDescriptor.

findSquashIssues

FilteredCollectionHolder<List<IssueOwnership<Issue>>> findSquashIssues(Bugged buggedEntity,
                                                                       CollectionSorting sorter)
Given a Bugged Entity, returns a list of Issue (not BTIssue). That method will return the list of - its own issues, - the issues of other Bugged entities it may be related to. To keep track of which entity owns which issue, the data are wrapped in a IssueOwnership (that just pair the informations together).

Parameters:
buggedEntity - of which we need to get the issues,
sorter - that tells us how we should sort and filter the data
Returns:
a FilteredCollectionHolder containing a non-null but possibly empty list of IssueOwnership, sorted and filtered according to the CollectionSorting.

findBugTrackerIssues

FilteredCollectionHolder<List<IssueOwnership<org.squashtest.csp.core.bugtracker.domain.BTIssue>>> findBugTrackerIssues(Bugged buggedEntity,
                                                                                                                       CollectionSorting sorter)
Given a Bugged Entity, returns a list of BTIssue (not Issue). That method will return the list of - its own issues, - the issues of other Bugged entities it may be related to. To keep track of which entity owns which issue, the data are wrapped in a IssueOwnership (that just pair the informations together).

Parameters:
buggedEntity - of which we need to get the issues,
sorter - that tells us how we should sort and filter the data
Returns:
a FilteredCollectionHolder containing a non-null but possibly empty list of IssueOwnership, sorted and filtered according to the CollectionSorting.

checkBugTrackerStatus

BugTrackerStatus checkBugTrackerStatus()
tests if the bugtracker is ready for use

Returns:
the status of the bugtracker

setCredentials

void setCredentials(String username,
                    String password)
sets the credentials of an user for authentication bugtracker-side.

Parameters:
username -
password -
Throws:
org.squashtest.csp.core.bugtracker.core.BugTrackerRemoteException - if the credentials are wrong

findRemoteProject

org.squashtest.csp.core.bugtracker.domain.BTProject findRemoteProject(String name)
returns an instance of the remote project.

Parameters:
name - : the name of the project.
Returns:
the project filled with users and versions if found.

getRemotePriorities

List<org.squashtest.csp.core.bugtracker.domain.Priority> getRemotePriorities()
returns the list of priorities .

Returns:
the list of priorities. An empty list is returned if none are found.
Throws:
org.squashtest.csp.core.bugtracker.core.BugTrackerManagerException - and subtypes.

getIssues

List<org.squashtest.csp.core.bugtracker.domain.BTIssue> getIssues(List<String> issueKeyList)
returns a list of BTIssu corresponding to the given string keys

Parameters:
issueKeyList - the issue key list
Returns:
a BTIssue list


Copyright © 2010-2012 Squashtest TM, Squashtest.org. All Rights Reserved.