Class Phrasebook
java.lang.Object
org.episteme.core.mathematics.loaders.openmath.phrasebook.Phrasebook
Defines what a minimal phrasebook should implement.
Note that this class does NOT assume anything about the protocol used between client and server. This is the responsibility of the implementing subclass. Because of this, problems with the communication should be thrown as a subclass of PhrasebookException.
- Version:
- $Version$
- Author:
- Manfred Riem (mriem@win.tue.nl)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAdds a CD to the phrasebook.An execute method.A perform method.voidRemoves a CD from the phrasebook.
-
Constructor Details
-
Phrasebook
public Phrasebook()Constructor.
-
-
Method Details
-
perform
A perform method.- Parameters:
fMethod- the type of perform.fArguments- the arguments to the perform.- Returns:
- the result.
- Throws:
PhrasebookException- thrown when a major error occurs.
-
execute
An execute method.
Note: the previous version of the library (1.2) didn't allow you to return any object as a result of a perform. To make it possible this method is the right one to implement.- Parameters:
fMethod- the type of execution.fArguments- the arguments to the execute.- Returns:
- the result.
- Throws:
PhrasebookException- thrown when a major error occurs.
-
addCD
Adds a CD to the phrasebook.- Parameters:
fName- the name of the CD.fLocation- the URL of the CD, if none is given it is assumed to be on the classpathfClassName- the Codec of the CD.- Throws:
PhrasebookException- thrown when a major error occurs.
-
removeCD
Removes a CD from the phrasebook.- Parameters:
fName- the name of the CD.- Throws:
PhrasebookException- thrown when a major error occurs.
-