To create a test recorder, you extend the recorder user interface
wizard and the four main Generic Recorder Framework (GRF) helper classes in
the org.eclipse.hyades.test.core.Recorder
extension point.
To create a new test recorder, use the Generic Recorder extension
point to perform the following steps:
Defaults exist for each of these providers. To review the defaults
and to see more details about these providers, refer to the
genericrecorder extension point documentation.
Note: Implementations of this extension point are responsible for configuring the associated recorder application
(see org.eclipse.hyades.execution.recorder.local.appadapters.IRecorderApplicationAdapter
) during initialization.
For more information, see the API documentation for org.eclipse.tptp.test.provisional.recorder.framework.IRecorderClientHelper
or org.eclipse.tptp.test.provisional.recorder.ui.wizards.IRecorderPageProvider
.
Defining the Recorder
Message Handler
The Recorder Message Provider handles incoming messages
from the Recorder Agent. The Recorder Agent controls how the recorder interprets
the application that is being recorded. It is responsible for sending messages
back to the workbench that are intercepted by the IRecorderDataProcessor
interface
where the recording file is actually written.
Some default messages
are handled in the Abstract class.
- Interface: IRecorderMessageProvider
- Abstract class: AbstractRecorderMessageProvider
Defining the Recorder Client Helper
The Generic Recorder
Framework (GRF) calls client helper methods during initialization and shutdown.
You can add custom initialization code for the extending recorder here.
- Interface: IRecorderClientHelper
- Adapter: RecorderClientHelperAdapter
Defining the Wizard Page Provider
Use the wizard
page provider to develop additional pages for the recorder wizard. This is
the only provider that exists in the org.eclipse.hyades.test.ui
project. All
the other providers are in the org.eclipse.hyades.test.core
project.
- Interface: IRecorderPageProvider
- Default: DefaultRecWizardProvider
The default produces only one page: the Select Location for Test
Suite page.
All pages served must be of type IGenericRecorderPage
.
For
each page, you can optionally define the following methods as well:
- public String getRecorderData(String key)
- public Object getRecorderObjectData(String key)
- public void saveSettings()
The default process for retrieving data from wizard page provider
is to call the getRecorderData()
methods of all pages until the key is found.
Thus, only the getRecorderData()
of the pages must be implemented.
Defining
the Exec Options Provider
Extend the Exec Options Provider to enable
agent parameters to be set before the Recorder Agent is launched. For example,
you can define JVM arguments or enable additional files to be deployed.
- Interface: IRecorderExecOptionsProvider
- Abstract class: AbstractRecorderExecOptionsProvider
After you have extended the recorder user interface wizard and
the four main GRF helper classes, your new recorder will be set to display
in the Select a Recorder Type window.