|Java Interface|| |
|Base class|| |
StepDialogInterface is the Java interface that implements the settings dialog of a partitioner plugin.
Maintain the Dialog for Partitioner Settings
dialog class is responsible for constructing and opening the settings dialog for the partitioner. When you open the partitioning settings in Spoon, the system instantiates the
dialog class passing in a
StepPartitioningMeta object. Retrieve the
Partitioner object by calling
getPartitioner() and call the
open() method on the dialog. SWT is the native windowing environment of Spoon and the framework used for implementing dialogs.
public String open()
This method returns only after the dialog has been confirmed or cancelled. The method must conform to these rules.
- If the dialog is confirmed
Partitionobject must be updated to reflect the new settings
- If you changed any settings, the
StepPartitioningMetaobject Changed flag must be set to
open()returns the name of the step to which the partitioning is applied—use the
stepnamefield inherited from
- If the dialog is cancelled
Partitionobject must not be changed
StepPartitioningMetaobject Changed flag must be set to the value it had at the time the dialog opened
StepPartitioningMeta object has an internal Changed flag that is accessible using
setChanged(). Spoon decides whether the transformation has unsaved changes based on the Changed flag, so it is important for the dialog to set the flag appropriately.
The sample Partitioner plugin project has an implementation of the dialog class that is consistent with the these rules and is a good basis for creating your own dialogs.