com.ibm.are.plugin
Interface Plugin

All Superinterfaces:
com.ibm.are.core.Element
All Known Implementing Classes:
BasePlugin

public interface Plugin
extends com.ibm.are.core.Element

The Plugin interface represents the basic operations and features that must be implemented for a class to be considered a plugin by the Application Runtime Expert. Any class that implements the Plugin interface can be automatically detected and instantiated by the Application Runtime Expert. Any plugin can receive input arguments via the plugins.xml configuration file. This support is built into the runtime and can be used without writing any additional code.

Version:
1.0
Author:
IBM

Field Summary
static java.lang.String COPYRIGHT
          Copyright for class bytecode
 
Method Summary
 java.util.logging.Logger getLogger()
          Retrieves the logger associated with the plugin
 PluginReporting getReporter()
          Retrieves the reporter for the plugin
 java.io.PrintWriter getStandardOut()
          Retrieves the standard output writer for the plugin.
 void init(java.util.List initArgs)
          All plugin initialization is done in this method.
 ResultInfo result()
          Retrieves the result of the plugin being run.
 void run()
          Runs the plugin.
 
Methods inherited from interface com.ibm.are.core.Element
getCommonName, getDescription, getElementData, getVersion, setElementData
 

Field Detail

COPYRIGHT

static final java.lang.String COPYRIGHT
Copyright for class bytecode

See Also:
Constant Field Values
Method Detail

init

void init(java.util.List initArgs)
All plugin initialization is done in this method. The runtime will always invoke this method prior to invoking the run() method. This method will only be invoked once per instance by the runtime.

Parameters:
initArgs - Initialization arguments. Currently the runtime does not pass any arguments upon initialization, so this list will always be empty.

run

void run()
Runs the plugin. This method will only be invoked once per instance by the runtime.


result

ResultInfo result()
Retrieves the result of the plugin being run. The type of result returned by a plugin is implementation dependent.

Returns:
The result of the plugin being run

getLogger

java.util.logging.Logger getLogger()
Retrieves the logger associated with the plugin

Returns:
The logger

getStandardOut

java.io.PrintWriter getStandardOut()
Retrieves the standard output writer for the plugin. This writer is typically mapped to standard output, aka the System.out output stream. But this is not always the case. Thus, plugin authors should always write to the standard output writer provided by this method rather than writing directly to System.out.

Returns:
The standard output writer

getReporter

PluginReporting getReporter()
Retrieves the reporter for the plugin

Returns:
The reporter
See Also:
PluginReporting