Interface Executable
- All Superinterfaces:
Loadable
- All Known Implementing Classes:
Help,InfoExecutable
The Executable interface extends Loadable, meaning it can be loaded into the system
as part of a plugin. Implementations of this interface are expected to provide specific behavior
for execution within the application.
All Executable tasks can be executed within the "Plugins" section of the main application.
A button labeled Executables will appear next to your plugin. When clicked, a window will open,
displaying buttons for each executable task. The button labels are taken from the name() method,
while the corresponding actions are triggered by calling execute().
Executable names are allowed to overlap with other tasks, if necessary, as the name serves merely
as an identifier. Additionally, the name "About" is reserved by the system and will create a special
button next to the plugin's name, which opens a page with information about the plugin.
If you need to create an "About" button, you can easily do so by extending the InfoExecutable
abstract class, which provides a simple implementation for creating informational pages about the plugin.
Plugins can implement this interface to provide custom executable tasks that can be triggered or scheduled by the system. These tasks could range from simple operations to complex workflows.
- See Also:
-
Method Summary
-
Method Details
-
name
String name()Returns the name of this executable task.This name can be used to identify the executable task within the system. It should be unique within the plugin to avoid confusion with other tasks. However, multiple tasks may share the same name if needed.
- Returns:
- the name of the executable task
-
execute
void execute()Executes the task or action defined by this executable.This method contains the logic that is triggered when the executable is run. The exact behavior depends on the plugin's implementation of this interface.
-