Extending code generation

The code generation subsystem maps Load Test Behavior Model (LTBM) elements to objects of the code generation element model (IModelElement), which in turn are mapped to objects of its ILanguageElement class. As a result, a language element tree is created that contains all equivalent elements of the behavior model test element tree and at the same time determines the structure of code to be generated.

Before you begin

The language elements are typed, named, and have appropriate templates defined for them. Performance testing code generation takes place entirely within the Eclipse workbench. The Eclipse extension point mechanism is used for code generation extensibility to accommodate new protocols.

About this task

The com.ibm.rational.test.lt.codegen.core plug-in supports code generation for the generic Load Test script extending the com.ibm.rational.test.lt.execution.core.impl.LTTestScript class and generic test elements such as loops, containers, transactions, data pools, generic content verification points, data sources and substituters, and generic custom code. Specific protocols such as the com.ibm.rational.test.lt.codegen.http plug-in are implemented as extensions of the com.ibm.rational.test.lt.codegen.core plug-in. The com.ibm.rational.test.lt.codegen.schedule plug-in generates schedules implemented on top of com.ibm.rational.test.lt.codegen.core functionality.

For the code generation extension sample, see the plug-in com.ibm.rational.test.lt.sdksamples.codegen.socket.

The Javadoc for the test execution services interfaces and classes can be accessed from the product by clicking Help > Help ContentsIBM Rational Performance Tester API Reference.