View Javadoc

1   /**
2    * Copyright (C) 2008 Atlassian
3    * 
4    * Licensed under the Apache License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    * 
8    *    http://www.apache.org/licenses/LICENSE-2.0
9    * 
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  
17  package com.atlassian.theplugin.jira;
18  
19  import com.atlassian.theplugin.commons.Server;
20  import com.atlassian.theplugin.commons.remoteapi.ProductServerFacade;
21  import com.atlassian.theplugin.commons.remoteapi.RemoteApiException;
22  import com.atlassian.theplugin.jira.api.*;
23  
24  import java.util.Calendar;
25  import java.util.List;
26  
27  public interface JIRAServerFacade extends ProductServerFacade {
28      List getIssues(Server server, List<JIRAQueryFragment> query,
29  				   String sort,
30  				   String sortOrder,
31  				   int start,
32  				   int size) throws JIRAException;
33  
34  	List getSavedFilterIssues(Server server,
35  							  List<JIRAQueryFragment> query,
36  							  String sort,
37  							  String sortOrder,
38  							  int start,
39  							  int size) throws JIRAException;
40  
41  	List<JIRAProject> getProjects(Server server) throws JIRAException;
42  
43      List<JIRAConstant> getIssueTypes(Server server) throws JIRAException;
44      
45      List<JIRAConstant> getStatuses(Server server) throws JIRAException;
46  
47  	List<JIRAConstant> getIssueTypesForProject(Server server, String project) throws JIRAException;
48  
49  	List<JIRAQueryFragment> getSavedFilters(Server server) throws JIRAException;	
50  
51  	List<JIRAComponentBean> getComponents(Server server, String projectKey) throws JIRAException;
52  
53  	List<JIRAVersionBean> getVersions(Server server, String projectKey) throws JIRAException;
54  
55  	List<JIRAConstant> getPriorities(Server server) throws JIRAException;
56  
57  	List<JIRAResolutionBean> getResolutions(Server server) throws JIRAException;
58  
59      List<JIRAAction> getAvailableActions(Server server, JIRAIssue issue) throws JIRAException;
60  
61  	List<JIRAActionField> getFieldsForAction(Server server, JIRAIssue issue, JIRAAction action) throws JIRAException;
62  
63  	void progressWorkflowAction(Server server, JIRAIssue issue, JIRAAction action) throws JIRAException;
64  
65  	void addComment(Server server, JIRAIssue issue, String comment) throws JIRAException;
66  
67      JIRAIssue createIssue(Server server, JIRAIssue issue) throws JIRAException;
68  
69  	JIRAIssue getIssueDetails(Server server, JIRAIssue issue) throws JIRAException;
70  
71  	void logWork(Server server, JIRAIssue issue, String timeSpent, Calendar startDate,
72  				 String comment, boolean updateEstimate, String newEstimate)
73  			throws JIRAException;
74  
75  	void setAssignee(Server server, JIRAIssue issue, String assignee) throws JIRAException;
76  
77  	List<JIRAComment> getComments(Server server, JIRAIssue issue) throws JIRAException;
78  }