Clover icon

Coverage Report

  1. Project Clover database Mon Nov 11 2024 15:05:32 GMT
  2. Package jalview.ws.params

File ParamDatastoreI.java

 

Code metrics

0
0
0
1
92
20
0
-
-
0
-

Classes

Class Line # Actions
ParamDatastoreI 26 0 0
-1.0 -
 

Contributing tests

No tests hitting this source file were found.

Source view

1    /*
2    * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
3    * Copyright (C) $$Year-Rel$$ The Jalview Authors
4    *
5    * This file is part of Jalview.
6    *
7    * Jalview is free software: you can redistribute it and/or
8    * modify it under the terms of the GNU General Public License
9    * as published by the Free Software Foundation, either version 3
10    * of the License, or (at your option) any later version.
11    *
12    * Jalview is distributed in the hope that it will be useful, but
13    * WITHOUT ANY WARRANTY; without even the implied warranty
14    * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15    * PURPOSE. See the GNU General Public License for more details.
16    *
17    * You should have received a copy of the GNU General Public License
18    * along with Jalview. If not, see <http://www.gnu.org/licenses/>.
19    * The Jalview Authors are detailed in the 'AUTHORS' file.
20    */
21    package jalview.ws.params;
22   
23    import java.io.IOException;
24    import java.util.List;
25   
 
26    public interface ParamDatastoreI
27    {
28   
29    public List<WsParamSetI> getPresets();
30   
31    public WsParamSetI getPreset(String name);
32   
33    public List<ArgumentI> getServiceParameters();
34   
35    public boolean presetExists(String name);
36   
37    public void deletePreset(String name);
38   
39    /**
40    * writes or overwrites the record for a modifiable WsParamSetI entry with a
41    * given name in the datastore.
42    *
43    * @param presetName
44    * @param text
45    * @param jobParams
46    * may throw an illegal argument RunTimeException if the presetName
47    * overwrites an existing, unmodifiable preset.
48    */
49    public void storePreset(String presetName, String text,
50    List<ArgumentI> jobParams);
51   
52    /**
53    * update an existing instance with a new name, descriptive text and
54    * parameters.
55    *
56    * @param oldName
57    * @param presetName
58    * @param text
59    * @param jobParams
60    */
61    public void updatePreset(String oldName, String presetName, String text,
62    List<ArgumentI> jobParams);
63   
64    /**
65    * factory method - builds a service specific parameter object using the given
66    * data
67    *
68    * @param name
69    * @param description
70    * @param applicable
71    * URLs
72    * @param parameterfile
73    * Service specific jalview parameter file (as returned from new
74    * method)
75    * @return null or valid WsParamSetI object for this service.
76    */
77   
78    public WsParamSetI parseServiceParameterFile(String name,
79    String description, String[] serviceURL, String parameters)
80    throws IOException;
81   
82    /**
83    * create the service specific parameter file for this pset object.
84    *
85    * @param pset
86    * @return string representation of the parameters specified by this set.
87    * @throws IOException
88    */
89    public String generateServiceParameterFile(WsParamSetI pset)
90    throws IOException;
91   
92    }