1
2
3
4
5
6
7
8
9
10
11 package org.astrogrid.applications.description;
12 import org.astrogrid.applications.description.exception.ParameterNotInInterfaceException;
13 /*** Defines a calling 'interface' to an {@link org.astrogrid.applications.description.ApplicationDescription}
14 * <p>
15 * An interface comprises a name, a set of input parameters, and a set of output parameters.
16 * @author Noel Winstanley nw@jb.man.ac.uk 25-May-2004
17 * @see org.astrogrid.applications.description.ApplicationDescription
18 *
19 */
20 public interface ApplicationInterface {
21 /*** access the name of this interface */
22 public abstract String getName();
23 /*** access an array of input parameter names */
24 public abstract String[] getArrayofInputs();
25 /*** access an array of output parameter names */
26 public abstract String[] getArrayofOutputs();
27 /*** for an input parameter name (such as returned by {@link #getArrayofInputs()} etc), find the corresponding
28 * parameter descrption
29 * @param name the name of the parameter.
30 * @return the description of this parameter.
31 * @throws ParameterNotInInterfaceException if tis parametername is not present in the interface.
32 */
33 public abstract ParameterDescription getInputParameter(String name) throws ParameterNotInInterfaceException;
34 /*** determine whether this parameter is an input or output parameter in this interface */
35 public abstract ParameterDirection getParameterDirection(String name) throws ParameterNotInInterfaceException;
36 /*** @see #getInputParameter(String)*/
37 public abstract ParameterDescription getOutputParameter(String name) throws ParameterNotInInterfaceException;
38
39 /*** access the application description that this interface belongs to */
40 public ApplicationDescription getApplicationDescription();
41
42 /*** access the cardinality of a parameter */
43 public Cardinality getParameterCardinality(String name) throws ParameterNotInInterfaceException;
44
45 }
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68