- java.lang.Object
-
- ij.plugin.filter.PlugInFilterRunner
-
- All Implemented Interfaces:
DialogListener,java.lang.Runnable
public class PlugInFilterRunner extends java.lang.Object implements java.lang.Runnable, DialogListener
-
-
Constructor Summary
Constructors Constructor Description PlugInFilterRunner(java.lang.Object theFilter, java.lang.String command, java.lang.String arg)The constructor runs a PlugInFilter or ExtendedPlugInFilter by calling its setup, run, etc.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleandialogItemChanged(GenericDialog gd, java.awt.AWTEvent e)The listener to any change in the dialog.intgetSliceNumber()Return the slice number currently processed by the calling thread.voidrun()The dispatcher for the background threadsvoidsetDialog(GenericDialog gd)
-
-
-
Constructor Detail
-
PlugInFilterRunner
public PlugInFilterRunner(java.lang.Object theFilter, java.lang.String command, java.lang.String arg)The constructor runs a PlugInFilter or ExtendedPlugInFilter by calling its setup, run, etc. methods. For details, see the documentation of interfaces PlugInFilter and ExtendedPlugInFilter.- Parameters:
theFilter- The PlugInFilter to be runcommand- The command that has caused running the PlugInFilterarg- The argument specified for this PlugInFilter in IJ_Props.txt or in the plugins.config file of a .jar archive conatining a collection of plugins.argmay be a string of length zero.
-
-
Method Detail
-
getSliceNumber
public int getSliceNumber()
Return the slice number currently processed by the calling thread.- Returns:
- The slice number. Returns -1 on error (when not processing).
-
run
public void run()
The dispatcher for the background threads- Specified by:
runin interfacejava.lang.Runnable
-
setDialog
public void setDialog(GenericDialog gd)
-
dialogItemChanged
public boolean dialogItemChanged(GenericDialog gd, java.awt.AWTEvent e)
The listener to any change in the dialog. It is used for preview. It is invoked every time the user changes something in the dialog (except OK and cancel buttons), provided that all previous listeners (parameter checking) have returned true.- Specified by:
dialogItemChangedin interfaceDialogListener- Parameters:
e- The event that has happened in the dialog. This method may be also called with e=null, e.g. to start preview already when the dialog appears.gd- A reference to the GenericDialog.- Returns:
- Always true. (The return value determines whether the dialog will enable the OK button)
-
-