Revision 37599 branches/v2_0_0_prep/extensions/org.gvsig.installer/org.gvsig.installer.lib/org.gvsig.installer.lib.api/src/main/java/org/gvsig/installer/lib/api/PackageInfo.java
PackageInfo.java | ||
---|---|---|
40 | 40 |
import org.gvsig.tools.task.SimpleTaskStatus; |
41 | 41 |
|
42 | 42 |
/** |
43 |
* Information of a package that is used on the installation process. |
|
44 |
* This information is composed by next fields: |
|
45 |
* </br> <li> |
|
43 |
* Information of a package that is used on the installation process. This |
|
44 |
* information is composed by next fields: </br> <li> |
|
46 | 45 |
* <lu><b>Code</b>: unique identifier for the package.</lu> <lu><b>Name</b>: |
47 | 46 |
* name of the package.</lu> <lu><b>Description</b>: brief description of the |
48 | 47 |
* package functionality</lu> * <lu><b>Version</b>: number of version.</lu> |
... | ... | |
60 | 59 |
*/ |
61 | 60 |
public interface PackageInfo extends Cloneable { |
62 | 61 |
|
63 |
/** |
|
64 |
* @return |
|
65 |
* Gets the code of the package. |
|
66 |
*/ |
|
67 |
public String getCode(); |
|
62 |
/** |
|
63 |
* @return Gets the code of the package. |
|
64 |
*/ |
|
65 |
public String getCode(); |
|
68 | 66 |
|
69 |
public void setCode(String code);
|
|
67 |
public void setCode(String code);
|
|
70 | 68 |
|
71 |
public String getID();
|
|
69 |
public String getID();
|
|
72 | 70 |
|
73 |
/** |
|
74 |
* @return |
|
75 |
* Gets the name of the package. |
|
76 |
*/ |
|
77 |
public String getName(); |
|
71 |
/** |
|
72 |
* @return Gets the name of the package. |
|
73 |
*/ |
|
74 |
public String getName(); |
|
78 | 75 |
|
79 |
public void setName(String name);
|
|
76 |
public void setName(String name);
|
|
80 | 77 |
|
81 |
/** |
|
82 |
* @return |
|
83 |
* Gets the description of the package. |
|
84 |
*/ |
|
85 |
public String getDescription(); |
|
78 |
/** |
|
79 |
* @return Gets the description of the package. |
|
80 |
*/ |
|
81 |
public String getDescription(); |
|
86 | 82 |
|
87 |
public void setDescription(String description);
|
|
83 |
public void setDescription(String description);
|
|
88 | 84 |
|
89 |
/** |
|
90 |
* @return |
|
91 |
* Gets the version of the package. |
|
92 |
*/ |
|
93 |
public Version getVersion(); |
|
85 |
/** |
|
86 |
* @return Gets the version of the package. |
|
87 |
*/ |
|
88 |
public Version getVersion(); |
|
94 | 89 |
|
95 |
public void setVersion(String version); |
|
96 |
public void setVersion(Version version); |
|
90 |
public void setVersion(String version); |
|
97 | 91 |
|
98 |
/** |
|
99 |
* @return |
|
100 |
* Gets the build number of the package. |
|
101 |
*/ |
|
102 |
public int getBuild(); |
|
92 |
public void setVersion(Version version); |
|
103 | 93 |
|
104 |
public void setBuild(int build); |
|
94 |
/** |
|
95 |
* @return Gets the build number of the package. |
|
96 |
*/ |
|
97 |
public int getBuild(); |
|
105 | 98 |
|
106 |
/** |
|
107 |
* @return |
|
108 |
* Gets the state of the package. |
|
109 |
* @see STATE |
|
110 |
*/ |
|
111 |
public String getState(); |
|
99 |
public void setBuild(int build); |
|
112 | 100 |
|
113 |
/** |
|
114 |
* Sets the state of the package |
|
115 |
* |
|
116 |
* @param state |
|
117 |
* @see STATE |
|
118 |
*/ |
|
119 |
public void setState(String state); |
|
101 |
/** |
|
102 |
* @return Gets the state of the package. |
|
103 |
* @see STATE |
|
104 |
*/ |
|
105 |
public String getState(); |
|
120 | 106 |
|
121 |
/** |
|
122 |
* @return |
|
123 |
* Gets if the package is official. |
|
124 |
*/ |
|
125 |
public boolean isOfficial(); |
|
107 |
/** |
|
108 |
* Sets the state of the package |
|
109 |
* |
|
110 |
* @param state |
|
111 |
* @see STATE |
|
112 |
*/ |
|
113 |
public void setState(String state); |
|
126 | 114 |
|
127 |
public void setOfficial(boolean official); |
|
115 |
/** |
|
116 |
* @return Gets if the package is official. |
|
117 |
*/ |
|
118 |
public boolean isOfficial(); |
|
128 | 119 |
|
129 |
/** |
|
130 |
* @return |
|
131 |
* Gets the type of the package. |
|
132 |
*/ |
|
133 |
public String getType(); |
|
120 |
public void setOfficial(boolean official); |
|
134 | 121 |
|
135 |
public void setType(String type); |
|
122 |
/** |
|
123 |
* @return Gets the type of the package. |
|
124 |
*/ |
|
125 |
public String getType(); |
|
136 | 126 |
|
137 |
/** |
|
138 |
* Returns the supported operating system. |
|
139 |
* |
|
140 |
* @return the supported operating system |
|
141 |
* @see OS |
|
142 |
*/ |
|
143 |
public String getOperatingSystem(); |
|
127 |
public void setType(String type); |
|
144 | 128 |
|
145 |
/** |
|
146 |
* Sets the supported operating system. |
|
147 |
* |
|
148 |
* @param operatingSystem |
|
149 |
* the supported operating system |
|
150 |
* @see OS |
|
151 |
*/ |
|
152 |
public void setOperatingSystem(String operatingSystem); |
|
129 |
/** |
|
130 |
* Returns the supported operating system. |
|
131 |
* |
|
132 |
* @return the supported operating system |
|
133 |
* @see OS |
|
134 |
*/ |
|
135 |
public String getOperatingSystem(); |
|
153 | 136 |
|
154 |
/** |
|
155 |
* Returns the supported hardware architecture. |
|
156 |
* |
|
157 |
* @return the supported hardware architecture |
|
158 |
* @see ARCH |
|
159 |
*/ |
|
160 |
public String getArchitecture(); |
|
137 |
/** |
|
138 |
* Sets the supported operating system. |
|
139 |
* |
|
140 |
* @param operatingSystem |
|
141 |
* the supported operating system |
|
142 |
* @see OS |
|
143 |
*/ |
|
144 |
public void setOperatingSystem(String operatingSystem); |
|
161 | 145 |
|
162 |
/** |
|
163 |
* Sets the supported hardware architecture. |
|
164 |
* |
|
165 |
* @param architecture |
|
166 |
* the supported hardware architecture |
|
167 |
* @see ARCH |
|
168 |
*/ |
|
169 |
public void setArchitecture(String architecture); |
|
146 |
/** |
|
147 |
* Returns the supported hardware architecture. |
|
148 |
* |
|
149 |
* @return the supported hardware architecture |
|
150 |
* @see ARCH |
|
151 |
*/ |
|
152 |
public String getArchitecture(); |
|
170 | 153 |
|
171 |
/** |
|
172 |
* Returns the supported java vm version. |
|
173 |
* |
|
174 |
* @return the supported java vm version |
|
175 |
* @see JVM |
|
176 |
*/ |
|
177 |
public String getJavaVM(); |
|
154 |
/** |
|
155 |
* Sets the supported hardware architecture. |
|
156 |
* |
|
157 |
* @param architecture |
|
158 |
* the supported hardware architecture |
|
159 |
* @see ARCH |
|
160 |
*/ |
|
161 |
public void setArchitecture(String architecture); |
|
178 | 162 |
|
179 |
/** |
|
180 |
* Sets the supported java vm version. |
|
181 |
* |
|
182 |
* @param javaVM |
|
183 |
* the supported java vm version |
|
184 |
* @see JVM |
|
185 |
*/ |
|
186 |
public void setJavaVM(String javaVM); |
|
163 |
/** |
|
164 |
* Returns the supported java vm version. |
|
165 |
* |
|
166 |
* @return the supported java vm version |
|
167 |
* @see JVM |
|
168 |
*/ |
|
169 |
public String getJavaVM(); |
|
187 | 170 |
|
188 |
/** |
|
189 |
* Returns the supported gvSIG version. |
|
190 |
* |
|
191 |
* @return the supported gvSIG version |
|
192 |
*/ |
|
193 |
public String getGvSIGVersion(); |
|
171 |
/** |
|
172 |
* Sets the supported java vm version. |
|
173 |
* |
|
174 |
* @param javaVM |
|
175 |
* the supported java vm version |
|
176 |
* @see JVM |
|
177 |
*/ |
|
178 |
public void setJavaVM(String javaVM); |
|
194 | 179 |
|
195 |
/** |
|
196 |
* Sets the supported gvSIG version. |
|
197 |
* |
|
198 |
* @param gvSIGVersion |
|
199 |
* the supported gvSIG version |
|
200 |
*/ |
|
201 |
public void setGvSIGVersion(String gvSIGVersion); |
|
180 |
/** |
|
181 |
* Returns the supported gvSIG version. |
|
182 |
* |
|
183 |
* @return the supported gvSIG version |
|
184 |
*/ |
|
185 |
public String getGvSIGVersion(); |
|
202 | 186 |
|
203 |
/** |
|
204 |
* Returns the package bundle download {@link URL}. |
|
205 |
* |
|
206 |
* May be null if there is no remote URL to download the bundle. |
|
207 |
* |
|
208 |
* @return the package bundle download {@link URL} |
|
209 |
*/ |
|
210 |
public URL getDownloadURL(); |
|
211 |
|
|
212 |
public String getDownloadURLAsString(); |
|
213 |
|
|
214 |
// /** |
|
215 |
// * Returns the package bundle download {@link URL}. |
|
216 |
// * |
|
217 |
// * May be null if there is no remote URL to download the bundle. |
|
218 |
// * |
|
219 |
// * @return the package bundle download {@link URL} |
|
220 |
// */ |
|
221 |
public URL getDownloadURL(URL baseURL); |
|
187 |
/** |
|
188 |
* Sets the supported gvSIG version. |
|
189 |
* |
|
190 |
* @param gvSIGVersion |
|
191 |
* the supported gvSIG version |
|
192 |
*/ |
|
193 |
public void setGvSIGVersion(String gvSIGVersion); |
|
222 | 194 |
|
223 |
/** |
|
224 |
* Sets the package bundle download {@link URL}. Optional. |
|
225 |
* |
|
226 |
* @param defaultURL |
|
227 |
* the package bundle download {@link URL} |
|
228 |
*/ |
|
229 |
public void setDownloadURL(URL defaultURL); |
|
230 |
|
|
231 |
public void setDownloadURL(String defaultDownloadURL); |
|
232 |
|
|
233 |
/** |
|
234 |
* Returns the package info model version. |
|
235 |
* |
|
236 |
* @return the package info model version |
|
237 |
*/ |
|
238 |
public String getModelVersion(); |
|
195 |
/** |
|
196 |
* Returns the package bundle download {@link URL}. |
|
197 |
* |
|
198 |
* May be null if there is no remote URL to download the bundle. |
|
199 |
* |
|
200 |
* @return the package bundle download {@link URL} |
|
201 |
*/ |
|
202 |
public URL getDownloadURL(); |
|
239 | 203 |
|
240 |
/** |
|
241 |
* Sets the package info model version. |
|
242 |
* |
|
243 |
* @param modelVersion |
|
244 |
* the package info model version |
|
245 |
*/ |
|
246 |
public void setModelVersion(String modelVersion); |
|
247 |
|
|
248 |
public String getOwner(); |
|
249 |
|
|
250 |
/** |
|
251 |
* Sets the package owner. |
|
252 |
* |
|
253 |
* @param owner |
|
254 |
* the package owner |
|
255 |
*/ |
|
256 |
public void setOwner(String owner); |
|
257 |
|
|
258 |
/** |
|
259 |
* Returns the package source files url {@link URL}. |
|
260 |
* |
|
261 |
* @return the package source files url {@link URL} |
|
262 |
*/ |
|
263 |
public URL getSourcesURL(); |
|
204 |
public String getDownloadURLAsString(); |
|
264 | 205 |
|
265 |
/** |
|
266 |
* Sets the package sources. |
|
267 |
* |
|
268 |
* @param sources |
|
269 |
* the package sources |
|
270 |
*/ |
|
271 |
public void setSourcesURL(URL sources); |
|
206 |
// /** |
|
207 |
// * Returns the package bundle download {@link URL}. |
|
208 |
// * |
|
209 |
// * May be null if there is no remote URL to download the bundle. |
|
210 |
// * |
|
211 |
// * @return the package bundle download {@link URL} |
|
212 |
// */ |
|
213 |
public URL getDownloadURL(URL baseURL); |
|
272 | 214 |
|
273 |
/** |
|
274 |
* Returns the package web url {@link URL}. |
|
275 |
* |
|
276 |
* @return the package web url {@link URL} |
|
277 |
*/ |
|
278 |
public URL getWebURL(); |
|
215 |
/** |
|
216 |
* Sets the package bundle download {@link URL}. Optional. |
|
217 |
* |
|
218 |
* @param defaultURL |
|
219 |
* the package bundle download {@link URL} |
|
220 |
*/ |
|
221 |
public void setDownloadURL(URL defaultURL); |
|
279 | 222 |
|
280 |
/** |
|
281 |
* Sets the package web url {@link URL}. |
|
282 |
* |
|
283 |
* @param webURL |
|
284 |
* the package web url {@link URL} |
|
285 |
*/ |
|
286 |
public void setWebURL(URL webURL); |
|
287 |
|
|
288 |
/** |
|
289 |
* Gets the ant script that has to be executed in the |
|
290 |
* installation process. |
|
291 |
* |
|
292 |
* @return |
|
293 |
* the script. |
|
294 |
*/ |
|
295 |
public String getAntScript(); |
|
223 |
public void setDownloadURL(String defaultDownloadURL); |
|
296 | 224 |
|
297 |
/** |
|
298 |
* Sets the ant script that can be executed in the |
|
299 |
* installation process. |
|
300 |
* |
|
301 |
* @param antScript |
|
302 |
* The ant script to copy. |
|
303 |
*/ |
|
304 |
public void setAntScript(String antScript); |
|
225 |
/** |
|
226 |
* Returns the package info model version. |
|
227 |
* |
|
228 |
* @return the package info model version |
|
229 |
*/ |
|
230 |
public String getModelVersion(); |
|
305 | 231 |
|
306 |
public File downloadFile() throws InstallPackageServiceException; |
|
232 |
/** |
|
233 |
* Sets the package info model version. |
|
234 |
* |
|
235 |
* @param modelVersion |
|
236 |
* the package info model version |
|
237 |
*/ |
|
238 |
public void setModelVersion(String modelVersion); |
|
307 | 239 |
|
308 |
public File downloadFile(SimpleTaskStatus taskStatus) |
|
309 |
throws InstallPackageServiceException; |
|
240 |
public String getOwner(); |
|
310 | 241 |
|
311 |
/** |
|
312 |
* @return |
|
313 |
*/ |
|
314 |
public void addFileToCopy(File file); |
|
242 |
/** |
|
243 |
* Sets the package owner. |
|
244 |
* |
|
245 |
* @param owner |
|
246 |
* the package owner |
|
247 |
*/ |
|
248 |
public void setOwner(String owner); |
|
315 | 249 |
|
316 |
public File getFileToCopy(int i); |
|
250 |
/** |
|
251 |
* Returns the package source files url {@link URL}. |
|
252 |
* |
|
253 |
* @return the package source files url {@link URL} |
|
254 |
*/ |
|
255 |
public URL getSourcesURL(); |
|
317 | 256 |
|
318 |
public void removeFileToCopy(File file); |
|
257 |
/** |
|
258 |
* Sets the package sources. |
|
259 |
* |
|
260 |
* @param sources |
|
261 |
* the package sources |
|
262 |
*/ |
|
263 |
public void setSourcesURL(URL sources); |
|
319 | 264 |
|
320 |
public void clearFilesToCopy(); |
|
265 |
/** |
|
266 |
* Returns the package web url {@link URL}. |
|
267 |
* |
|
268 |
* @return the package web url {@link URL} |
|
269 |
*/ |
|
270 |
public URL getWebURL(); |
|
321 | 271 |
|
322 |
public List<File> getFilesToCopy(); |
|
272 |
/** |
|
273 |
* Sets the package web url {@link URL}. |
|
274 |
* |
|
275 |
* @param webURL |
|
276 |
* the package web url {@link URL} |
|
277 |
*/ |
|
278 |
public void setWebURL(URL webURL); |
|
323 | 279 |
|
324 |
/** |
|
325 |
* @param folder |
|
326 |
* @return |
|
327 |
*/ |
|
328 |
public boolean removeInstallFolder(File folder); |
|
329 |
|
|
330 |
public boolean removeFilesFolder(File folder); |
|
280 |
/** |
|
281 |
* Gets the ant script that has to be executed in the installation process. |
|
282 |
* |
|
283 |
* @return the script. |
|
284 |
*/ |
|
285 |
public String getAntScript(); |
|
331 | 286 |
|
332 |
/** |
|
333 |
* @param string |
|
334 |
* @return |
|
335 |
*/ |
|
336 |
public boolean matchID(String string); |
|
287 |
/** |
|
288 |
* Sets the ant script that can be executed in the installation process. |
|
289 |
* |
|
290 |
* @param antScript |
|
291 |
* The ant script to copy. |
|
292 |
*/ |
|
293 |
public void setAntScript(String antScript); |
|
337 | 294 |
|
338 |
public Dependencies getDependencies(); |
|
339 |
|
|
340 |
public void setDependencies(String dependencies); |
|
341 |
|
|
342 |
public void setDependencies(Dependencies dependencies); |
|
343 |
|
|
344 |
public String toStringCompact(); |
|
345 |
|
|
346 |
public List<String> getCategories(); |
|
347 |
|
|
348 |
public void setCategories(List<String> categoriesList); |
|
349 |
|
|
350 |
public String getCategoriesAsString(); |
|
351 |
|
|
352 |
public void addCategoriesAsString(String categoriesString); |
|
353 |
|
|
295 |
public File downloadFile() throws InstallPackageServiceException; |
|
296 |
|
|
297 |
public File downloadFile(SimpleTaskStatus taskStatus) |
|
298 |
throws InstallPackageServiceException; |
|
299 |
|
|
300 |
/** |
|
301 |
* @return |
|
302 |
*/ |
|
303 |
public void addFileToCopy(File file); |
|
304 |
|
|
305 |
public File getFileToCopy(int i); |
|
306 |
|
|
307 |
public void removeFileToCopy(File file); |
|
308 |
|
|
309 |
public void clearFilesToCopy(); |
|
310 |
|
|
311 |
public List<File> getFilesToCopy(); |
|
312 |
|
|
313 |
/** |
|
314 |
* @param folder |
|
315 |
* @return |
|
316 |
*/ |
|
317 |
public boolean removeInstallFolder(File folder); |
|
318 |
|
|
319 |
public boolean removeFilesFolder(File folder); |
|
320 |
|
|
321 |
/** |
|
322 |
* @param string |
|
323 |
* @return |
|
324 |
*/ |
|
325 |
public boolean matchID(String string); |
|
326 |
|
|
327 |
public Dependencies getDependencies(); |
|
328 |
|
|
329 |
public void setDependencies(String dependencies); |
|
330 |
|
|
331 |
public void setDependencies(Dependencies dependencies); |
|
332 |
|
|
333 |
public String toStringCompact(); |
|
334 |
|
|
335 |
public List<String> getCategories(); |
|
336 |
|
|
337 |
public void setCategories(List<String> categoriesList); |
|
338 |
|
|
339 |
public String getCategoriesAsString(); |
|
340 |
|
|
341 |
public void addCategoriesAsString(String categoriesString); |
|
342 |
|
|
354 | 343 |
} |
Also available in: Unified diff