1 package org.apache.maven.continuum.builddefinition;
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22 import org.apache.maven.continuum.model.project.BuildDefinition;
23 import org.apache.maven.continuum.model.project.BuildDefinitionTemplate;
24 import org.apache.maven.continuum.model.project.Project;
25 import org.apache.maven.continuum.model.project.ProjectGroup;
26 import org.apache.maven.continuum.store.ContinuumObjectNotFoundException;
27
28 import java.util.List;
29
30
31
32
33
34
35 public interface BuildDefinitionService
36 {
37
38
39
40
41
42
43
44 BuildDefinition getBuildDefinition( int buildDefinitionId )
45 throws BuildDefinitionServiceException;
46
47
48
49
50
51
52 List<BuildDefinition> getAllBuildDefinitions()
53 throws BuildDefinitionServiceException;
54
55 BuildDefinition addBuildDefinition( BuildDefinition buildDefinition )
56 throws BuildDefinitionServiceException;
57
58 void removeBuildDefinition( BuildDefinition buildDefinition )
59 throws BuildDefinitionServiceException;
60
61 void updateBuildDefinition( BuildDefinition buildDefinition )
62 throws BuildDefinitionServiceException;
63
64 List<BuildDefinition> getAllTemplates()
65 throws BuildDefinitionServiceException;
66
67
68
69
70
71 BuildDefinition cloneBuildDefinition( BuildDefinition buildDefinition );
72
73
74
75
76
77 void addTemplateInProject( int buildDefinitionTemplateId, Project project )
78 throws BuildDefinitionServiceException;
79
80
81 List<BuildDefinitionTemplate> getAllBuildDefinitionTemplate()
82 throws BuildDefinitionServiceException;
83
84 BuildDefinitionTemplate getBuildDefinitionTemplate( int id )
85 throws BuildDefinitionServiceException;
86
87 BuildDefinitionTemplate addBuildDefinitionTemplate( BuildDefinitionTemplate buildDefinitionTemplate )
88 throws BuildDefinitionServiceException;
89
90 BuildDefinitionTemplate updateBuildDefinitionTemplate( BuildDefinitionTemplate buildDefinitionTemplate )
91 throws BuildDefinitionServiceException;
92
93 void removeBuildDefinitionTemplate( BuildDefinitionTemplate buildDefinitionTemplate )
94 throws BuildDefinitionServiceException;
95
96 public BuildDefinitionTemplate addBuildDefinitionInTemplate( BuildDefinitionTemplate buildDefinitionTemplate,
97 BuildDefinition buildDefinition, boolean template )
98 throws BuildDefinitionServiceException;
99
100 BuildDefinitionTemplate removeBuildDefinitionFromTemplate( BuildDefinitionTemplate buildDefinitionTemplate,
101 BuildDefinition buildDefinition )
102 throws BuildDefinitionServiceException;
103
104 public BuildDefinitionTemplate getDefaultAntBuildDefinitionTemplate()
105 throws BuildDefinitionServiceException;
106
107 public BuildDefinitionTemplate getDefaultMavenOneBuildDefinitionTemplate()
108 throws BuildDefinitionServiceException;
109
110 public BuildDefinitionTemplate getDefaultMavenTwoBuildDefinitionTemplate()
111 throws BuildDefinitionServiceException;
112
113 public BuildDefinitionTemplate getDefaultShellBuildDefinitionTemplate()
114 throws BuildDefinitionServiceException;
115
116 public BuildDefinitionTemplate getContinuumDefaultWithType( String type )
117 throws BuildDefinitionServiceException;
118
119 public List<BuildDefinitionTemplate> getBuildDefinitionTemplatesWithType( String type )
120 throws BuildDefinitionServiceException;
121
122 public ProjectGroup addBuildDefinitionTemplateToProjectGroup( int projectGroupId,
123 BuildDefinitionTemplate buildDefinitionTemplate )
124 throws BuildDefinitionServiceException, ContinuumObjectNotFoundException;
125
126 public List<BuildDefinitionTemplate> getContinuumBuildDefinitionTemplates()
127 throws BuildDefinitionServiceException;
128 }