jwo.landserf.script
Interface Scriptable
- All Known Implementing Classes:
- CentroidThread, CombineThread, ContourThread, DemToTinThread, FracSurfaceThread, JoinVectorThread, OpenThread, PeakClassificationThread, PitRemovalThread, PointDensityThread, ProjectionThread, RectifyThread, SaveThread, SelectVectorThread, SimplifyThread, SurfNetworkThread, SurfParamThread, TinToDemThread, VoidRemovalThread
public interface Scriptable
Indicates that the class can be called via a scipting command.
- Version:
- 2.3, 31st October, 2005.
- Author:
- Jo Wood
Method Summary |
boolean |
doCommand(LSCommand command)
Should perform the scripting command with the parameter values supplied
by the given command object. |
LSCommand |
getCommand()
Should report the syntax required to issue the scripting command. |
GISFrame |
getGISFrame()
Should retrieve the GISFrame that can be used for storing multiple spatial objects. |
Object |
getReturnedObject()
Can return an object that has been created as a result of the scriptable
command being issued. |
getCommand
LSCommand getCommand()
- Should report the syntax required to issue the scripting command.
- Returns:
- Command syntax.
doCommand
boolean doCommand(LSCommand command)
- Should perform the scripting command with the parameter values supplied
by the given command object.
- Parameters:
command
- Command containing parameter values.
- Returns:
- True if command completed successfully. If false, it should indicate
some kind of problem. The details of the problem would usually be stored
in a GISFframe.
getReturnedObject
Object getReturnedObject()
- Can return an object that has been created as a result of the scriptable
command being issued. If command has yet to be issued or if it does not involve
the creation of a new data, this should return null. Many commands
will involve the creation of a single RasterMap or VectorMap and should therefore
use this method to retrieve the result. For commands that create more than one new
spatial object, these can be retrieved from the
gisFrame
via getGISFrame()
.
- Returns:
- New object or null if one has not been created.
getGISFrame
GISFrame getGISFrame()
- Should retrieve the GISFrame that can be used for storing multiple spatial objects. If
the script creates 1 or less spatial objects, there should not normally be any need to
call this method. Since scriptable commands do not usually use a graphical user interface,
this will often be in the form of a non-graphical
SimpleGISFrame
which is
essentially a collection of spatial objects.
- Returns:
- GISFrame storing spatial objects.
Copyright Jo Wood, 1996-2009, last modified, 17th April, 2009