Defining how a recorder can record a client
To declare that a recorder can record a client:
- Declare a new recorder-client binding in the plugin.xml file by using the com.ibm.rational.test.lt.recorder.core.recorderClientBinding extension point.
- Specify the IDs of the recorder and the client that are compatible.
- Optionally, declare a client decorator. A client decorator is a class that modifies a client so that it can be recorded by the recorder.
To implement a client decorator, define an implementation of the com.ibm.rational.test.lt.recorder.core.extensibility.IClientDecorator class.
The implementation has two main methods: decorate() and undecorate(). The decorate() method is called when the recorder starts running, but before the client is launched. The undecorate() method is called after the client is closed, but before the recorder is stopped.
The decorator can interact with the recorder delegate and the client delegate by setting or getting properties from them. The methods for doing so are available in the decorator context. The client and the recorder must support the properties.
Typically, you extend the BaseClientDecorator class rather than directly implementing the IClientDecorator class. The base abstract class provides a basic behavior for most methods. With that class, you can override specifically those methods that you must override.