The Universal Analyzer language package for a given XXX Universal Analyzer language usually contains:
- xxxMetaModel.xml
- xxxLanguagePattern.xml
- xxxInformationTracking.xml
- A set of image icons
Release | Yes/No |
---|---|
8.0.x | |
7.3.x | |
7.2.x | |
7.0.x |
xxxMetaModel.xml
This file is the metamodel that describes objects defined in the language, the categories and the properties. More detail about this file can be found in the Universal Analyzer Framework Admin Guide.
The following is an example xxxMetaModel.xml file:
<metaModel file_level="client"? file_no="2"? > <category name="KSH"? rid="0"? > <inheritedCategory name="object"/> <inheritedCategory name="identification"/> <inheritedCategory name="persistent"/> </category> <type name="kshFunction"? rid="1"? > <inheritedCategory name="UAObject"/> <inheritedCategory name="METRICABLE"/> <inheritedCategory name="APM All Artifacts"/> </type> <property name="merged" type="integer" id="102"> <description>merged</description> <attribute name="ACCESS_APPVIEW" intValue="1" /> <attribute name="ACCESS_CVS" intValue="1" /> <attribute name="ACCESS_HTML" intValue="1" /> <attribute name="INF_TYPE" intValue="37000" /> <attribute name="INF_SUB_TYPE" intValue="102" /> </property> </metaModel>
Note that:
- The file_level should be ="client" for each customer defined metamodel
- The file_level should be ="builtin" for CAST defined metamodel
When assembling several metamodel files within a single CAST Knowledge Base, always ensure that each metamodel file number 'file_no' is unique within the set. Otherwise, the installation will fail due to unique ID constraint violations.
Each category and type defined in the xxxMetaModel.xml file must be assigned an ID. Each item is given a relative ID (rid) within a particular metamodel, while each metamodel file is assigned a file number (file_no) that acts as an ID base. A range of 1000 IDs is reserved per file number. The ID of the type/category/property defined in a customer defined metamodel can be computed as follows:
ID=2000000 + file_no*1000 + RID
The maximum value of the ID should be equal to
xxxLanguagePattern.xml
This file is the language pattern file that describes how to recognize objects within source files using regular expressions. More detail about this file can be found in the Universal Analyzer Framework Admin Guide.
xxxInformationTracking.xml
This file is an optional file used to reduce the number of incorrect links detected during the analysis of your language with the CAST Universal
Analyzer. More detail about this file can be found in the Universal Analyzer Framework Admin Guide.
Set of image icons
These images are associated with the language's objects - icons are located in a "Res" subdirectory (a subdirectory of the main package directory). The title of the icon file must match the name of the object. More detail about this can be found in the Universal Analyzer Framework Admin Guide.