1.0 Introduction
2.0 Installation
3.0 Generation
4.0 Maintenance
5.0 Documentation
Eclipse Test and Performance Tools Platform Project
Getting Started with
generating code for TPTP EMF models
Author: Alex Nan
Author: Paul Slauenwhite
Last
Getting Started with
generating code for TPTP EMF models
The
following docu
Table of Contents:
The
TPTP models are composed of the Trace, Test, Statistical, and Probekit
models. They are based on EMF and
generated from ECore model files.
The
TPTP models are located in the org.eclipse.tptp.platform.models
plug-in under the following source trees:
·
Trace
(src-trace).
·
Test
(src-test).
·
Statistical
(src-statistical).
·
Probekit
(src-probekit).
The
deprecated Log and Trace Analyzer models are composed of the Consu
The
deprecated Log and Trace Analyzer models are located in the org.eclipse.tptp.platform.models.lta
plug-in under the following source trees:
·
Consu
·
Generic
Log Adapter (src-gla).
·
Old
Symptom model (Symptom 0.1) (src-sdb).
·
New
Symptom model (Symptom 2.0) (src-symptom).
The
TPTP models and deprecated Log and Trace Analyzer models requires the org.eclipse.tptp.platform.models.hierarchy
plug-in (src-hierarchy source tree), which defines
the hierarchical structure used to organize and interact with the various
models.
1 The deprecated Producer Common Base
Event model is located in the org.eclipse.tptp.platform.logging.events
plug-in under the following source trees:
·
EMF
(src.cbe101).
·
Java
(src.events).
·
Native
(src-native).
1. Download and install the following
runti
· TPTP 4.6 or above.
· Eclipse 3.5 or above.
· EMF/XSD 2.5 or above.
2. Add a JRE 1.5 or above to the system
path.
3. Start Eclipse with the -clean
option.
3.0
Generation
1. Check out the model plug-ins from CVS
(HEAD).
2. Open the Java Perspective.
3. Open the Properties View.
4. Open each of the EMF ECore (*.ecore) files (see <TPTP
model source tree>/model) in the EMF ECore
editor.
5. Right-click the root node in the tree
and select Validate.
6. Correct any validation errors.
7. Open each of the EMF generator model
(*.genmodel)
files (see <TPTP model source
tree>/model) in the EMF Generator editor.
8. Select the root node in the tree.
9. Deselect the Show Categories toolbar
button in the Properties View.
10. Verify that the following properties:
·
Code
Formatting = false
·
Compliance
Level = 5.0
·
Copyright
Fields = false
·
Dynamic
Templates = false
·
Feature
Delegation = None
·
Generate
Schema = false
·
Model
Directory = /<TPTP model
plug-in>/<TPTP model source tree>
·
Runtime
Version = 2.5
·
Template
Directory = <blank>
11. Right-click the root node in the
tree, select Generate Model Code.
12. Correct any compilation errors.
13. Complete the following manual
changes:
a) Delete the following packages:
·
/org.eclipse.tptp.platform.models/src-test/org.eclipse.hyades.models.test.data
·
/org.eclipse.tptp.platform.models/src-test/org.eclipse.hyades.models.test.data.impl
·
/org.eclipse.tptp.platform.models/src-test/org.eclipse.hyades.models.test.data.util
b) Change all references to org.eclipse.emf.ecore.impl.EObjectImpl.eContainerFeatureID
to invocations of org.eclipse.emf.ecore.impl.EObjectImpl.eContainerFeatureID() (see defect #262424).
c) Confirm the following features are NOT
unique:
·
TRCAnnotation_values
·
TRCThread_initialInvocations
·
CBEDefaultEle
·
SymptomCatalog_SymptomDefinition
·
SymptomCatalog_SymptomRule
·
SymptomCatalog_Sympto
14. Organize the imports for the TPTP
model plug-ins.
15. Synchronize the TPTP model plug-ins
with CVS.
16. Correct any overwritten methods
(tagged with @generated NOT).
17. Update the copyright
date for all updated files.
18. Check out the TPTP plug-ins from CVS
(HEAD) using the TPTP
4.6 Project File Set (Developers).
19. Correct any compilation errors.
20. Launch a self-hosted instance of
Eclipse and test the core TPTP use cases (for example, probe instru
21. Create a patch of the changes and
attach the patch to the Bugzilla for regenerating the
TPTP Models.
22. Check the patch into CVS
(HEAD).
4.0 Maintenance
The TPTP Models should be regenerated after any model change. In addition, the TPTP Models should be
regenerated once per release during the last week of develop
For more
information on EMF code generation, see EMF
tutorials.
For more
information on the TPTP models, see TPTP
models.
Copyright © 2008, 2009 IBM Corporation and
others. All rights reserved. This document and the accompanying materials are
made available under the terms of the Eclipse Public License v1.0 which
accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html
Author: