public interface Algorithm extends Parameterizable
Specifies the requirements for any algorithm that is to be executable by the main class.
Any implementation needs not to take care of input nor output, parsing and so on. Those tasks are performed by the framework. An algorithm simply needs to ask for parameters that are algorithm specific.
Note: Any implementation is supposed to provide a constructor without parameters (default constructor).
Modifier and Type | Method and Description |
---|---|
TypeInformation[] |
getInputTypeRestriction()
Get the input type restriction used for negotiating the data query.
|
Result |
run(Database database)
Runs the algorithm.
|
Result run(Database database) throws IllegalStateException
database
- the database to run the algorithm onIllegalStateException
- if the algorithm has not been initialized
properly (e.g. the setParameters(String[]) method has been failed
to be called).TypeInformation[] getInputTypeRestriction()