1343 |
15 Sep 05 |
nicklas |
1 |
/* |
1343 |
15 Sep 05 |
nicklas |
$Id$ |
1343 |
15 Sep 05 |
nicklas |
3 |
|
3675 |
16 Aug 07 |
jari |
Copyright (C) 2005 Nicklas Nordborg |
4889 |
06 Apr 09 |
nicklas |
Copyright (C) 2006 Jari Häkkinen, Nicklas Nordborg |
1343 |
15 Sep 05 |
nicklas |
6 |
|
2304 |
22 May 06 |
jari |
This file is part of BASE - BioArray Software Environment. |
2304 |
22 May 06 |
jari |
Available at http://base.thep.lu.se/ |
1343 |
15 Sep 05 |
nicklas |
9 |
|
1343 |
15 Sep 05 |
nicklas |
BASE is free software; you can redistribute it and/or |
1343 |
15 Sep 05 |
nicklas |
modify it under the terms of the GNU General Public License |
4480 |
05 Sep 08 |
jari |
as published by the Free Software Foundation; either version 3 |
1343 |
15 Sep 05 |
nicklas |
of the License, or (at your option) any later version. |
1343 |
15 Sep 05 |
nicklas |
14 |
|
1343 |
15 Sep 05 |
nicklas |
BASE is distributed in the hope that it will be useful, |
1343 |
15 Sep 05 |
nicklas |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
1343 |
15 Sep 05 |
nicklas |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
1343 |
15 Sep 05 |
nicklas |
GNU General Public License for more details. |
1343 |
15 Sep 05 |
nicklas |
19 |
|
1343 |
15 Sep 05 |
nicklas |
You should have received a copy of the GNU General Public License |
4514 |
11 Sep 08 |
jari |
along with BASE. If not, see <http://www.gnu.org/licenses/>. |
1343 |
15 Sep 05 |
nicklas |
22 |
*/ |
1343 |
15 Sep 05 |
nicklas |
23 |
import net.sf.basedb.core.ProgressReporter; |
1343 |
15 Sep 05 |
nicklas |
24 |
import net.sf.basedb.core.plugin.AbstractPlugin; |
1343 |
15 Sep 05 |
nicklas |
25 |
import net.sf.basedb.core.plugin.Request; |
1343 |
15 Sep 05 |
nicklas |
26 |
import net.sf.basedb.core.plugin.Response; |
1343 |
15 Sep 05 |
nicklas |
27 |
|
1343 |
15 Sep 05 |
nicklas |
28 |
/** |
1343 |
15 Sep 05 |
nicklas |
Just a simple test plugin that is placed in a JAR file. |
1343 |
15 Sep 05 |
nicklas |
30 |
|
1343 |
15 Sep 05 |
nicklas |
@author Nicklas |
1343 |
15 Sep 05 |
nicklas |
@version 2.0 |
1343 |
15 Sep 05 |
nicklas |
@base.modified $Date$ |
1343 |
15 Sep 05 |
nicklas |
34 |
*/ |
1343 |
15 Sep 05 |
nicklas |
35 |
public class JarPlugin |
1343 |
15 Sep 05 |
nicklas |
36 |
extends AbstractPlugin |
1377 |
22 Sep 05 |
nicklas |
37 |
implements JarPluginInterface |
1343 |
15 Sep 05 |
nicklas |
38 |
{ |
1343 |
15 Sep 05 |
nicklas |
39 |
|
6127 |
14 Sep 12 |
nicklas |
40 |
@Override |
1372 |
21 Sep 05 |
nicklas |
41 |
public MainType getMainType() |
1343 |
15 Sep 05 |
nicklas |
42 |
{ |
1372 |
21 Sep 05 |
nicklas |
43 |
return JarPluginType.getMainType(); |
1343 |
15 Sep 05 |
nicklas |
44 |
} |
1343 |
15 Sep 05 |
nicklas |
45 |
|
6127 |
14 Sep 12 |
nicklas |
46 |
@Override |
2512 |
10 Aug 06 |
nicklas |
47 |
public boolean supportsConfigurations() |
2512 |
10 Aug 06 |
nicklas |
48 |
{ |
2512 |
10 Aug 06 |
nicklas |
49 |
return false; |
2512 |
10 Aug 06 |
nicklas |
50 |
} |
6127 |
14 Sep 12 |
nicklas |
51 |
@Override |
2512 |
10 Aug 06 |
nicklas |
52 |
public boolean requiresConfiguration() |
2512 |
10 Aug 06 |
nicklas |
53 |
{ |
2512 |
10 Aug 06 |
nicklas |
54 |
return false; |
2512 |
10 Aug 06 |
nicklas |
55 |
} |
1343 |
15 Sep 05 |
nicklas |
56 |
|
1343 |
15 Sep 05 |
nicklas |
57 |
/** |
1376 |
22 Sep 05 |
nicklas |
Just print some info to the ProgressReporter for the Request COMMAND_EXECUTE. |
1343 |
15 Sep 05 |
nicklas |
59 |
*/ |
6127 |
14 Sep 12 |
nicklas |
60 |
@Override |
1376 |
22 Sep 05 |
nicklas |
61 |
public void run(Request request, Response response, ProgressReporter progress) |
1343 |
15 Sep 05 |
nicklas |
62 |
{ |
5596 |
18 Mar 11 |
nicklas |
63 |
job.getPluginDefinition().newInstance(JarPluginInterface.class); |
1622 |
16 Nov 05 |
nicklas |
64 |
response.setDone("Ok"); |
1343 |
15 Sep 05 |
nicklas |
65 |
} |
1377 |
22 Sep 05 |
nicklas |
66 |
|
6127 |
14 Sep 12 |
nicklas |
67 |
@Override |
1377 |
22 Sep 05 |
nicklas |
68 |
public void uploadToRepository(String repositoryPath) |
1377 |
22 Sep 05 |
nicklas |
69 |
{} |
1343 |
15 Sep 05 |
nicklas |
70 |
|
1377 |
22 Sep 05 |
nicklas |
71 |
|
1343 |
15 Sep 05 |
nicklas |
72 |
} |