1 package jalview.ws2.operations;
3 import jalview.ws.params.ParamDatastoreI;
4 import jalview.ws2.WebServiceI;
5 import jalview.ws2.gui.MenuEntryProviderI;
8 * Operation represents an action which can be performed with a (web)service or
9 * calculator. Examples of operations are multiple sequence alignment or
10 * sequence annotation. There should be one Operation implementation for each
11 * operation that Jalview can perform on sequences or alignments. The concrete
12 * implementations may be further parameterized to alter the functionality (e.g.
13 * making the operation interactive) or restrict input data (e.g. limit to
19 public interface Operation
22 * Get the web service instance used to communicate with the web client.
24 * @return web service client instance
26 public WebServiceI getWebService();
29 * Get the name of the operation. Typically fetched from the server.
31 * @return operation name
33 public String getName();
36 * Get the description of the operation. Typically fetched from the server.
38 * @return operation description
40 public String getDescription();
43 * Get the name of the category that the operation falls into. Used to group
44 * the operations under the web services menu.
46 * @return category name
48 public String getTypeName();
51 * Get the hostname/url of the server which this operation is delegated to.
52 * Typically fetched from the accompanying web service instance.
56 public String getHostName();
59 * Check if the operation has user-customizable input parameters.
61 * @return if has parameters
63 public boolean hasParameters();
66 * Returns parameter datastore for this operations containing input parameters
67 * and available presets.
69 * @return parameter datastore of the operation
71 public ParamDatastoreI getParamStore();
74 * @return minimum accepted number of sequences
76 public int getMinSequences();
79 * @return maximum accepted number of sequences
81 public int getMaxSequences();
84 * @return whether gaps should be included
86 public boolean canSubmitGaps();
89 * @return whether works with protein sequences
91 public boolean isProteinOperation();
94 * @return whether works with nucleotide sequences
96 public boolean isNucleotideOperation();
99 * @return whether should be run interactively
101 public boolean isInteractive();
104 * Get the menu builder for this operation which will be used to construct the
105 * web services menu. The builder will be given the parent menu entry which it
106 * should attach menu items to and the current align frame.
108 * @return menu entry builder instance
110 public MenuEntryProviderI getMenuBuilder();
113 * @return whether this operation is alignment analysis
115 public boolean isAlignmentAnalysis();
118 * @return whether non-standatds symbols should be filtered out
120 public boolean getFilterNonStandardSymbols();
123 * @return whether it needs aligned sequences
125 public boolean getNeedsAlignedSequences();