Escolar Documentos
Profissional Documentos
Cultura Documentos
03
August 2010
www.bmc.com
Telephone
Fax
Fax
If you have comments or suggestions about this documentation, contact Information Design and Development by email at
doc_feedback@bmc.com.
Customer Support
You can obtain technical support by using the Support page on the BMC Software website or by contacting Customer
Support by telephone or email. To expedite your inquiry, please see Before Contacting BMC Software.
Support website
You can obtain technical support from BMC Software 24 hours a day, 7 days a week at
http://www.bmc.com/support. From this website, you can:
Read overviews about support services and programs that BMC Software offers.
Find the most current information about BMC Software products.
Search a database for problems similar to yours and possible solutions.
Order or download product documentation.
Report a problem or ask a question.
Subscribe to receive email notices when new product versions are released.
Find worldwide BMC Software support center locations and contact information, including email addresses, fax
numbers, and telephone numbers.
Product information
Product name
Product version (release number)
License number and password (trial or permanent)
Machine type
Operating system type, version, and service pack
System hardware configuration
Serial numbers
Related software (database, application, and communication) including type, version, and service pack or
maintenance level
Messages received (and the time and date that you received them)
Product error messages
Messages from the operating system, such as file system full
Messages from related software
In the United States and Canada, call 800 537 1813. Outside the United States and Canada, contact your local support
center for assistance.
Contents
BMC Atrium Core documentation
13
Chapter 1
17
22
22
23
Chapter 2
25
Getting started
Contents
18
19
20
20
21
26
29
29
29
30
34
34
35
35
35
35
36
36
36
36
37
38
39
39
40
43
43
44
Chapter 3
45
C API functions
65
CMDBCreateMultipleAttributes function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBCreateMultipleInstances function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBDeleteAttribute function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBDeleteClass function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBDeleteInstance function. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBDeleteMultipleInstances function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBEndBulkEntryTransaction function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBExpandParametersForCI function. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return Values. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBExportData function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBExportDef function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGetAttribute function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGetClass function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Contents
82
82
82
84
85
85
85
85
86
86
86
86
87
87
87
87
88
88
88
88
89
89
89
89
90
90
90
90
91
91
91
91
92
92
92
93
93
93
93
93
94
94
94
95
97
97
97
97
CMDBGetVersions function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphQuery function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkBegin function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkEnd function. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input argument . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkNext function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBImportData function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBImportDef function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBInitialization function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input argument . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryByPath function. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBRunQualificationForCI function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBSetAttribute function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBSetClass function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Input arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Return value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Contents
115
115
116
116
116
116
117
118
118
118
118
119
119
119
119
119
120
120
120
120
121
121
121
121
122
122
122
122
123
123
123
123
124
124
124
124
125
125
125
125
126
126
126
128
128
128
129
131
141
CMDBExportItemList structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBExportItemStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBFederatedActivateInfo structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBFederatedARInfo structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGetObjectList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGetObjectStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGetRelationList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGetRelationStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphAdjacentList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphAdjacentStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkObjectList structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkObjectStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkQueryStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkRelation structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkRelationList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkResultStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkSelectorAndFilterList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkSelectorAndFilterStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBGraphWalkStateStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBImportItem structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBImportItemList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBImportItemStruct structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBIndexList structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBIndexStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBInstanceList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBInstanceStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBItemTypeAttribute structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBItemTypeClass structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBNestedQueryStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQualifierStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryArithOpStruct structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryAttributeName structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryCardinality . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryObject structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryObjectList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryObjectRelationship structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryObjectSelectorList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryObjectSelectorStruct structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryQualifierAndOrStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryQualifierSetOpStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryQualifierSimpleOpStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryQualifierStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryQualifierValueSetStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryQualifierValueStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryResultGraph. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQuerySortStruct . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQuerySortList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
CMDBQueryStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Contents
159
159
161
162
163
163
163
164
164
165
165
166
166
167
167
169
170
171
172
173
174
175
175
176
177
178
178
179
179
179
180
181
181
182
183
184
186
186
187
188
188
189
190
192
193
194
195
197
197
198
11
CMDBGraphQueryResult . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200
CMDBStdEdgeResult . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200
CMDBEdgeListList. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201
CMDBNodeList. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201
CMDBNodeListList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202
CMDBRelationshipResult . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202
CMDBRelationshipResultList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203
CMDBREClassQualList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203
CMDBREClassQualStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 204
CMDBREDatasetList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 204
CMDBREDatasetPair structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205
CMDBREJobRunInfo structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205
CMDBREJobRunInfoList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 206
CMDBSortList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 206
CMDBSortStruct structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207
CMDBUIComponentInfo structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207
CMDBUIComponentResult structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211
CMDBUIComponentResultList structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212
CMDBVersionInfo structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212
CMDBVersionInfoList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
CMDBWeakPropagatedAttrs structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
CMDBWeakPropagatedAttrsList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 214
CMDBXMLExportItemList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 214
CMDBXMLImportItemList structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215
Appendix A
cmdbdriver commands
217
12
225
This section describes the complete set of BMC Atrium Core documentation,
including manuals, help systems, videos, and so on.
Unless otherwise noted, documentation is available on the BMC Atrium Core
documentation media (DVD or Electronic Product Download bundle) and on the
BMC Customer Support site, free of charge, at http://www.bmc.com/support.
To find this documentation on the BMC Customer Support site, choose Product
Documentation > Supported Product A-Z List > BMC Atrium CMDB Enterprise
Manager > 7.6.03.
Title
Description
Audience
BMC Atrium CMDB 7.6.03 Information about setting permissions, configuring Configuration managers,
Administrator's Guide
federation, modifying the data model, configuring application administrators,
an impact model, and other administrative tasks in and asset analysts.
BMC Atrium CMDB.
BMC Atrium CMDB 7.6.03 Hierarchical diagram of all classes in the Common Configuration managers,
Common Data Model
Data Model (CDM) including unique attributes and application administrators,
Diagram
applicable relationships.
and asset analysts.
BMC Atrium CMDB
7.6.03 Data Model Help
Configuration managers,
application administrators,
and asset analysts.
13
Title
Description
Audience
Configuration managers,
application administrators,
asset analysts, and users
that work with CIs and need
to understand the
Note: This Help is provided in HTML and is available
relationships that exist
through the Help links in the BMC Atrium CMDB
within BMC Atrium CMDB.
user interface. It is not available on the BMC
Customer Support site.
BMC Atrium CMDB 7.6.03 Information about using BMC Atrium CMDB,
User's Guide
including searching for and comparing CIs and
relationships, relating CIs, viewing history, running
impact simulations, and viewing federated data.
Configuration managers,
application administrators,
and asset analysts.
Application administrators
and programmers.
Application administrators.
Application programmers.
14
Everyone.
Title
Description
Audience
Configuration managers,
application administrators,
and asset analysts.
BMC Atrium Integration Help for using and configuring BMC Atrium
Engine 7.6.03 Online Help Integration Engine.
15
Title
Description
Audience
Configuration managers,
application administrators,
and asset analysts.
16
Chapter
Chapter 1
17
BMC Service
Impact Manager
Atrium Console
BMC
Remedy
User
Web
Client
BMC Atrium
Discovery
.Net
Client
Atrium Explorer
BMC
Remedy
User
Web
Client
CMDB Java
API
Normalization
Engine
CMDB C
API
Reconciliation
Engine
AR System
API
Database
This guide describes the C API. For more information about the BMC Atrium
CMDB Java API, see BMC Atrium CMDB 7.6.03 Javadoc Help. For more
information about web services APIs, see BMC Atrium Core 7.6.03 Web Services
Help.
18
Contains data structures that store both simple and complex information. A
simple data structure serves as the primary building block for a complex data
structure.
Includes a set of free functions that you can use to deallocate memory.
Includes a set of copy functions that you can use to make copies of BMC Atrium
CMDB C API structures
Microsoft Windows
Linux
Sun Solaris
IBM AIX
Hewlett Packard HP-UX
Hewlett Packard HP-Itanium
Chapter 1
19
For more information about the web services API, see the BMC Atrium Core 7.6.03
Web Services Help.
20
The BMC Atrium Web Services Infrastructure component has been divided into
the components shown in Table 1-1.
Table 1-1: BMC Atrium Web Services Infrastructure components
Component
Includes
Web Services
Infrastructure
The TIBCO Runtime UDDI Server is a registry through which web services are
published and clients find and invoke the services. It is implemented as a
collection of web services and is deployed as a WAR file (uddi.war) on the web
application server.
API version
Chapter 1
21
BMC Atrium CMDB 7.6.03 User's GuideFor user tasks such as, viewing CI
history, viewing CI and relationship classes, and comparing instances.
When to use the BMC Atrium CMDB API and the BMC Atrium Core
Console
Table 1-3 outlines the scenarios in which you should use APIs or the BMC Atrium
Core Console.
Table 1-3: API programming and BMC Atrium Core Console scenarios (Sheet 1 of 2)
Scenario
22
API programming
Comparison between BMC Atrium CMDB API programming and using the BMC Atrium Core Console
Table 1-3: API programming and BMC Atrium Core Console scenarios (Sheet 2 of 2)
Scenario
BMC Atrium Core Console and BMC Atrium CMDB API terminology
The BMC Atrium Core Console and the APIs use different terms for specific tasks,
as shown in Table 1-4.
Table 1-4: BMC Atrium Core Console and API terminology
BMC Atrium Core Console term
API term
search/find
getList/find/query
create
create
modify
set/update
view/display
get
Chapter 1
23
24
Chapter
Getting started
This section provides the information that you need to get started with developing
your BMC Atrium CMDB APIs.
The following topics are provided:
25
Supported?
7.6.03
7.6.03
Yes
7.6.03
7.6.00
Yes
(Not supported on 64-bit
Windows platform)
7.6.03
7.5.00
Yes
(Not supported on 64-bit
Windows platform)
7.6.03
2.1.00
Yes
(32-bit Windows only.
Not supported on 64-bit
UNIX platforms.)
7.6.03
2.0.1
Yes
(32-bit Windows only.
Not supported on 64-bit
UNIX platforms.)
7.5.00
7.6.03
No
7.5.00
7.6.00
Yes
7.5.00
7.5.00
Yes
7.5.00
2.1.00
Yes
(32-bit Windows only.
Not supported on 64-bit
UNIX platforms.)
7.5.00
2.0.1
Yes
(32-bit Windows only.
Not supported on 64-bit
UNIX platforms.)
26
7.1.00
7.6.03
No
7.1.00
7.6.00
No
7.1.00
7.5.00
No
Table 2-1: Compatibility between BMC Atrium CMDB and BMC Remedy AR System servers
(Sheet 2 of 2)
BMC Remedy AR System server
Supported?
7.1.00
2.1.00
Yes
7.1.00
2.0.1
Yes
7.0.1
7.6.03
No
7.0.1
7.6.00
No
7.0.1
7.5.00
No
7.0.1
2.1.00
No
7.0.1
2.0.1
Yes
A BMC Atrium CMDB client is any application that uses the BMC Atrium CMDB
API. If you plan to develop a BMC Atrium CMDB client, reference Table 2-2, which
provides a compatibility matrix for versions of BMC Atrium CMDB servers and
clients. The platform version (including operating system and either 32-bit or 64bit architecture) of the BMC Atrium CMDB client is independent of the BMC
Atrium CMDB server. For example, the 32-bit Windows version of the client can
communicate with the 64-bit Linux version of the server. The supported
combinations listed apply to all platforms.
27
Table 2-2: Compatibility between BMC Atrium CMDB clients and servers (Sheet 1 of 2)
BMC Atrium CMDB Client BMC Atrium CMDB Server Supported?
28
7.6.03
7.6.03
Yes
7.6.03
7.6.00
7.6.03
7.5.00
7.6.03
2.1.00
7.6.03
2.0.1
7.6.00
7.6.03
7.6.00
7.6.00
Yes
7.6.00
7.5.00
7.6.00
2.1.00
7.6.00
2.0.1
7.5.00
7.6.03
7.5.00
7.6.00
7.5.00
7.5.00
Yes
7.5.00
2.1.00
7.5.00
2.0.1
2.1.00
7.6.03
2.1.00
7.6.00
2.1.00
7.5.00
2.1.00
2.1.00
Yes
2.1.00
2.0.1
2.0.1
7.6.03
2.0.1
7.6.00
2.0.1
7.5.00
Table 2-2: Compatibility between BMC Atrium CMDB clients and servers (Sheet 2 of 2)
BMC Atrium CMDB Client BMC Atrium CMDB Server Supported?
2.0.1
2.1.00
No
2.0.1
2.0.1
Yes
Contents
ar.h
cmdb.h
BMC Atrium Core C API data type and structure definitions, size
limits, and constant definitions.
arerrno.h
arextern.h
arfree.h
cmdbfree.h
arstruct.h
29
NOTE
The SDK contains files that are not listed in Table 2-4. Those files are required for
the Java API or for working with the cmdbdriver program, but are not required to
create a C API program.
Table 2-4: C API library files (Sheet 1 of 4)
30
Platform
Files
Microsoft Windows
32-bit
arapi7603_build001.dll
arcatalog_eng.dll
arjni7603_build001.dll
arrpc7603_build001.dll
arutiljni7603_build001.dll
arutl7603_build001.dll
cmdbapi7603.dll
icudt32.dll
icuinbmc32.dll
icuucbmc32.dll
mfc71.dll
msvcp71.dll
msvcr71.dll
64-bit
arapi7603_build001_win64.dll
arcatalog_eng.dll
arjni7603_build001_win64.dll
arrpc7603_build001_win64.dll
arutiljni7603_build001.dll
arutl7603_build001_win64.dll
arxmlutil7603_build001_win64.dll
cmdbapi7603_win64.dll
icudt32.dll
icuinbmc32_win64.dll
icuucbmc32_win64.dll
mfc71.dll
msvcp71.dll
msvcr71.dll
Files
Solaris
32-bit
libarjni7603_build001.so
libarutiljni7603_build001.so
libcmdbapi7603.so
libcmdbjni7603.so
libjlicapi7603_build001.so
libicudatabmc.so.32
libicui18nbmc.so.32
libicuucbmc.so.32
64-bit
libarjni7603_build001.so
libarutiljni7603_build001.so
libcmdbapi7603_solsp64.so
libcmdbjni7603.so
libjlicapi7603_build001.so
libicudatabmc_solsp64.so.32
libicui18nbmc_solsp64.so.32
libicuucbmc_solsp64.so.32
AIX
32-bit
libarjni7603_build001.a
libarutiljni7603_build001.a
libcmdbjni7603.a
libcmdbapi7603.a
libicudatabmc32.a
libicui18nbmc32.a
libicuucbmc32.a
libjlicapi7603_build001.a
64-bit
libarjni7603_build001.a
libarutiljni7603_build001.a
libcmdbjni7603_build001.a
libcmdbapi7603_build001_aixp64.a
libicudatabmc_aixp6432.a
libicui18nbmc_aixp6432.a
libicuucbmc_aixp6432.a
libjlicapi7603_build001.a
31
32
Platform
Files
HP-UX
32-bit
libicudatabmc.sl.32
libicui18nbmc.sl.32
libicuucbmc.sl.32
libarjni7603_build001.sl
libarutiljni7603_build001.sl
libcmdbapi7603.sl
libcmdbjni7603.sl
libjlicapi7603_build001.sl
64-bit
libicudatabmc_hppa64.sl.32
libicui18nbmc_hppa64.sl.32
libicuucbmc_hppa64.sl.32
libarjni7603_build001.sl
libarutiljni7603_build001.sl
libcmdbjni7603.sl
libjlicapi7603_build001.sl
Linux
32-bit
libicudatabmc.so.32
libicui18nbmc.so.32
libicuucbmc.so.32
libarjni7603_build001.so
libarutiljni7603_build001.so
libcmdbapi7603.so
libcmdbjni7603.so
libjlicapi7603_build001.so
64-bit
libicudatabmc_lx64.so.32
libicui18nbmc_lx64.so.32
libicuucbmc_lx64.so.32
libarjni7603_build001.so
libarutiljni7603_build001.so
libcmdbapi7603_lx64.so
libcmdbjni7603.so
libjlicapi7603_build001.so
Files
HP-Itanium
33
For Microsoft Windows 32-bit you need Microsoft Visual C++ version 7.0 or
later. For Microsoft Windows 64-bit, you need Microsoft Visual C++ 9.0. to
compile your C API programs.
NOTE
If you develop C++ clients that run on HP computers using the BMC Atrium
CMDB C API, compile your code with the __HPACC_THREAD_SAFE_RB_TREE flag
enabled. This operation is necessary because the libraries that the tree header file
uses, which includes tree.cc, are not thread safe.
34
Platform
Links
Windows
cmdbapi7603.dll
Solaris, Linux
libcmdbapi7603.so
HP-UX
libcmdbapi7603.sl
HP-Itanium
libcmdbapi7603_hpia32.sl
libcmdbapi7603_hpia64.sl
AIX
libcmdbapi7603.a
Description
com.bmc.arsys.api.*;
com.bmc.cmdb.api.*;
java.util.*;
35
36
37
Description
Usage
-u user
cmdbdriver.exe -u Demo
-a authorString
cmdbdriver.exe -a
ARSystemAuthorizationSt
ring
-p password
cmdbdriver.exe -u Demo
-a -p
-1 locale
-s server
cmdbdriver.exe -u Demo
-a -p -s localhost
-x inputFileFullpath
cmdbdriver.exe -x
cmdb.in
-t portNumber
cmdbdriver.exe -t 8080
-q quietModeNumber
38
0: NO_SUPPRESSION
1: SUPPRESS_RESULTS
2: SUPPRESS_HEADERS
4: SUPPRESS_PROMPTS
8: SUPPRESS_MENU
16: SUPPRESS_ERRORS
32: SUPPRESS_WARNINGS
64: SUPPRESS_TIME
128: SUPPRESS_DATE
Windows
Navigate to C:\Program
Double-click cmdbdriver.exe.
UNIX
Navigate to AtriumCoreInstallationDirectory/cmdb/sdk/bin.
Type the command ./cmdbdriver.sh.
Shared libraries required by the cmdbdriver program are added to the library
path for the cmdbdriver session. The cmdbdriver program sets the library
path variable according to your UNIX platform:
UNIX platform
Variable name
LD_LIBRARY_PATH
HP-UX
SHLIB_PATH
AIX
LIBPATH
39
NOTE
Use the help command (h or ?) to display cmdbdriver commands.
6 When you are finished using the cmdbdriver, type e or q to exit the program.
TIP
To execute the commands stored in a file, either use the inline parameters (see
Running cmdbdriver from the command line on page 39) or copy and paste the
commands at the cmdbdriver prompt.
40
BMC_Component is the relationship between these CIs and their classes within the
BMC.CORE namespace. The blank line in this example accepts the default value for
the Number of characteristics parameter. The default for this parameter is set to
0 (none).
MyServer
cqq
PersonQueryQual
41
4
1
Name
1
4
Daisy
cqobj
BMC.CORE
BMC_Person
PersonQueryObj
1
1
PersonQueryQual
qbp
BMC.ASSET
1
PersonQueryObj
1
PersonQueryObj
1
Name
1
BMC_Person
PersonQueryObj
Name
1
1
2
In the preceding example, the script first creates a query qualifier using the cqq
command. The alias for the query qualifier is specified as PersonQueryQual. The
query qualification in this example is a Simple query that searches for an instance
of BMC_Person class with Name = Daisy in the BMC.CORE namespace.
NOTE
A query qualifier can be reused any number of times within a specific session.
After a cmdbdriver session terminates, the query qualifier that you created within
the session is no longer available.
The value of 1 in the query qualification instructs the query to perform an Equal
to operation and 4 indicates that the right operand for the query is a value. The
query constructed in the query qualification is Name = Daisy.
42
In the query object, you specify the namespace and class information. The alias for
the query object is PersonQueryObj. The first value of 1 after the PersonQueryObj
line instructs the query to search for a CI class. The next value of 1 instructs the
query to use the existing PersonQueryQual query qualification object.
The blank value after the query qualifier name is for the source node alias. The
query qualification in this example does not involve an input of multiple nodes in
a graph format. Therefore, this parameter is left blank. The subsequent values of 1
and 1 specify that the query is to be performed on a CI class and that the query
must use an existing query object. The alias for the query qualification object is
then specified. The blank values indicate that there is no explicit join to perform in
the query.
The qbp command takes the input of the dataset, which is BMC.ASSET in this
example. The dataset mask is specified as none with a blank line. The
Query_Object_List, Query_Object_Optional_List, and
Query_Object_Selector_List parameters are then specified. The attribute to
fetch in the query is specified as Name. The results are sorted by the Name
attribute in an ascending order.
Identify function input parameters, and load them with appropriate values.
Examine the content and structure of function output parameters.
Experiment with different parameter values.
43
44
Chapter
This section describes how to find CIs related to each other using the BMC Atrium
CMDB C API query functions.
Though this section does not discuss specific elements of the Java API and web
services API, the concepts and strategies discussed here are the same for them. For
more information about the query function equivalents in the Java API, see BMC
Atrium CMDB 7.6.03 Javadoc Help installed in the cmdb/sdk/javadoc/cmdbapi/
subdirectory of your BMC Atrium Core installation directory. For more
information about BMC Atrium Core Web Services query operations, see BMC
Atrium Core 7.6.03 Web Services Help.
The following topics are provided:
45
CMDBQueryStruct
Input parameter that contains the
qualifications and the subset to select
from the query results.
CMDBQueryObjectList
The qualification, class name, and type of
object to query (CI or relationship class).
[0]CMDBQueryObject
[1]CMDBQueryObject
CMDBQueryResultGraph
The results returned by the query.
CMDBQueryObjectOptional
The optional information to return
in the query.
CMDBQueryObjectSelectorList
The query objects to retrieve
in the query results.
CMDBQuerySortList
CMDBInstanceList
CMDBQueryQualifierStruct
The qualifications and details about the
type of query to perform (Simple, nested,
And/OR).
[0]CMDBQueryObjectSelector
[0]CMDBQuerySortStruct
[0]CMDBInstanceStruct
[1]CMDBQueryObjectSelector
[1]CMDBQuerySortStruct
[1]CMDBInstanceStruct
[2]CMDBQueryObjectSelector
[2]CMDBQuerySortStruct
[2]CMDBInstanceStruct
CMDBQueryGraphResult
CMDBNodeListList
CMDBEdgeListList
CMDBNodeList
CMDBRelationshipResultsList
CMDBInstanceList
CMDBRelationshipResult
[2]CMDBQueryObject
If queryObjectType = relationship
Direction (In/Out)
If operation = And/Or
CMDBQueryAndOrStruct
If operation = set (nested query)
CMDBQueryQualifierSetOpStruct
If operation = simple
CMDBQueryQualifierSimpleOpStruct
CMDBQueryQualifierValueSetStruct
The qualifications for a nested query (list
of literal values or a query structure).
If type = query
CMDBNestedQueryStruct
46
CMDBQueryQualifierValueStruct
The right operand in the query (literal
value, attribute name, or arithmetic
expression).
[0]CMDBInstanceStruct
[0]CMDBInstanceStruct
[1]CMDBInstanceStruct
[1]CMDBInstanceStruct
[2]CMDBInstanceStruct
[2]CMDBInstanceStruct
Legend
Query result structures
Query object structures
To search for all computers within the payroll division, Allen needs to query the
BMC_ComputerSystem and the BMC_Organization classes that share a
BMC_MemberOfCollection relationship and where the BusinessCategory
attribute of the BMC_Organization class is equal to Payroll.
In the following sample program, Allen creates the queryObjects,
queryObjectsOptional, qObj, and query variables. He then initializes these
variables with specific values and passes them to the CMDBQueryByPath function
as parameters.
/*declare variables*/
CMDBQueryObjectList queryObjects;
CMDBQueryObjectList queryObjectsOptional;
CMDBQueryObject *qObj;
CMDBQueryStruct query;
/*Reset the memory space allocated for the query variable*/
memset(&query, 0, sizeof(CMDBQueryStruct));
/*Set values to the members of the query structure*/
strcpy(query.datasetId, "BMC.ASSET");
query.datasetMask = 0;
/*Reset the memory space allocated for the queryObjects variable*/
memset(&queryObjects, 0, sizeof(CMDBQueryObjectList));
47
strcpy(qObj->alias, "class1");
qObj->qualification = NULL;
/* Initialize the second query object for the
BMC_MemberOfCollection class*/
qObj = &queryObjects.queryObjectList[1];
strcpy(qObj->classNameId.namespaceName,"BMC.CORE");
strcpy(qObj->classNameId.className, "BMC_MemberOfCollection);
strcpy(qObj->alias, "relationship1");
qObj->qualification = NULL;
/* Initialize the third query Object for the BMC_Organization
class*/
qObj = &queryObjects.queryObjectList[2];
strcpy(qObj->classNameId.namespaceName,"BMC.CORE");
strcpy(qObj->classNameId.className, "BMC_Organization ");
strcpy(qObj->alias, "class2");
/*Memory space allocated to contain qualification for the
BMC_Organization class*/
qObj->qualification = ( *) calloc (sizeof(), 1);
/*Specify SIMPLE type operation for the qualification*/
qObj->qualification->operation = CMDB_QUERY_QUAL_OP_SIMPLE;
qObj->qualification->u.simpleOp =
(CMDBQueryQualifierSimpleOpStruct *) calloc
(sizeof(CMDBQueryQualifierSimpleOpStruct), 1);
/*Specify the attribute and arithmetic condition for the
qualification*/
qObj->qualification->u.simpleOp->operation =
CMDB_QUERY_QUAL_SIMPLEOP_EQUAL;
strcpy(qObj->qualification->u.simpleOp->attribute,
"BusinessCategory");
/*Specify the expression to the right of the condition (right
operand)*/
qObj->qualification->u.simpleOp->operandRight =
(CMDBQueryQualifierValueStruct *) calloc
(sizeof(CMDBQueryQualifierValueStruct), 1);
/*Specify the operand type for the right operand*/
qObj->qualification->u.simpleOp->operandRight->type =
CMDB_QUERY_QUAL_VALUE_TYPE_VALUE;
qObj->qualification->u.simpleOp->operandRight->u.value.dataType =
AR_DATA_TYPE_CHAR;
/* Specify the literal value for the comparison in the
qualification*/
qObj->qualification->u.simpleOp->operandRight->u.value.u.charVal =
strdup("Payroll");
/*Specifies the object type for the top level object in the
query*/
48
qObj->queryObjectType = CMDB_QUERY_OBJECT_TYPE_REGULAR;
/*Set the queryObjectsOptional object with 0s to indicate that all
attributes in the CMDBQueryObjectSelectorList object are
required*/
memset(&queryObjectsOptional, 0, sizeof(CMDBQueryObjectList));
/*Initialize the querySelector object*/
memset(&querySelector, 0, sizeof(CMDBQueryObjectSelectorList));
querySelector.numItems = 1;
querySelector.queryObjectSelectorList =
(CMDBQueryObjectSelectorStruct *) calloc(2,
sizeof(CMDBQueryObjectSelectorStruct));
/*Initialize the selector object*/
selector = &querySelector.queryObjectSelectorList[0];
strcpy(selector->alias, "class1");
selector->attributes = (ARNameList *) calloc(sizeof
(ARNameList), 1);
selector->attributes->numItems = 1;
selector->attributes->nameList = (ARNameType *)
calloc(sizeof(ARNameType), 1);
/*Specify the name of the attribute to retrieve*/
strcpy(selector->attributes->nameList[0], "InstanceId");
querySelector.flags = CMDB_QUERY_OBJECTSELECTOR_FLAG_DEFAULT_NONE;
query.queryObjects = &queryObjects;
query.queryObjects = &queryObjectsOptional;
query.queryObjectsToSelect = &querySelector;
query.firstRetrieve = 0;
query.maxRetrieve = 500;
result = CMDBQueryByPath(GetControlStructPtr(),
&query,
&resultStruct,
&status);
Allen wants to query the production dataset for all computer systems in the
Payroll division. Therefore, he sets the datasetId member of the query variable
to BMC.ASSET and the datasetMask member to 0. He then initializes the members
of the queryObjects object and sets the numItems member to 3 to include the
classes identified in the query: BMC_ComputerSystem, BMC_MemberOfCollection,
and BMC_Organization.
Allen sets the qObj variable to the first queryObject object in the
queryObjectList. He then initializes the Namespace, ClassName, alias, and
qualification members to contain information about the BMC_ComputerSystem
class. He initializes the second queryObject object to contain information about
the BMC_MemberOfCollection class. For both BMC_ComputerSystem and
BMC_MemberOfCollection classes, he does not specify any qualification.
49
Allen initializes the third queryObject object in the list to contain information
about the BMC_Organization class. Because the qualification for this class is to be
specified as BMC_Organization = Payroll, Allen allocates the memory space
for the qualification member. He sets the operation type for the qualification to
CMDB_QUERY_QUAL_OP_SIMPLE.
Allen then specifies the qualification for the BMC_Organization class. He sets the
operation for the u.simpleOp member to CMDB_QUERY_QUAL_SIMPLEOP_EQUAL
and the attribute to BusinessCategory.
Because Allen wants to query all computers in the Payroll division, the expression
to the right of the condition in the query in this case is a literal value. Therefore, he
sets the operand type for the right operand to
CMDB_QUERY_QUAL_VALUE_TYPE_VALUE. He specifies the data type of the value as
AR_DATA_TYPE_CHAR and sets the value for the right operand in the qualification
to Payroll.
Allen sets the queryObjectType member of the qObj object to
CMDB_QUERY_OBJECT_TYPE_REGULAR to indicate that the class information that
qObj structure holds is a regular class. Because this query returns all the attributes
specified in the selector list, he sets the &queryObjectsOptional object to 0s.
Allen then initializes the querySelector object with the numItems member set to
1. He initializes the selector object, which points to the first object in the
querySelector array, with values for the nameList member. Because Allen
requires only the instance IDs of the computer systems, the InstanceId is the only
attribute that is selected from the query result.
Allen sets the flags member of the querySelector object to
CMDB_QUERY_OBJECTSELECTOR_FLAG_DEFAULT_NONE, which means that no
attributes are selected from the query result by default. He sets the queryObjects,
queryObjectsOptional, querySelector, firstRetrieve, and maxRetrieve
members of the query object with the filled-in structures of each of the objects. He
then finally passes these objects to the CMDBQueryByPath function. The query
result is stored in the result variable, which is of type CMDBQueryResultStruct.
In the loop, you call the CMDBGraphWalkNext function until the query has no more
records to return. Chunking occurs when the maxRetrieve parameter has a value
greater than 0. Otherwise, the query returns all the nodes in the first call. For
example, if the query retrieves 500 rows of data and the maxRetrieve parameter
is set to 100, the CMDBGraphWalkNext function returns 100 nodes in the first call,
100 nodes in the next, and so on.
51
52
NOTE
The CMDBGraphQuery function is a legacy method of building queries, and has
been replaced with the newer graph walk functions. If you know the starting
instance of your query, use the graph walk functions.
For the CMDBGraphQuery function, you must know the adjacent nodes to traverse
in the graph. To avoid this issue, use the CMDBQueryByPath or graph walk
functions.
53
Graph representation
You can represent a graph G = (V, E), in two standard ways: as a collection of
adjacency lists or as an adjacency matrix. The adjacency-list representation is more
common, because it provides a compact way to represent sparse graphsthose for
which |E| is much less than |V|2. However, an adjacency-matrix representation
might be better when the graph is dense, |E| is close to |V|2. The representation
used by the CMDBGraphQuery input query graph is an adjacency list.
The adjacency-list representation of a graph G = (V, E) consists of an array Adj
of |V| lists, one for each vertex in V. For each u in the set of V, the adjacency list
Adj[u] contains pointers to all the vertices v such that there is an edge (u, v) in
the set of E. That is, Adj[u] consists of all the vertices adjacent to u in G. The vertices
in each adjacency list are typically stored in an arbitrary order. Figure 3-2 (b) is an
adjacency-list representation in an arbitrary order of the undirected graph in
Figure 3-2 (a).
Figure 3-2: Undirected graph and its equivalent adjacency list
NOTE
In an undirected graph G = (V, E), the edge set E consists of unordered pairs of
vertices, rather than ordered pairs. That is, an edge is a set {u, v}, where (u, v)
in the set of E, and u is not equal to v. In an undirected graph, self-loops are
forbidden, so every edge consists of exactly two distinct vertices.
54
55
56
Figure 3-6 shows the data structures of the queryGraph argument for Figure 3-5
(a). Figure 3-7 on page 58 shows the data structures of the queryGraph argument
for Figure 3-5 (b).
57
The path taken to walk this graph is shown by the bolded relationships in
Figure 3-8 on page 59. The bolded nodes are those returned in the objects list.
58
59
Figure 3-10 on page 61 shows the data structures of the queryGraph argument for
Figure 3-9 (a). Figure 3-11 on page 62 shows the data structures of the queryGraph
argument for Figure 3-9 (b).
60
61
The path taken to walk this graph is shown by the bolded relationships in
Figure 3-12 on page 63. The bolded nodes are those returned in the objects list.
62
Six CIs. Three are instances of A:A with instance IDs 8, 5, and 9. Three are
instances of A:B with instance IDs 1, 3, and 2.
Six relationships. Three are instances of A:rAB with instance IDs 1, 3, and 2.
Three are instances of A:rBA with instance IDs 1, 2, and 3.
63
64
Chapter
C API functions
This section provides reference information for the C API functions, which are
defined in the cmdb.h and cmdbfree.h header files. For a complete list of header
files required for BMC Atrium Core, see BMC Atrium CMDB C API header files
on page 29.
The following topics are provided:
65
66
CMDB Data Change AllFor all other functions with which you manipulate the
data in BMC Atrium CMDB.
Table 4-1: List of functions categorized by type (Sheet 1 of 4)
Function type
Function list
CMDBBeginBulkEntryTransaction
CMDBEndBulkEntryTransaction
67
Function list
CMDBGetServerPort
CMDBInitialization
CMDBSetServerPort
CMDBSystemInit
CMDBTermination
CMDBExportData
CMDBExportDef
CMDBImportData
CMDBImportDef
CMDBActivateFederatedInContext
CMDBExpandParametersForCI
CMDBGetRelatedFederatedInContext
CMDBRunQualificationForCI
68
Function list
Each of these free functions accept two
parameters:
valueA pointer to the structure you
want to free. The function recursively frees
all allocated memory within that structure.
If you specify NULL for this parameter (or the
structure is a list with zero items), the
function performs no operations.
freeStructA Boolean value that
indicates whether to free the top level
structure. If you allocated memory for the
top level structure, specify TRUE to free
both the structure and its contents. If you
used a stack variable for the top level
structure, specify FALSE to free only the
contents of the structure.
Free functions: Release the memory space
allocated to the specified C API structure.
When you allocate memory space for
parameters that various functions require,
you must release the memory when it is no
longer required.
FreeCMDBAttributeGetStruct
FreeCMDBAttributeLimit
FreeCMDBAttributeLimitList
FreeCMDBAttributeLimitStruct
FreeCMDBAttributeValueList
FreeCMDBAttributeValueListList
FreeCMDBAuditInfoStruct
FreeCMDBAuditValueList
FreeCMDBAuditValueListList
FreeCMDBClassNameIdList
FreeCMDBClassTypeInfo
FreeCMDBExportItemList
FreeCMDBExportItemStruct
FreeCMDBFederatedActivateInfo
FreeCMDBGetObjectList
FreeCMDBGetRelationList
FreeCMDBGraphAdjacentList
FreeCMDBGraphAdjacentStruct
FreeCMDBGraphList
FreeCMDBGraphStruct
FreeCMDBGraphWalkObjectStruct
FreeCMDBGraphWalkObjectList
FreeCMDBGraphWalkQueryStruct
FreeCMDBGraphWalkRelation
FreeCMDBGraphWalkRelationList
FreeCMDBGraphWalkResultStruct
FreeCMDBGraphWalkSelectorAndFilterList
FreeCMDBGraphWalkSelectorAndFilterStruct
FreeCMDBGraphWalkStateStruct
FreeCMDBIndexList
FreeCMDBNestedQueryStruct
FreeCMDBQualifierStruct
FreeCMDBImportItemList
FreeCMDBIndexList
FreeCMDBInstanceList
FreeCMDBQueryObject
FreeCMDBQueryObjectList
FreeCMDBQueryObjectSelectorList
FreeCMDBQueryQualifierStruct
FreeCMDBQueryQualifierValueStruct
FreeCMDBQueryResultGraph
FreeCMDBQueryStruct
FreeCMDBQuerySortStruct
FreeCMDBQuerySortList
Chapter 4 C API functions
69
Function list
Note: When you use the bulk functions, such as
CMDBCreateMultipleInstances and
CMDBDeleteMultipleInstances, to
manipulate one or more instances, the
success of the operation depends on the
complete call. For example, if an error is
encountered when creating a particular
instance in the bulk function, the entire
operation is rolled back and none of the
instances are created.
CMDBCreateInstance
CMDBCreateMultipleInstances
CMDBDeleteInstance
CMDBDeleteMultipleInstances
CMDBGetCopyAuditData
CMDBGetInstance
CMDBGetInstanceBLOB
CMDBGetListInstance
CMDBGetMultipleInstances
CMDBSetInstance
CMDBSetMultipleInstances
CMDBCancelJobRun
CMDBGetJobRun
CMDBGetListJobRun
CMDBStartJobRun
CMDBCreateGuid
Utility functions: Use BMC Atrium CMDB
utilities to generate globally unique identifiers CMDBGetVersions
(GUIDs) and get version information.
70
CMDBActivateFederatedInContext function
CMDBActivateFederatedInContext function
The CMDBActivateFederatedInContext function expands the
BMC_FederatedInterface instance for a specific CI. Depending on a flag that you
specify when you call this function, your federated instance might be either only
expanded or expanded and launched.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBActivateFederatedInContext(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
datasetId,
ARNameType
instanceId,
ARNameType
federatedInstanceId,
unsigned int
activateOption,
CMDBFederatedActivateInfo
*federatedInfo,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
datasetIdThe unique identifier for the dataset. The data in the return values
are based on the dataset ID specified.
71
Return values
federatedInfoThe expanded federated instance information.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBBeginBulkEntryTransaction function
The CMDBBeginBulkEntryTransaction function enables you to invoke API
functions within a bulk transaction construct. Any API calls that arrive after this
function call are placed in a queue. Data model functions are not part of the bulk
transaction.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBBeginBulkEntryTransaction(
ARControlStruct
*control,
ARStatusList
*status)
Input argument
ControlThe control record for the operation, which contains information about
the user requesting the operation and the server on which the operation is to be
performed.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
72
CMDBCancelJobRun function
CMDBCancelJobRun function
The CMDBCancelJobRun function cancels a currently running Reconciliation
Engine job. Depending on the system resources, the Reconciliation Engine might
cancel a job with a certain delay.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBCancelJobRun(
ARControlStruct
*control,
ARNameType
jobRunId,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Return value
statusA list of zero or more notes, warnings, or errors.
73
CMDBCreateAttribute function
The CMDBCreateAttribute function creates a new attribute with the specified
name for the specified class.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBCreateAttribute(
ARControlStruct
*control,
CMDBClassNameId
classNameID,
ARNameType
attributeName,
ARNameType
attributeId,
unsigned int
dataType,
ARInternalId
*arsubclassesId,
unsigned int
entryMode,
CMDBAttributeLimit
*attributeLimit,
ARValueStruct
*defaultValue,
ARPropList
*characList,
ARPropList
*customCharacList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIdThe name of the class for which you want to create an attribute.
The classNameID argument contains the namespace name and the unique class
name.
74
CMDBCreateAttribute function
5: Diary (CMDB_ATTR_DATA_TYPE_DIARY)
6: Selection (CMDB_ATTR_DATA_TYPE_ENUM)
7: Time (CMDB_ATTR_DATA_TYPE_TIME)
10: Fixed-point decimal (CMDB_ATTR_DATA_TYPE_DECIMAL)
11: Attachment (CMDB_ATTR_DATA_TYPE_ATTACH)
12: Currency (CMDB_ATTR_DATA_TYPE_CURRENCY)
13: Date (CMDB_ATTR_DATA_TYPE_DATE)
14: Time of day (CMDB_ATTR_DATA_TYPE_TIME_OF_DAY)
37: Attachment pool (CMDB_ATTR_DATA_TYPE_ATTACH_POOL)
entryModeThe entry mode for the attribute. Entry modes not listed are for
BMC Software internal use.
1: RequiredUsers must enter data (CMDB_ATTR_ENTRYMODE_REQUIRED).
2: OptionalUsers do not have to enter data, but they can if needed
(CMDB_ATTR_ENTRYMODE_OPTIONAL).
4: Display onlyUsers cannot enter data
(CMDB_ATTR_ENTRYMODE_DISPLAY_ONLY).
attributes, you see all attributes, including the hidden attributes. You can specify
one or more group IDs or role IDs for the permissions, separated by a semicolon,
for example, 20;-5.
2: Change PermissionsSpecify a list of groups or roles that have permissions
75
group or a role. When querying for classes, you can retrieve hidden attributes.
You can specify one or more group IDs or role IDs for the permissions, separated
by a semicolon, for example, 20;3.
5: Propagated OwnerThe class ID and the attribute ID of the lead class
attribute.
1CMDB_ATTR_CREATE_MODE_OPENAnyone can specify a value for the
attribute.
2CMDB_ATTR_CREATE_MODE_PROTECTEDOnly users with permissions can
76
CMDBCreateClass function
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
CMDBCreateClass function
The CMDBCreateClass function creates a class with the core attributes in the
OBJSTR:Class. The data model is stored in the OBJSTR:Class form, and the
attribute information is stored in the OBJSTR:AttributeDefinition form.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBCreateClass(
ARControlStruct
*control,
CMDBClassNameId
*classNameID,
ARNameType
classID,
CMDBClassTypeInfo
*classTypeInfo,
CMDBClassNameId
*superclassNameId,
CMDBIndexList
*indexList,
CMDBAuditInfoStruct
*auditInfo,
ARPropList
*characList,
ARPropList
*customCharacList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classIDThe unique identifier for the class. It can be provided by the user. If
left blank, the class ID is automatically generated by the system.
77
characListA list of characteristics for the class. Specify NULL for this
parameter if you do not want to associate characteristics with this class.
Characteristics not listed are for BMC Software internal use.
1: SingletonUsed to specify if this is a singleton class. This characteristic is an
integer value where type CMDB_CLASS_CHARAC_SINGLETON_FALSE indicates
that this is not a singleton class. Type CMDB_CLASS_CHARAC_SINGLETON_TRUE
indicates that this is a singleton class (CMDB_CLASS_CHARAC_SINGLETON).
2: AbstractThis property does not allow you to create instances for this
abstract class (CMDB_CLASS_CHARAC_ABSTRACT). After the property has been
set for the attribute, you cannot create instances for it. All the attributes are
propagated to the subclasses.
3: FinalYou cannot create subclasses from this class
(CMDB_CLASS_CHARAC_FINAL).
4: AuthorThe author of the class (CMDB_CLASS_CHARAC_AUTHOR).
5: DescriptionThe class description (CMDB_CLASS_CHARAC_DESCRIPTION).
6: Hidden PermissionGives you the permissions to modify the class
(CMDB_CLASS_CHARAC_CLASS_HIDDEN_PERMS). Marks the class as hidden for a
group or a role. When querying for classes, you can choose to retrieve hidden
classes. You can specify one or more group IDs or role IDs for the permissions
separated by a semicolon, for example, 20;3.
7: Visible PermissionGives you the permissions to modify the class
(CMDB_CLASS_CHARAC_CLASS_VISIBLE_PERMS). Marks the class as visible for a
group or a role. When querying for classes, you will see all classes, including the
hidden classes. You can specify one or more group IDs or role IDs for the
permissions separated by a semicolon, for example, 20;-5.
8: SubclassCMDB_CLASS_CHARAC_CATEGORIZATION_SUBCLASS
9: Form nameCMDB_CLASS_CHARAC_FORM_NAME
78
CMDBCreateClass function
store from which the federated data class will retrieve the data
(CMDB_CLASS_CHARAC_FEDERATION_VENDOR_TABLE_NAME). Specify this
characteristic only if you set the CHARAC_FEDERATION_SCHEMA_TYPE
characteristic to 1.
15: Relation typeAllows you to specify the type of relationship for the
federated class (CMDB_CLASS_CHARAC_RELATION_TYPE). This characteristic,
two CI endpoints.
1CMDB_RELATION_QUERYIndicates that the relation type is a query used for
Remedy AR System qualification, which defines how the source class links to
the destination class in federated relationship classes
(CMDB_CLASS_CHARAC_RELATION_LINK_QUALIFIER).
17: Number of temp tablesAllows you to define the maximum number of
the query.
79
performance reasons, BMC recommends that you do not set this value if you
have a lot of data in the external data store and you have not specified any
qualifications against the federated data class that maps to it.
Return values
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
CMDBCreateGuid function
The CMDBCreateGuid function creates a globally unique identifier (GUID).
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBCreateGuid(
ARGuid
guid,
ARStatusList
*status)
Return values
guidThe unique identifier (system-generated).
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
80
CMDBCreateInstance function
CMDBCreateInstance function
The CMDBCreateInstance function creates a CI or relationship instance of the
specified class.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBCreateInstance(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
datasetId,
CMDBAttributeValueList
*attributeValueList,
ARNameType
instanceId,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIdThe name of the class from which the instance is created. The
classNameID argument contains the namespace name and the unique class
name.
NOTE
If you set values to a diary attribute when you create an instance, the name, text,
and timestamp details of that diary entry are concatenated into a single string. To
avoid this issue, first create the instance, get the instance, and then set the diary
attribute value.
81
Return values
instanceIdThe system-generated unique identifier for the new instance that
is created if you did not specify it in the attributeValueList parameter.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBCreateMultipleAttributes function
The CMDBCreateMultipleAttributes function creates multiple new attributes with
the specified names for the specified class.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBCreateMultipleAttribute(
ARControlStruct
*control,
CMDBClassNameId
*classNameID,
ARNameList
*attributeNameList,
ARNameList
*attributeIdList,
ARUnsignedIntList
*dataTypeList,
ARInternalIdList
*arsubclassesIdList,
ARUnsignedIntList
*entryModeList,
CMDBAttributeLimitList
*attributeLimitList,
ARValueList
*defaultValueList,
ARPropListList
*characListList,
ARPropListList
*customCharacListList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIDThe name of the class for which you want to create the
attributes. The classNameID argument contains the namespace name and the
unique class name.
82
CMDBCreateMultipleAttributes function
entryModeListThe entry mode for the attributes. Entry modes not listed are
for BMC Software internal use.
1: RequiredUsers must enter data (CMDB_ATTR_ENTRYMODE_REQUIRED).
2: OptionalUsers do not have to enter data, but they can if needed
(CMDB_ATTR_ENTRYMODE_OPTIONAL).
4: Display onlyUsers cannot enter data
(CMDB_ATTR_ENTRYMODE_DISPLAY_ONLY).
structure that applies to the type of attribute list that you are modifying. The
limits and properties that you assign must be of the same data type as the
attribute. If you do not want to change the attribute limits and properties,
specify NULL for this parameter.
attributes, you will see all attributes, including the hidden attributes. You can
specify one or more group IDs or role IDs for the permissions separated by a
semicolon, for example, 20;-5.
2: Change PermissionsSpecify a list of groups or roles that have permissions
group or a role. When querying for classes, you can retrieve hidden attributes.
You can specify one or more group IDs or role IDs for the permissions, separated
by a semicolon, for example, 20;3.
5: Propagated OwnerThe class ID and the attribute ID of the lead class
83
attribute.
1CMDB_ATTR_CREATE_MODE_OPENAnyone can specify a value for the
attribute.
2CMDB_ATTR_CREATE_MODE_PROTECTEDOnly users with permissions can
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
84
CMDBCreateMultipleInstances function
CMDBCreateMultipleInstances function
The CMDBCreateMultipleInstances function creates multiple specified CI or
relationship instances in the specified dataset.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBCreateMultipleInstances(
ARControlStruct
*control,
const ARNameType
datasetId,
const CMDBInstanceList
*instances,
ARNameList
*instanceIdList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Return values
instanceIdListThe system-generated unique identifier for the new
instances if you did not specify instance IDs in the attributeValueList
parameter.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
85
CMDBDeleteAttribute function
The CMDBDeleteAttribute function deletes the attribute with the specified ID.
Depending on the value that you specify for the deleteOption parameter, the
attribute is deleted immediately and is not returned to users who request
information about attributes.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBDeleteAttribute(
ARControlStruct
*control,
CMDBClassNameId
classNameID,
ARNameType
attributeName,
unsigned int
deleteOption,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIDThe name of the class from which you want to delete the
attribute. The classNameID argument contains the namespace name and the
unique class name.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
86
CMDBDeleteClass function
CMDBDeleteClass function
The CMDBDeleteClass function deletes a specified class and its associated
attributes.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBDeleteClass(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
unsigned int
deleteOption,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
relationship classes, and audit history (if any) that are associated with the class.
All the dependencies for the specified class are deleted
(CMDB_DELETE_CLASS_OPTION_ALL_DEPENDENCIES). This option overrides the
CMDB_CLASS_DATA_DELETE option.
NOTE
To retain the audit history after you delete the class, back up the class audit form
before you delete the class.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
87
CMDBDeleteInstance function
The CMDBDeleteInstance function deletes the instance of the class.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBDeleteInstance(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
datasetId,
ARNameType
instanceId,
unsigned int
deleteOption,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
datasetIdThe unique identifier for the dataset. Instances are deleted from a
dataset based on the value specified in this parameter.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
88
CMDBDeleteMultipleInstances function
CMDBDeleteMultipleInstances function
The CMDBDeleteMultipleInstances function deletes a list of CI or relationship
instances in the specified dataset.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBDeleteMultipleInstance(
ARControlStruct
*control,
const ARNameType
datasetId,
const CMDBInstanceList
*instances,
deleteOption,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
datasetIdThe unique identifier for the dataset. Instances are deleted from a
dataset based on the value specified in this parameter.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
89
CMDBEndBulkEntryTransaction function
Depending on the success of the calls invoked within the
CMDBBeginBulkEntryTransaction function, the transactions are committed or
rolled back.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBEndBulkEntryTransaction(
ARControlStruct
*control,
unsigned int
actionType,
ARBulkEntryReturnList
*bulkEntryReturnList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Return values
bulkEntryReturnListReturns the status of the entry calls.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
90
CMDBExpandParametersForCI function
CMDBExpandParametersForCI function
The CMDBExpandParametersForCI function accepts an unexpanded string that
contains parameters and substitutes values from the attribute value list provided
in the CMDBAttributeValueList structure. For example, the function takes
$Name$ and $InstanceId$ as the unexpanded parameters and substitutes the
values HRServer and CS000019.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBQualificationForCI(
ARControlStruct
*control,
char
*paramString,
CMDBAttributeValueList
*attValueList,
char
**expandedStr,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Return Values
expandedStrThe string that contains the expanded parameters.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
91
CMDBExportData function
The CMDBExportData function exports the specified class data for a specific
qualification.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBExportData(
ARControlStruct
*control,
ARQualifierStruct
*qualifier,
ARNameList
*attributeGetList,
CMDBSortList
*sortList,
unsigned int
firstRetrieve,
unsigned int
maxRetrieve,
char
*exportBuf,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
92
CMDBExportDef function
Return values
exportBufThe exported buffer that contains the class data in an XML format.
statusA list of zero or more notes, warnings, or errors.
CMDBExportDef function
The CMDBExportDef function exports a list of specified class definitions.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBExportDef(
ARControlStruct
*control,
CMDBExportItemList
*exportItemList,
char
*exportBuf,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Return values
exportBufThe exported buffer that contains the class definitions in XML
format.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
93
CMDBGetAttribute function
The CMDBGetAttribute function retrieves a single attribute.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetAttribute(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
attributeName,
ARNameType
attributeId,
unsigned int
*dataType,
unsigned int
*attributeType,
CMDBClassNameId
*baseClassNameId,
ARInternalId
*arsubclassesId,
unsigned int
*entryMode,
CMDBAttributeLimit
*attributeLimit,
ARValueStruct
*defaultValue,
ARPropList
*characList,
ARPropList
*customCharacList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
name.
94
CMDBGetAttribute function
Return values
attributeIdThe ID of the attribute.
dataTypeThe data type of the attribute. Data types represented by numbers
not in the list are either unsupported or display fields.
1: Keyword (CMDB_ATTR_DATA_TYPE_KEYWORD)
2: Integer (CMDB_ATTR_DATA_TYPE_INTEGER)
3: Real (CMDB_ATTR_DATA_TYPE_REAL)
4: Character (CMDB_ATTR_DATA_TYPE_CHAR)
5: Diary (CMDB_ATTR_DATA_TYPE_DIARY)
6: Selection (CMDB_ATTR_DATA_TYPE_ENUM)
7: Time (CMDB_ATTR_DATA_TYPE_TIME)
10: Fixed-point decimal (CMDB_ATTR_DATA_TYPE_DECIMAL)
12: Currency (CMDB_ATTR_DATA_TYPE_CURRENCY)
13: Date (CMDB_ATTR_DATA_TYPE_DATE)
14: Time of day (CMDB_ATTR_DATA_TYPE_TIME_OF_DAY)
37: Attachment pool (CMDB_ATTR_DATA_TYPE_ATTACH_POOL)
95
attributes, you see all attributes, including the hidden attributes. You can specify
one or more group IDs or role IDs for the permissions, separated by a semicolon,
for example, 20;-5.
2: Change PermissionsSpecify a list of groups or roles that have permissions
group or a role. When querying for classes, you can retrieve hidden attributes.
You can specify one or more group IDs or role IDs for the permissions, separated
by a semicolon, for example, 20;3.
4: Primary KeySpecify whether the attribute is a part of the primary key of
the class (CMDB_ATTR_CHARAC_PRIMARY_KEY).
5: Propagated OwnerThe class ID and the attribute ID of the lead class
attribute.
1CMDB_ATTR_CREATE_MODE_OPENAnyone can specify a value for the
attribute.
2CMDB_ATTR_CREATE_MODE_PROTECTEDOnly users with permissions can
96
CMDBGetClass function
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBGetClass function
The CMDBGetClass function retrieves class information from the OBJSTR:Class
form for the specified class.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetClass(
ARControlStruct
*control,
CMDBClassNameID
*classNameId,
ARNameType
*classId,
CMDBClassTypeInfo
*classTypeInfo,
CMDBClassNameId
*superclassNameId,
CMDBIndexList
*indexList,
CMDBAuditInfoStruct
auditInfo,
ARPropList
*characList,
ARPropList
*customCharacList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Return values
classIdThe ID used to identify the class.
classTypeInfoInformation about the type of class.
superclassNameIdThe name of the superclass. The superclassNameID
argument contains the namespace name and the unique class name.
97
characListA list of characteristics for this class. Specify NULL for this
parameter if you do not want to associate characteristics with this class.
Characteristics not listed are for BMC Software internal use.
1: SingletonUsed to specify if this is a singleton class. This characteristic is an
integer value where type CMDB_CLASS_CHARAC_SINGLETON_FALSE indicates
that this is not a singleton class. Type CMDB_CLASS_CHARAC_SINGLETON_TRUE
indicates that this is a singleton class (CMDB_CLASS_CHARAC_SINGLETON).
2: AbstractThis property does not allow you to create instances for this
abstract class (CMDB_CLASS_CHARAC_ABSTRACT). After the property has been
set for the attribute, you cannot create instances for it. All the attributes are
propagated to the subclasses.
3: FinalYou cannot create subclasses from this class
(CMDB_CLASS_CHARAC_FINAL).
4: AuthorThe author of the class (CMDB_CLASS_CHARAC_AUTHOR).
5: DescriptionThe class description (CMDB_CLASS_CHARAC_DESCRIPTION).
6: Hidden permissionsGives you the permissions to modify the class
(CMDB_CLASS_CHARAC_CLASS_HIDDEN_PERMS). Marks the class as hidden for
the users in the group. When querying for classes, you can choose to retrieve
hidden classes.
7: Visible permissionsGives you the permissions to modify the class
(CMDB_CLASS_CHARAC_CLASS_VISIBLE_PERMS). Marks the class as visible for
the users in the group. When querying for classes, you will see all classes
including the hidden classes.
8: Categorization(CMDB_CLASS_CHARAC_CATEGORIZATION_SUBCLASS).
9: Form name(CMDB_CLASS_CHARAC_FORM_NAME).
10: ExposureThe visibility of the class, which can be
CMDB_CLASS_EXPOSURE_NONE, CMDB_CLASS_EXPOSURE_USED_VISIBLE, or
CMDB_CLASS_EXPOSURE_USED_HIDDEN.
98
CMDBGetClass function
12: Federation schema typeAllows you to specify the schema type for
federation (CMDB_CLASS_CHARAC_FEDERATION_SCHEMA_TYPE). This
store from which the federated data class will retrieve the data
(CMDB_CLASS_CHARAC_FEDERATION_VENDOR_TABLE_NAME). Specify this
characteristic only if you set the CHARAC_FEDERATION_SCHEMA_TYPE
characteristic to 1.
15: Relation typeAllows you to specify the type of relationship for the
federated class (CMDB_CLASS_CHARAC_RELATION_TYPE). This characteristic,
two CI endpoints.
1CMDB_RELATION_QUERYIndicates that the relation type is a query used for
join conditions. 0 is the default value for this characteristic.
16: BMC Remedy AR System qualificationAllows you to specify the BMC
Remedy AR System qualification, which defines how the source class links to
the destination class in federated relationship classes
(CMDB_CLASS_CHARAC_RELATION_LINK_QUALIFIER).
17: Number of temp tablesAllows you to define the maximum number of
the query.
1CMDB_QUAL_NON_RESTRICITVEIndicates that a qualification is required
for the federated class. 1 is the default value for this characteristic. For
performance reasons, BMC recommends that you do not set this value if you
have a lot of data in the external data store and you have not specified any
qualifications against the federated data class that maps to it.
99
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBGetCopyAuditData function
If the attribute data for the instance is modified, the CMDBGetCopyAuditData
function retrieves a copy of the specified CI instance. The Audit Option must be set
for the attributes characteristic to get the audit data.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetCopyAuditData(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
instanceId,
ARTimestamp
auditTimestamp,
CMDBQualifierStruct
*qualifier,
ARNameList
*attributeGetList,
CMDBSortList
*sortList,
unsigned int
firstRetrieve,
unsigned int
maxRetrieve,
CMDBAuditValueListList
*auditValueListList,
unsigned int
*numMatches,
ARStatusList
*status)
classNameIdThe class name of the CI instance for which to retrieve the audit
data. The classNameID argument contains the namespace name and the unique
class name.
100
CMDBGetCopyAuditData function
sortListA list of zero or more fields that identifies the sort order for the
attributes. Specify a NULL value for this parameter to use no specific sort order.
Return values
auditValueListListThe list of values for the specified attributes. If the audit
option at the CI class-level is disabled, an error is returned.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
Chapter 4
C API functions
101
CMDBGetInstance function
The CMDBGetInstance function retrieves information about the instance.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetInstance(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
datasetId,
usigned int
getMask,
ARNameType
instanceId,
ARNameList
*attributeGetList,
CMDBAttributeValueList
*attributeValueList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIdThe name of the class for which to retrieve the instance. The
classNameID argument contains the namespace name and the unique class
name.
datasetIdThe unique identifier for the dataset. The data in the return values
are based on the dataset ID specified in this parameter.
102
CMDBGetInstanceBLOB function
Return values
attributeValueListA list of one or more attribute and value pairs retrieved
for the specified instance.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBGetInstanceBLOB function
The CMDBGetInstanceBLOB function retrieves the attachment, or binary large
object (BLOB), stored for the attachment subclasses. The BLOB can be returned in a
file or in an in-memory buffer.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetInstanceBLOB(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
datasetId,
unsigned int
getMask,
ARNameType
instanceId,
ARNameType
attributeName,
ARLocStruct
*loc,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIdThe name of the class for which to retrieve the instance blob. The
classNameID argument contains the namespace name and the unique class
name.
datasetIdThe unique identifier for the dataset. The data in the return values
are based on the dataset ID specified in this parameter.
C API functions
103
Return values
locThe location where the BLOB is stored.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBGetListClass function
The CMDBGetListClass function retrieves a list of classes. You can specify one or
more of the classNameIdRelation, superclassName, and characQueryList
qualification parameters.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetListClass(
ARControlStruct
*control,
ARNameType
namespaceName,
CMDBClassNameId
*classNameIdRelation,
CMDBClassNameId
*superclassName,
ARPropList
*characQueryList,
ARBoolean
getHiddenClasses,
CMDBClassNameIdList
*classNameIdList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
104
CMDBGetListInstance function
Return values
classNameIdListA list of class names that match the specified criteria.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBGetListInstance function
The CMDBGetListInstance function retrieves a list of instances. You can limit the
instance list to entries that match particular conditions by specifying the
qualifier parameter.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetListInstance(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
datasetId,
usigned int
getMask,
CMDBQualifierStruct
*qualifier,
ARNameList
*attributeGetList,
CMDBSortList
*sortList,
unsigned int
firstRetrieve,
unsigned int
maxRetrieve,
ARNameList
*instanceIdList,
CMDBAttributeValueListList
*attributeValueListList,
unsigned int
*numMatches,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIdThe name of the class for which to retrieve the instances. The
classNameID argument contains the namespace name and the unique class
name.
Chapter 4
C API functions
105
datasetIdThe unique identifier for the dataset. The data in the return values
are based on the dataset ID specified in this parameter.
Return values
instanceIdListThe list of instance IDs that match the criteria.
attributeValueListListA list of one or more attribute and value pairs
retrieved for the specified instances.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
106
CMDBGetMultipleAttributes function
CMDBGetMultipleAttributes function
The CMDBGetMultipleAttributes function retrieves multiple attributes.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetMultipleAttribute(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARBoolean
getHiddenAttrs,
ARBoolean
getDerivedAttrs,
ARNameList
*nameList,
ARPropList
*attrCharacQueryList,
ARBooleanList
*existList,
ARNameList
*attributeNameList,
ARNameList
*attributeIdList,
ARUnsignedIntList
*dataTypeList,
ARUnsignedIntList
*attributeTypeList,
CMDBClassNameIdList
*baseClassNameIdList,
ARInternalIdList
*arsubclassesIdList,
ARUnsignedIntList
*entryModeList,
CMDBAttributeLimitList
*attributeLimitList,
ARValueList
*defaultValueList,
ARPropListList
*characList,
ARPropListList
*customCharacList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
C API functions
107
Return values
existListA list of flags and corresponding Boolean values indicating
whether the attribute list exists. The value TRUE indicates that the attribute list
exists; FALSE indicates that the attribute list does not exist.
baseClassNameIdListThe list of base class name IDs for which you want to
retrieve the attribute.
entryModeListThe entry mode for the attribute. Entry modes not listed are
for BMC Software internal use.
1: RequiredUsers must enter data (CMDB_ATTR_ENTRYMODE_REQUIRED).
2: OptionalUsers do not have to enter data, but they can if needed
(CMDB_ATTR_ENTRYMODE_OPTIONAL).
4: Display onlyUsers cannot enter data
(CMDB_ATTR_ENTRYMODE_DISPLAY_ONLY).
structure that applies to the type of attributes that you are retrieving. The limits
and properties that you assign must be of the same data type as the attribute. If
you do not want to change the attribute limits and properties, specify NULL for
this parameter.
attributes, you see all attributes, including the hidden attributes. You can specify
one or more group IDs or role IDs for the permissions, separated by a semicolon,
for example, 20;-5.
108
CMDBGetMultipleAttributes function
group or a role. When querying for classes, you can retrieve hidden attributes.
You can specify one or more group IDs or role IDs for the permissions, separated
by a semicolon, for example, 20;3.
4: Primary KeySpecify whether the attribute is a part of the primary key of the
class (CMDB_ATTR_CHARAC_PRIMARY_KEY).
5: Propagated OwnerThe class ID and the attribute ID of the lead class
attribute.
1CMDB_ATTR_CREATE_MODE_OPENAnyone can specify a value for the
attribute.
2CMDB_ATTR_CREATE_MODE_PROTECTEDOnly users with permissions can
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
Chapter 4
C API functions
109
CMDBGetMultipleInstances function
The CMDBGetMultipleInstances function retrieves multiple instances of the
specified class in a dataset.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetMultipleInstances(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
datasetId,
unsigned int
getMask,
ARNameList
*instanceIds,
ARNameList
*attributeGetList,
ARBooleanList
*existList,
CMDBAttributeValueListList
*attributeValueListList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIdThe name of the class for which to retrieve the instances. The
classNameID argument contains the namespace name and the unique class
name.
datasetIdThe unique identifier for the dataset. The data in the return values
are based on the dataset ID specified in this parameter.
110
CMDBGetCMDBUIComponents function
Return values
existListA list of flags and corresponding Boolean values indicating
whether the attribute list exists. The value TRUE indicates that the attribute list
exists; FALSE indicates that the attribute list does not exist.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBGetCMDBUIComponents function
The CMDBGetCMDBUIComponents function retrieves a list of UI components for
a specified class.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetCMDBUIComponents(
ARControlStruct
*control,
CMDBUIComponentInfo
*inputInfo,
ARNameType
datasetId,
ARNameType
instanceId,
CMDBUIComponentResultList
*outputInfo,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
inputInfoThe qualification for the user interface component. You can specify
information such as locale, classId, and tags to retrieve the required UI
component data. If no qualifications are specified, all existing UI components
are returned.
datasetIdThe dataset ID of the specific CI for which you want to retrieve the
UI components. For example, to retrieve component data for an instance of
BMC_ComputerSystem, specify the dataset ID for that instance. If you do not
specify the instanceId parameter for this function, the datasetId parameter
is ignored.
Chapter 4
C API functions
111
Return Values
outputInfoThe CMDBUIComponents result set for the specified
qualifications.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBGetJobRun function
The CMDBGetJobRun function retrieves job information and the log for the
currently running Reconciliation Engine job. For information about interpreting
job run logs and job run information, see the BMC Atrium Core 7.6.03 Installation
Guide.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetJobRun(
ARControlStruct
*control,
ARNameType
jobRunId,
ARREJobRunInfoStruct
*jobRunInfo,
char
**jobRunLog
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Return values
jobRunInfoThe job run information to retrieve.
jobRunLogThe job run log to retrieve.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
112
CMDBGetListJobRun function
CMDBGetListJobRun function
The CMDBGetListJobRun function returns a list of running Reconciliation Engine
jobs. The job list is retrieved based on the qualification passed to the function.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetListJobRun(
ARControlStruct
*control,
CMDBQualifierStruct
*jobQualifier,
ARREJobRunInfoList
*jobRunInfoList,
unsigned int
*numMatches,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Return values
jobRunInfoListThe list of running jobs that match the qualification criteria.
numMatchesThe total number of jobs that match the qualification criteria.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
Chapter 4
C API functions
113
CMDBGetRelatedFederatedInContext function
The CMDBGetRelatedFederatedInContext function returns related
BMC_FederatedInterface instances for a specific CI.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetRelatedFederatedInContext(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
datasetId,
ARNameType
instanceId,
ARNameList
*attributeGetList,
ARNameList
*instanceIdList,
CMDBAttributeValueListList
*attrValueListList,
ARStatusList
*status
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIdThe class name for which to retrieve the federated instances. The
classNameID argument contains the namespace name and the unique class
name.
Return values
instanceIdListThe list of instance GUIDs.
attrValueListListA list of one or more attribute and value pairs (specified in
any order). You must specify values for all required attributes that do not have
defined defaults. Values must be of the data type defined for the attributes or
have a data type of 0. NULL values can be specified for optional attributes only.
An error is generated if an attribute does not exist or the user specified by the
control parameter does not have write permission for an attribute.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
114
CMDBGetServerPort function
CMDBGetServerPort function
The CMDBGetServerPort function retrieves information about the BMC Atrium
CMDB server port.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGetServerPort(
ARControlStruct
*control,
int
*tcpPort,
int
*rpcPort,
ARStatusList
*status)
Input argument
controlThe control record for the operation, which contains information about
the user requesting the operation and the server on which the operation is to be
performed.
Return values
tcpPortRetrieves the TCP port number for the BMC Atrium Core server.
rpcPortRetrieves the RPC port number for the BMC Atrium Core server.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBGetVersions function
The CMDBGetVersions function retrieves the version information for any BMC
Atrium Core component that is installed.
Synopsis
#include "ar.h"
#include "arextern.h"
int CMDBGetVersions(
ARControlStruct
*control,
ARNameList
*appIdList
ARBooleanList
*existList
CMDBVersionInfoList
*versionInfoList
ARStatusList
*status)
Chapter 4
C API functions
115
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Return values
existListA list of TRUE or FALSE values. Each value in this list denotes
whether the corresponding application IDs in the supplied appIdList exists.
CMDBGraphQuery function
The CMDBGraphQuery function searches for relationships and endpoints related
to a specific CI.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGraphQuery(
116
ARControlStruct
*control,
CMDBClassNameId
*startClassNameId,
ARNameType
datasetId,
unsigned int
getMask,
ARNameType
startExtensionId,
ARNameType
startInstanceId,
int
numLevels,
int
direction,
ARBoolean
noMatchProceed,
ARBoolean
onMatchProceed,
CMDBGraphList
*queryGraph,
CMDBGetObjectList
*objects,
CMDBGetRelationList
*relations,
ARStatusList
*status)
CMDBGraphQuery function
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
datasetIdThe unique identifier for the dataset. The data in the return values
are based on the dataset ID specified in this parameter.
Chapter 4
C API functions
117
Return values
objectsList of one or more CI instances matching the specified criteria. The
starting node is not included.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBGraphWalkBegin function
The CMDBGraphWalkBegin function specifies the start node for retrieving CI and
relationship instances in a chunk. This function sets up the starting node and query
parameters for the graph walk.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGraphWalkBegin(
ARControlStruct
*control,
CMDBClassNameId
*startClassNameId,
ARNameType
*startInstanceId,
CMDBGraphWalkQueryStruct
*graphWalkQueryStruct,
CMDBGraphWalkStateStruct
*graphWalkStateStruct,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
CMDBGraphWalkEnd function
Return values
graphWalkStateStructThe status of the list of classes walked in the query,
next chunks availability, and the next object index. This structure, which is for
internal use only, is used as an input argument for the CMDBGraphWalkNext
function.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBGraphWalkEnd function
The CMDBGraphWalkEnd function ends the graph walk. Use this function after
you retrieve the CI and relationship information using the CMDBGraphWalkNext
function.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGraphWalkNext(
ARControlStruct
*control,
CMDBGraphWalkStateStruct
*graphWalkStateStruct,
ARStatusList
*status)
Input argument
controlThe control record for the operation, which contains information about
the user requesting the operation and the server on which the operation is to be
performed.
Return values
graphWalkStateStructThe status of the last node walked in the CI and
relationship graph.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
Chapter 4
C API functions
119
CMDBGraphWalkNext function
The CMDBGraphWalkNext function moves to the next chunk of nodes to retrieve
in the graph walk. This function is used after setting up the start node in the CI and
relationship graph using the CMDBGraphWalkBegin function.
You do not need to specify values for any of the parameters of the function. To
retrieve rows in chunks, use only the hasNextChunk member of the
CMDBGraphWalkStateStruct structure.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBGraphWalkNext(
ARControlStruct
*control,
CMDBGraphWalkStateStruct
*graphWalkStateStruct,
CMDBGraphWalkResultStruct
*graphWalkResultStruct,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
graphWalkStateStructThe status of the start node setup for the graph walk
query before performing the next query chunk. This structure is for internal use
only.
Return values
graphWalkStateStructThe status of the graph walk after the next chunk is
queried.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
120
CMDBImportData function
CMDBImportData function
The CMDBImportData function imports the specified instance data.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBImportData(
ARControlStruct
*control,
unsigned int
importOption,
char
*importBuf,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
importBufThe import buffer, which contains the class data in XML format to
import.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
Chapter 4
C API functions
121
CMDBImportDef function
The CMDBImportDef function imports a list of specified class definitions.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBImportDef(
ARControlStruct
*control,
CMDBXMLImportItemList
*importItemList,
unsigned int
importOption,
char
*importBuf,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
importItemListA list of zero or more items to import. Specify NULL for this
parameter to import all definitions in the import buffer.
importBufThe import buffer that contains the class definitions in XML format
to import.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
122
CMDBInitialization function
CMDBInitialization function
The CMDBInitialization function initializes the C API session. You must invoke
this function before any other C API calls.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBInitialization(
ARControlStruct
*control,
ARStatusList
*status)
Input argument
controlThe control record for the operation, which contains information about
the user requesting the operation and the server on which the operation is to be
performed.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
Chapter 4
C API functions
123
CMDBQueryByPath function
The CMDBQueryByPath function retrieves a list of instances for the specified
qualifications. To improve the performance of the queries, add indexes on
attributes that are frequently used in the qualification.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBQueryByPath(
ARControlStruct
*control,
CMDBQueryStruct
*query,
CMDBQueryResult
*result,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
queryA query that determines the list of instances to return. The qualification
can include one or more subqueries and any combination of conditional,
relational, and arithmetic operations.
Return values
resultThe list of instances returned for the specified qualifications.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
124
CMDBRunQualificationForCI function
CMDBRunQualificationForCI function
The CMDBRunQualificationForCI function validates a list of attributes for a
specified CI. The CMDBRunQualificationForCI function takes qualification
parameters in structured and encoded modes.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBRunQualificationForCI(
ARControlStruct
*control,
CMDBQualifierStruct
*qualifier,
CMDBAttributeValueList
*attValueList,
ARBoolean*
passed,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
qualifierA query that determines the set of CIs to retrieve. The qualification
can include one or more subclasses and any combination of conditional,
relational, and arithmetic operations. For more information about how to
construct a qualifier, see Chapter 3, Building qualifications and expressions, in the
BMC Remedy Action Request System 7.6.03 Workflow Objects Guide.
Return values
passedA Boolean value that specifies whether the qualification passed.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
Chapter 4
C API functions
125
CMDBSetAttribute function
The CMDBSetAttribute function sets an attribute with the specified name for the
specified class.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBSetAttribute(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
attributeName,
ARNameType
newAttributeName,
unsigned int
*entryMode,
CMDBAttributeLimit
*attributeLimit,
ARValueStruct
*defaultValue,
ARPropList
*characList,
ARPropList
*customCharacList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIdThe name of the class for which the attribute needs to set. The
classNameID argument contains the namespace name and the unique class
name.
entryModeThe list of entry modes for the attribute being set. Entry modes not
listed are for BMC Software internal use.
1: RequiredUsers must enter data (CMDB_ATTR_ENTRYMODE_REQUIRED).
2: OptionalUsers do not have to enter data, but they can if needed
(CMDB_ATTR_ENTRYMODE_OPTIONAL).
4: Display onlyUsers cannot enter data
(CMDB_ATTR_ENTRYMODE_DISPLAY_ONLY).
126
CMDBSetAttribute function
attributeLimitThe list of value limits for the attribute and other properties
specific to the attributes type. See the CMDBsubclassesLimitStruct definition
in cmdb.h to find the contained structure that applies to the type of attribute
that you are modifying. The limits and properties that you assign must be of the
same data type as the attribute. If you do not want to change the attribute limits
and properties, specify NULL for this parameter.
defaultValueThe value to apply if a user does not specify a value for the
attribute. The default value can be up to 255 bytes in length and must be of the
same data type as the attribute.
attributes, you see all attributes, including the hidden attributes. You can specify
one or more group IDs or role IDs for the permissions, separated by a semicolon,
for example, 20;-5.
2: Change PermissionsSpecify a list of groups or roles that have permissions
group or a role. When querying for classes, you can retrieve hidden attributes.
You can specify one or more group IDs or role IDs for the permissions, separated
by a semicolon, for example, 20;3.
4: Primary KeySpecify whether the attribute is a part of the primary key of the
class (CMDB_ATTR_CHARAC_PRIMARY_KEY).
5: Propagated OwnerThe class ID and the attribute ID of the lead class
attribute.
1CMDB_ATTR_CREATE_MODE_OPENAnyone can specify a value for the
attribute.
2CMDB_ATTR_CREATE_MODE_PROTECTEDOnly users with permissions can
Chapter 4
C API functions
127
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
CMDBSetClass function
The CMDBSetClass function sets the class properties in the OBJSTR:Class form.
After you create a class, you cannot change the following properties: namespace,
classId, classType (CI or relationship), and persistence provider.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBSetClass(
128
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
CMDBClassNameId
*newclassNameId,
CMDBClassTypeInfo
*classTypeInfo,
CMDBIndexList
*indexList,
CMDBAuditInfoStruct
*auditInfo,
ARPropList
*characList,
ARPropList
*customCharacList,
ARStatusList
*status)
CMDBSetClass function
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
auditInfoThe audit information for the class: audit type, qualification, and
Audit Only Changed Fields (auditMask). Use the following auditMask values:
characListA list of characteristics for this class. Specify NULL for this
parameter if you do not want to associate characteristics with this class.
Characteristics not listed are for BMC Software internal use.
1: SingletonUsed to specify if this is a singleton class. This characteristic is an
integer value where type CMDB_CLASS_CHARAC_SINGLETON_FALSE indicates
that this is not a singleton class. Type CMDB_CLASS_CHARAC_SINGLETON_TRUE
indicates that this is a singleton class (CMDB_CLASS_CHARAC_SINGLETON).
2: AbstractThis property does not allow you to create instances for this
abstract class (CMDB_CLASS_CHARAC_ABSTRACT). After the property has been
set for the attribute, you cannot create instances for it. All the attributes are
propagated to the subclasses.
3: FinalYou cannot create subclasses from this class
(CMDB_CLASS_CHARAC_FINAL).
4: AuthorThe author of the class (CMDB_CLASS_CHARAC_AUTHOR).
5: DescriptionThe class description (CMDB_CLASS_CHARAC_DESCRIPTION).
6: Hidden permissionsGives you the permissions to modify the class
(CMDB_CLASS_CHARAC_CLASS_HIDDEN_PERMS). Marks the class as hidden for
the users in the group. When querying for classes, you can choose to retrieve
hidden classes.
Chapter 4
C API functions
129
the users in the group. When querying for classes, you will see all classes
including the hidden classes.
8: Categorizationq(CMDB_CLASS_CHARAC_CATEGORIZATION_SUBCLASS).
9: Form name(CMDB_CLASS_CHARAC_FORM_NAME).
10: ExposureThe visibility of the class, which can be
CMDB_CLASS_EXPOSURE_NONE, CMDB_CLASS_EXPOSURE_USED_VISIBLE, or
CMDB_CLASS_EXPOSURE_USED_HIDDEN.
12: Federation schema typeAllows you to specify the schema type for
federation (CMDB_CLASS_CHARAC_FEDERATION_SCHEMA_TYPE). This
characteristic is an integer data type, where:
0CMDB_FEDERATION_SCHEMA_REGULARIndicates that the schema is not of
store from which the federated data class will retrieve the data
(CMDB_CLASS_CHARAC_FEDERATION_VENDOR_TABLE_NAME). Specify this
characteristic only if you set the CHARAC_FEDERATION_SCHEMA_TYPE
characteristic to 1.
15: Relation typeAllows you to specify the type of relationship for the
federated class (CMDB_CLASS_CHARAC_RELATION_TYPE). This characteristic,
which only applies to relationship classes, is an integer data type, where:
0CMDB_RELATION_REGULARIndicates a regular relationship that relates
two CI endpoints.
1CMDB_RELATION_QUERYIndicates that the relation type is a query used for
Remedy AR System qualification, which defines how the source class links to
the destination class in federated relationship classes
(CMDB_CLASS_CHARAC_RELATION_LINK_QUALIFIER).
17: Number of temp tables; allows you to define the maximum number of
temporary tables to create for vendor forms
(CMDB_CLASS_CHARAC_NUM_TEMP_TABLES). Do not specify a value for the
characteristic if you are working with regular (non-vendor) forms.
130
CMDBSetInstance function
the query.
1CMDB_QUAL_NON_RESTRICITVEIndicates that a qualification is required
for the federated class. 1 is the default value for this characteristic. For
performance reasons, BMC recommends that you do not set this value if you
have a lot of data in the external data store and you have not specified any
qualifications against the federated data class that maps to it.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
CMDBSetInstance function
The CMDBSetInstance function sets attribute values for a CI or relationship
instance of the specified class.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBSetInstance(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameType
datasetId,
ARNameType
instanceId,
CMDBAttributeValueList
*attributeValueList,
ARStatusList
*status)
Chapter 4
C API functions
131
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIdThe name of the class to which the instance to set belongs. The
classNameID argument contains the namespace name and the unique class
name.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
132
CMDBSetMultipleAttributes function
CMDBSetMultipleAttributes function
The CMDBSetMultipleAttributes function sets multiple attributes with the
specified names for the specified class.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBSetMultipleAttribute(
ARControlStruct
*control,
CMDBClassNameId
*classNameId,
ARNameList
*attributeNameList,
ARNameList
*newAttributeNameList,
ARUnsignedIntList
*entryModeList,
CMDBAttributeLimitList
*attributeLimitList,
ARValueList
*defaultValueList,
ARPropListList
*characListList,
ARPropListList
*customCharacListList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
classNameIdThe name of the class for which the attributes need to be set. The
classNameID argument contains the namespace name and the unique class
name.
entryModeListThe list of entry modes for the attributes being set. Entry
modes not listed are for BMC Software internal use.
1: RequiredUsers must enter data (CMDB_ATTR_ENTRYMODE_REQUIRED).
2: OptionalUsers do not have to enter data, but they can if needed
(CMDB_ATTR_ENTRYMODE_OPTIONAL).
4: Display onlyUsers cannot enter data
(CMDB_ATTR_ENTRYMODE_DISPLAY_ONLY).
Chapter 4
C API functions
133
attributeLimitListThe list of value limits for the attributes being set and
other properties specific to the attributes types. See the
CMDBsubclassesLimitStruct definition in cmdb.h to find the contained
structure that applies to the type of attributes that you are modifying. The limits
and properties that you assign must be of the same data type as the attributes. If
you do not want to change the attributes limits and properties, specify NULL for
this parameter.
attributes, you see all attributes, including the hidden attributes. You can specify
one or more group IDs or role IDs for the permissions, separated by a semicolon,
for example, 20;-5.
2: Change PermissionsSpecify a list of groups or roles that have permissions
group or a role. When querying for classes, you can retrieve hidden attributes.
You can specify one or more group IDs or role IDs for the permissions, separated
by a semicolon, for example, 20;3.
4: Primary KeySpecify whether the attribute is a part of the primary key of the
class (CMDB_ATTR_CHARAC_PRIMARY_KEY).
5: Propagated OwnerThe class ID and the attribute ID of the lead class
attribute.
1CMDB_ATTR_CREATE_MODE_OPENAnyone can specify a value for the
attribute.
2CMDB_ATTR_CREATE_MODE_PROTECTEDOnly users with permissions can
CMDBSetMultipleInstances function
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
CMDBSetMultipleInstances function
The CMDBSetMultipleInstances function sets attribute values for CI or
relationship instances in the specified dataset.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBSetMultipleInstances(
ARControlStruct
*control,
const ARNameType
datasetId,
const CMDBInstanceList
*instances,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Chapter 4
C API functions
135
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
CMDBSetServerPort function
CMDBSetServerPort function sets the TCP and RPC port number information for
the BMC Atrium CMDB server.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBSetServerPort(
ARControlStruct
*control,
int
*tcpPort,
int
*rpcPort,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
tcpPortThe TCP port number that your program will use to communicate
with the BMC Remedy AR System server. If you do not specify this parameter
or provide 0 for the port number, your program will use the port number
supplied by the portmapper. This parameter is overridden by the ARTCPPORT
environment variable.
rpcPortThe RPC port number for the BMC Atrium Core server. Specify
390697 to use the admin thread. The default RPC port number is 390696.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
136
CMDBStartJobRun function
CMDBStartJobRun function
The CMDBStartJobRun function starts an existing Reconciliation Engine job.
Before starting a job, make sure the job is defined and exists in the Active state. If
no job for the specified job name exists or the job is not Active, the
CMDBStartJobRun function returns an error. Only one instance of a specific job can
be executed at a given time.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBStartJobRun(
ARControlStruct
*control,
ARNameType
jobName,
CMDBClassQualList
*classQualList,
CMDBREDatasetList
*datasetList
ARNameType
jobRunId,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
datasetListThe list of dataset pairs, where the first one represents the
substitution dataset (working dataset) and the second represents the dataset
defined in the Reconciliation Engine job (defined dataset), for example, 2,
{BMC.IMPORT.CONFIG, BMC.SAMPLE}.
Return values
jobRunIdA unique job identifier.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
Chapter 4
C API functions
137
CMDBSynchMetaData function
The CMDBSynchMetaData function creates BMC Remedy AR System forms from
the metadata instance in the OBJSTR:Class and OBJSTR:AttributeDefinition
forms.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBSynchMetaData(
ARControlStruct
*control,
ARNameType
pendingId,
CMDBClassNameIdList
*classNameIdList,
ARStatusList
*status)
Input arguments
controlThe control record for the operation, which contains information
about the user requesting the operation and the server on which the operation
is to be performed.
Return values
classNameIDListThe list of classes that are successfully synchronized with
the system. The classNameID argument contains the namespace name and the
unique class name.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
138
CMDBSystemInit function
CMDBSystemInit function
The CMDBSystemInit function performs server- and network-specific
initialization operations for internal use by BMC.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBSystemInit(
ARPropList
*propList,
ARStatusList
*status)
Return values
propListA list of properties that need to be initialized.
statusA list of zero or more notes, warnings, or errors generated from a call
of this function.
CMDBTermination function
The CMDBTermination function performs environment-specific cleanup routines
and disconnects from the session. All API programs that interact with the Class
Manager session should call this function upon completing work in the session.
Synopsis
#include "ar.h"
#include "arextern.h"
#include "cmdb.h"
int CMDBTermination(
ARControlStruct
*control,
ARStatusList
*status)
Input argument
controlThe control record for the operation, which contains information about
the user requesting the operation and the server on which the operation is to be
performed.
Return value
statusA list of zero or more notes, warnings, or errors generated from a call of
this function.
Chapter 4
C API functions
139
140
Chapter
This section provides reference information for the C API data structures.
The following topics are provided:
141
142
143
CMDBAttributeGetStruct
CMDBAttributeLimit
CMDBAttributeLimitList
CMDBAttributeNameId
CMDBAttributeValueList
CMDBAttributeValueListList
CMDBAttributeValueStruct
CMDBAuditInfoStruct
CMDBAuditValueList
CMDBAuditValueListList
CMDBSortList
CMDBSortStruct
CMDBWeakPropagatedAttrs
CMDBWeakPropagatedAttrsList
CMDBItemTypeAttribute
CMDBItemTypeClass
CMDBExportItem
CMDBExportItemList
CMDBExportItemStruct
CMDBImportItem
CMDBXMLExportItemList
CMDBImportItemList
CMDBImportItemStruct
CMDBXMLImportItemList
CMDBFederatedActivateInfo
CMDBFederatedARInfo
CMDBVersionInfo
CMDBVersionInfoList
144
CMDBClassRelationship
CMDBClassTypeInfo
CMDBIndexList
CMDBIndexStruct
CMDBClassNameId
CMDBClassNameIdList
CMDBInstanceList
CMDBInstanceStruct
CMDBQualifierStruct
CMDBGetObjectList
CMDBGetObjectStruct
CMDBGetRelationList
CMDBGetRelationStruct
CMDBGraphAdjacentList
CMDBGraphAdjacentStruct
CMDBGraphList
CMDBGraphStruct
CMDBGraphWalkObjectList
CMDBGraphWalkObjectStruct
CMDBGraphWalkQueryStruct
CMDBGraphWalkSelectorAndFilterList
CMDBGraphWalkSelectorAndFilterStruct
CMDBGraphWalkRelation
CMDBGraphWalkRelationList
CMDBGraphWalkResultStruct
CMDBGraphWalkStateStruct
CMDBQueryArithOpStruct
CMDBQueryAttributeName
CMDBQueryCardinality
CMDBQueryObject
CMDBQueryObjectList
CMDBQueryObjectSelectorList
CMDBQueryObjectSelectorStruct
CMDBQueryQualifierAndOrStruct
CMDBQueryQualifierSetOpStruct
CMDBQueryQualifierSimpleOpStruct
CMDBQueryQualifierStruct
CMDBQueryQualifierValueSetStruct
CMDBQueryQualifierValueStruct
CMDBQueryResultGraph
CMDBQuerySortList
CMDBQuerySortStruct
CMDBQueryStruct
CMDBStdRelationship
CMDBStdRelationshipList
CMDBRelationshipResultList
CMDBEdgeListList
CMDBNodeList
CMDBNodeListList
CMDBGraphQueryResult
CMDBNestedQueryStruct
145
CMDBREClassQualList
CMDBREClassQualStruct
CMDBREDatasetList
CMDBREDatasetPair
CMDBREJobRunInfo
CMDBREJobRunInfoList
CMDBAttributeGetStruct structure
The CMDBAttributeGetStruct structure holds the attributes to retrieve.
typedef struct CMDBAttributeGetStruct
{
unsigned int
type;
union
{
ARNameList attributeNameList;
} u;
} CMDBAttributeGetStruct;
attributeNameList
146
CMDBAttributeLimit structure
CMDBAttributeLimit structure
The CMDBAttributeLimit structure holds the data limit definitions for an
attribute of any data type.
typedef struct CMDBAttributeLimit
{
unsigned int dataType;
union
{
struct
{
int
rangeLow;
int
rangeHigh;
} integerLimits;
struct
{
int
maxLength;
char
*format;
unsigned int
menuStyle;
ARNameType
charMenu;
char
*pattern;
unsigned int
qbeMatchOperation;
} charLimits;
struct
{
double
rangeLow;
double
rangeHigh;
int
precision;
} realLimits;
struct
{
char
*rangeLow;
char
*rangeHigh;
int
precision;
} decimalLimits;
struct
{
int
minDate;
int
maxDate;
} dateLimits;
struct
{
unsigned int listStyle;
union
{
ARNameList
regularList;
AREnumItemList
customList;
} u;
} enumLimits;
struct
{
char
*rangeLow;
Chapter 5 C API data structures
147
char
*rangeHigh;
int
precision;
ARCurrencyDetailList
functionalCurrencies;
ARCurrencyDetailList
allowableCurrencies;
} currencyLimits;
struct
{
unsigned long
maxSize;
ARNameType
attachmentPoolName;
} attachLimits;
} u;
}CMDBAttributeLimit;
148
Description
CMDB_ATTR_DATA_TYPE_NULL
CMDB_ATTR_DATA_TYPE_
KEYWORD
CMDB_ATTR_DATA_TYPE_
INTEGER
CMDB_ATTR_DATA_TYPE_REAL
CMDB_ATTR_DATA_TYPE_CHAR
CMDB_ATTR_DATA_TYPE_DIARY
CMDB_ATTR_DATA_TYPE_ENUM
CMDB_ATTR_DATA_TYPE_
TIME
10
CMDB_ATTR_DATA_TYPE_
DECIMAL
11
CMDB_ATTR_DATA_TYPE_
ATTACH
An attachment attribute.
CMDBAttributeLimit structure
Description
12
CMDB_ATTR_DATA_TYPE_
CURRENCY
A currency attribute.
13
CMDB_ATTR_DATA_TYPE_DATE
14
CMDB_ATTR_DATA_TYPE_TIME_
OF_DAY
37
CMDB_ATTR_DATA_TYPE_
ATTACH_POOL
NOTE
Data types represented by values not in Table 5-2 are either unsupported or
display fields.
Integer limits
The integerLimits structure holds data limit definitions for an attribute of the
integer data type. It consists of the following elements:
rangeLow
rangeHigh
Character limits
The charLimits structure holds data limit definitions for an attribute of the
character data type. It consists of the following elements:
maxLength
format
Real limits
The realLimits structure holds data limit definitions for an attribute of the real
data type. It consists of the following elements:
rangeLow
rangeHigh
precision
149
Decimal limits
The decimalLimits structure holds data limit definitions for an attribute of the
decimal data type. It consists of the following elements:
rangeLow
rangeHigh
precision
Date limits
The dateLimits structure holds data limit definitions for an attribute of the date
data type. It consists of the following elements:
minDate
maxDate
Enum limits
The enumLimits structure holds data limit definitions for an attribute of the enum
data type. It consists of the following element:
regularList
Currency limits
The currencyLimits structure holds data limit definitions for an attribute of the
currency data type. It consists of the following elements:
rangeLow
rangeHigh
precision
functionalCurrencies
allowableCurrencies
150
CMDBAttributeLimitList structure
Attachment limits
The attachLimits structure holds data limit definitions for an attribute of the
attachment data type. It consists of the following elements:
maxSize
attachmentPoolName
CMDBAttributeLimitList structure
The CMDBAttributeLimitList structure holds a list of data limit definitions for
attributes.
typedef struct CMDBAttributeLimitList
{
unsigned int
numItems;
CMDBAttributeLimit
*limitList;
} CMDBAttributeLimitList;
limitList
CMDBAttributeNameId structure
The CMDBAttributeNameId structure holds the namespace name and the class
name information for a class.
typedef struct CMDBAttributeNameId
{
ARNameType
namespaceName;
ARNameType
className;
ARNameType
attributeName;
} CMDBAttributeNameId;
151
CMDBAttributeValueList structure
The CMDBAttributeValueList structure holds a list of values for an attribute.
typedef struct CMDBAttributeValueList
{
unsigned int
numItems;
CMDBAttributeValueStruct *attributeValueList;
} CMDBAttributeValueList;
CMDBAttributeValueListList structure
The CMDBAttributeValueListList structure holds a list of values for an
attributes list.
typedef struct CMDBAttributeValueListList
{
unsigned int
numItems;
CMDBAttributeValueList *attributeValueListList;
} CMDBAttributeValueListList;
CMDBAttributeValueStruct structure
The CMDBAttributeValueStruct structure holds values for attributes.
typedef struct CMDBAttributeValueStruct
{
ARNameType
attributeName;
ARValueStruct
attributeValue;
} CMDBAttributeValueStruct;
152
CMDBAuditInfoStruct structure
CMDBAuditInfoStruct structure
The CMDBAuditInfoStruct data structure holds the audit information to set audit
options for the class.
typedef struct CMDBAuditInfoStruct
{
unsigned int
type;
CMDBQualifierStruct
qual;
union {
ARNameType
logForm;
} u;
CMDB_CLASS_AUDITCHANGE_MASK
} CMDBAuditInfoStruct;
auditMask;
qual
logForm
auditMask
153
CMDBAuditValueList structure
The CMDBAuditValueList data structure holds a list of audit values to retrieve.
typedef struct CMDBAuditValueList
{
unsigned int
operation;
ARAccessNameType
changedBy;
ARTimestamp
auditTimestamp;
ARNameList
attrNameChangeList;
CMDBAuditValueList *attrAuditValueList;
} CMDBAuditValueList;
changedBy
auditTimestamp
attrNameChangeList
attrAuditValueList
154
CMDBAuditValueListList structure
CMDBAuditValueListList structure
The CMDBAuditValueListList data structure holds a list of audit values list to
retrieve.
typedef struct CMDBAuditValueListList
{
unsigned int
numItems;
CMDBAuditValueList *attrAuditValueList;
} CMDBAuditValueListList;
attrAuditValueList
CMDBClassNameId structure
The CMDBClassNameId structure holds the namespace name and the class name
information for a class.
typedef struct CMDBClassNameId
{
ARNameType
namespaceName;
ARNameType
className;
} CMDBClassNameId;
CMDBClassNameIdList structure
The CMDBClassNameIdList structure holds a list of CMDBClassNameId structures.
typedef struct CMDBClassNameIdList
{
unsigned int
numItems;
CMDBClassNameId *classNameIdList;
} CMDBClassNameIdList;
155
CMDBClassRelationship structure
The CMDBClassRelationship structure holds the relationship information of the
CI classes.
typedef struct CMDBClassRelationship
{
CMDBClassNameID
relClassNames[2];
ARNameType
roleNames[2];
unsigned int
cardinality;
ARBoolean
isRole2WeakReference;
CMDBWeakPropagatedAttrsList
weakPropagatedAttrsList;
ARBoolean
cascadeDelete;
} CMDBClassRelationship;
isRole2WeakReference
156
CMDBClassTypeInfo structure
CMDBClassTypeInfo structure
The CMDBClassTypeInfo structure holds the class type information.
typedef struct CMDBClassTypeInfo
{
unsigned int
classType;
union
{
CMDBClassRelationship
relationshipInfo;
} u;
} CMDBClassTypeInfo;
relationshipInfo
157
CMDBExportItem structure
The CMDBExportItem data structure holds the items to export for the specified
item type.
NOTE
This is a legacy structure of the BMC Atrium CMDB API, and has been replaced by
newer functions, CMDBExportData and CMDBExportDef.
typedef CMDBExportItem
{
unsigned int itemType;
union
{
CMDBItemTypeClass
CMDBItemTypeAttribute
}
}CMDBExportItem;
classItem;
attributeItem;
classItem
attributeItem
158
CMDBExportItemList structure
CMDBExportItemList structure
The CMDBExportItemList data structure holds a list of CMDBExportItemStruct
structures.
NOTE
This is a legacy structure of the BMC Atrium CMDB API, and has been replaced by
newer functions, CMDBExportData and CMDBExportDef.
typedef struct CMDBExportItemList
{
unsigned int
numItems;
CMDBExportItemStruct
*exportItemList;
} CMDBExportItemList;
CMDBExportItemStruct structure
The CMDBExportItemStruct data structure holds a single item to export.
NOTE
This is a legacy structure of the BMC Atrium CMDB API, and has been replaced by
newer functions, CMDBExportData and CMDBExportDef.
typedef struct CMDBExportItemStruct
{
unsigned int
itemType;
CMDBClassNameId
classNameId;
union {
char
*qualifier;
unsigned long
exportOption;
} u;} CMDBExportItemStruct;
159
classNameId
qualifier
exportOption
160
CMDBFederatedActivateInfo structure
CMDBFederatedActivateInfo structure
The CMDBFederatedActivateInfo data structure holds the federated instance
data activation information to retrieve.
typedef struct CMDBFederatedActivateInfo
{
unsigned int actionType;
unsigned int accessType;
union
{
CMDBFederatedARInfo arInfo;
char
*accessString;
} u;
} CMDBFederatedActivateInfo;
accessType
arInfo
accessString
161
CMDBFederatedARInfo structure
The CMDBFederatedARInfo data structure holds the BMC Remedy AR System
related federated interface information to retrieve.
typedef struct CMDBFederatedARInfo
{
unsigned int
arAccessType;
ARNameType
server;
ARNameType
form;
ARNameType
view;
char
*qualifier;
char
*url;
} CMDBFederatedARInfo;
server
form
view
qualifier
url
162
CMDBGetObjectList structure
CMDBGetObjectList structure
The CMDBGetObjectList data structure holds a list of CI instances.
typedef struct CMDBGetObjectList
{
unsigned int
numItems;
CMDBGetObjectStruct
*objectList;
} CMDBGetObjectList;
objectList
CMDBGetObjectStruct structure
The CMDBGetObjectStruct data structure holds a CI instance.
typedef struct CMDBGetObjectStruct
{
CMDBClassNameId
classNameId;
ARNameType
instanceId;
CMDBAttributeValueList attributeValueList;
} CMDBGetObjectStruct;
CMDBGetRelationList structure
The CMDBGetRelationList data structure holds a list of relationships.
typedef struct CMDBGetRelationList
{
unsigned int
numItems;
CMDBGetRelationStruct
*relationList;
} CMDBGetRelationList;
163
CMDBGetRelationStruct structure
The CMDBGetRelationStruct data structure holds a single relationship.
typedef struct CMDBGetRelationStruct
{
CMDBClassNameId
classNameId;
ARNameType
instanceId;
ARNameType
roleNames[2];
CMDBClassNameId
relatedClassNames[2];
ARNameType
relatedClassIds[2];
ARNameType
relatedInstanceIds[2];
CMDBAttributeValueList attributeValueList;
} CMDBGetRelationStruct;
CMDBGraphAdjacentList structure
The CMDBGraphAdjacentList data structure holds a list of adjacent nodes in
CMDBGraphAdjacentStruct.
typedef struct CMDBGraphAdjacentList
{
unsigned int
numItems;
CMDBGraphAdjacentStruct *adjacents;
} CMDBGraphAdjacentList;
adjacents
164
CMDBGraphAdjacentStruct structure
CMDBGraphAdjacentStruct structure
The CMDBGraphAdjacentStruct data structure holds an adjacent node.
typedef struct CMDBGraphAdjacentStruct
{
CMDBClassNameId
relClassNameId;
CMDBQualifierStruct
relQual;
CMDBAttributeGetStruct relGetAttribute;
CMDBClassNameId
objClassNameId;
ARNameType
extensionId;
CMDBQualifierStruct
objQual;
CMDBAttributeGetStruct objGetAttribute;
} CMDBGraphAdjacentStruct;
CMDBGraphList structure
The CMDBGraphList data structure is used to define the query graph list in the
CMDBGraphQuery function.
typedef struct CMDBGraphList
{
unsigned int
numItems;
CMDBGraphStruct
*graph;
} CMDBGraphList;
165
CMDBGraphStruct structure
The CMDBGraphStruct data structure holds each graph node in the query graph.
typedef struct CMDBGraphStruct
{
CMDBClassNameId
classNameId;
ARNameType
extensionId;
CMDBGraphAdjacentList
adjacentList;
} CMDBGraphStruct;
CMDBGraphWalkObjectList structure
The CMDBGraphWalkObjectList structure holds a list of
CMDBGraphWalkObjectStruct structures. This structure is for internal use only.
typedef struct CMDBGraphWalkObjectList
{
CMDBClassNameIdList
classNameIdList;
unsigned int
numItems;
CMDBGraphWalkObjectStruct *objectList;
}CMDBGraphWalkObjectList;
166
CMDBGraphWalkObjectStruct structure
CMDBGraphWalkObjectStruct structure
The CMDBGraphWalkObjectStruct structure holds the information about the
objects walked in the relationship graph, which is required to retrieve instances in
chunks. This structure is for internal use only.
typedef struct CMDBGraphWalkObjectStruct
{
unsigned int
classNameIdIndex;
ARNameType
instanceId;
ARBoolean
bNeedToWalkFurther;
unsigned int
level;
}CMDBGraphWalkObjectStruct;
level
CMDBGraphWalkQueryStruct structure
The CMDBGraphWalkQueryStruct structure holds the parameters for the query.
This structure is used in the CMDBGraphWalkBegin function to set up the starting
node in the relationship graph for the query.
typedef struct CMDBGraphWalkQueryStruct
{
ARNameType
datasetId;
unsigned int
datasetMask;
CMDBGraphWalkRelation
walkRelation;
unsigned int
numLevels;
unsigned int
maxRetrieve;
CMDB_GRAPH_WALK_QUERY_MODE
queryMode;
CMDBGraphWalkSelectorAndFilterList objSelectorAndFilterList;
}CMDBGraphWalkQueryStruct;
167
walkRelation
numLevels
maxRetrieve
queryMode
168
CMDBGraphWalkRelation structure
CMDBGraphWalkRelation structure
The CMDBGraphWalkRelation structure holds information about the relationship
to walk recursively, the qualification for the query, and the attributes to retrieve.
typedef struct CMDBGraphWalkRelation
{
CMDBClassNameId
classNameId;
ARNameList
*getAttrList;
CMDBQualifierStruct
*qualification;
unsigned int
direction;
ARBoolean
isImpactGraphWalk;
}CMDBGraphWalkRelation;
isImpactGraphWalk
169
CMDBGraphWalkRelationList structure
The CMDBGraphWalkRelationList structure holds information about the
relationship graph to walk and the type of attributes to retrieve in the query.
typedef struct CMDBGraphWalkRelationList
{
CMDB_GRAPH_WALK_ATTRIBUTE_FLAG_DEFAULT
unsigned int
CMDBGraphWalkRelation
}CMDBGraphWalkRelation;
attrFlag;
numItems;
*walkRelationList;
attributes
(CMDB_GRAPH_WALK_ATTRIBUTE_FLAG_DEFAULT_
NONHIDDEN).
2 If attributes omitted, select all attributes, hidden
and non-hidden
(CMDB_GRAPH_WALK_ATTRIBUTE_FLAG_DEFAULT_
ALL).
numItems
walkRelationList
170
CMDBGraphWalkResultStruct structure
CMDBGraphWalkResultStruct structure
The CMDBGraphWalkResultStruct structure holds the graph walk query results.
typedef struct CMDBGraphWalkResultStruct
{
CMDBInstanceList
relationList;
CMDBInstanceList
objectList;
}CMDBGraphWalkResultStruct;
171
CMDBGraphWalkSelectorAndFilterList
structure
The CMDBGraphWalkSelectorAndFilterList structure holds a list of attributes of
CMDBGraphWalkSelectorAndFilterStruct structures for a specified object.
typedef struct CMDBGraphWalkSelectorAndFilterList
{
CMDB_GRAPH_WALK_OBJECT_FLAG_DEFAULT
objFlag;
CMDB_GRAPH_WALK_ATTRIBUTE_FLAG_DEFAULT
attrFlag;
unsigned int
numItems;
CMDBGraphWalkSelectorAndFilterStruct *objSelectorAndFilterList;
}CMDBGraphWalkSelectorAndFilterList;
nothing
(CMDB_GRAPH_WALK_OBJECT_FLAG_DEFAULT_NONE).
1 If no specific objects are listed in the filter, select all
objects walked
(CMDB_GRAPH_WALK_OBJECT_FLAG_DEFAULT_ALL).
attrFlag
nothing
(CMDB_GRAPH_WALK_ATTRIBUTE_FLAG_DEFAULT_
NONE).
1 If no specific attributes are listed in the filter, select
numItems
172
CMDBGraphWalkSelectorAndFilterStruct structure
CMDBGraphWalkSelectorAndFilterStruct
structure
The CMDBGraphWalkSelectorAndFilterStruct structure holds the filter criteria
and the list of attributes to retrieve in the graph walk query.
typedef struct CMDBGraphWalkSelectorAndFilterStruct
{
CMDBClassNameId
classNameId;
ARNameList
*attributes;
CMDBQualifierStruct
*qualification;
} CMDBGraphWalkSelectorAndFilterStruct;
173
CMDBGraphWalkStateStruct structure
The CMDBGraphWalkStateStruct structure holds the information about all the
objects walked in the graph walk query. This structure is used for query chunking
purposes. Therefore, the default value of the structure members should not be
modified.
typedef struct CMDBGraphWalkStateStruct
{
CMDBGraphWalkQueryStruct
queryStruct;
CMDBGraphWalkObjectList
walkedObjectList;
ARBoolean
hasNextChunk;
unsigned int
firstRetrieve;
unsigned int
nextObjectIndex;
}CMDBGraphWalkStateStruct;
walkedObjectList
hasNextChunk
firstRetrieve
nextObjectIndex
174
CMDBImportItem structure
CMDBImportItem structure
NOTE
This is a legacy structure of the BMC Atrium CMDB API, and has been replaced by
newer functions, CMDBImportData and CMDBImportDef.
The CMDBImportItem data structure holds the items to import for the specified
item type.
typedef CMDBImportItem
{
unsigned int itemType;
union
{
CMDBItemTypeClass
CMDBItemTypeAttribute
}
}CMDBImportItem;
classItem;
attributeItem;
classItem
attributeItem
CMDBImportItemList structure
NOTE
This is a legacy structure of the BMC Atrium CMDB API, and has been replaced by
newer functions, CMDBImportData and CMDBImportDef.
The CMDBImportItemList data structure holds a list of items to import.
typedef struct CMDBImportItemList
{
unsigned int
numItems;
CMDBImportItemStruct
*importItemList;
} CMDBImportItemList;
175
CMDBImportItemStruct structure
NOTE
This is a legacy structure of the BMC Atrium CMDB API, and has been replaced by
newer functions, CMDBImportData and CMDBImportDef.
The CMDBImportItemStruct data structure holds the items to import.
typedef struct CMDBImportItemStruct
{
unsigned int
itemType;
CMDBClassNameId
classNameId;
unsigned long
importOption;
} CMDBImportItemStruct;
176
CMDBIndexList structure
classNameId
importOption
CMDBIndexList structure
The CMDBIndexList structure holds index information for the class.
typedef struct CMDBIndexList
{
unsigned int
numItems;
CMDBIndexStruct *indexList;
} CMDBIndexList;
177
CMDBIndexStruct structure
The CMDBIndexStruct structure holds the attributes to index.
typedef struct CMDBIndexStruct
{
unsigned int
numAttributes;
ARNameType
attributeName[AR_MAX_INDEX_subclasses];
ARBoolean
unique;
ARBoolean
isPrimaryKey;
ARNameType
indexName;
} CMDBIndexStruct;
isPrimaryKey
indexName
CMDBInstanceList structure
The CMDBInstanceList structure holds a list of CMDBInstanceStruct structures.
typedef struct CMDBInstanceList
{
unsigned int
numItems;
CMDBInstanceStruct
*instanceList;
} CMDBInstanceList;
instanceList
178
CMDBInstanceStruct structure
CMDBInstanceStruct structure
The CMDBInstanceStruct structure holds a list of attribute values for a specified
class and instance.
typedef struct CMDBInstanceStruct
{
CMDBClassNameId
classNameId;
ARNameType
instanceId;
CMDBAttributeValueList attributeValueList;
} CMDBInstanceStruct;
CMDBItemTypeAttribute structure
The CMDBItemTypeAttribute data structure holds a list of attribute information.
typedef struct CMDBItemTypeAttribute
{
CMDBClassNameId classNameId;
ARNameList
attribNameList;
}CMDBItemTypeAttribute;
CMDBItemTypeClass structure
The CMDBItemTypeClass data structure holds the class name information.
typedef struct CMDBItemTypeClass
{
CMDBClassNameId classNameId;
}CMDBItemTypeClass;
179
CMDBNestedQueryStruct structure
The CMDBNestedQueryStruct structure holds the query condition and class details
to select from the result list.
typedef struct CMDBNestedQueryStruct
{
CMDBQueryObjectList
*queryObjects;
CMDBQueryObjectList
*queryObjectsOptional;
CMDBQueryObjectSelector
*queryObjectToSelect;
} CMDBNestedQueryStruct;
180
CMDBQualifierStruct structure
CMDBQualifierStruct structure
The CMDBQualifierStruct structure holds the qualifier structure for the query
based on the qualifier type that is specified.
typedef struct CMDBQualifierStruct
{
unsigned int
qualifierType;
union
{
char
*qualifierString;
ARQualifierStruct
qualifierStruct;
} u;
} CMDBQualifierStruct;
qualifierString
qualifierStruct
CMDBQueryArithOpStruct structure
The CMDBQueryArithOpStruct structure is used to specify the arithmetic
operation to perform in the query qualification. This structure also holds the left
and right operands to use in the qualification.
typedef struct CMDBQueryArithOpStruct
{
CMDB_QUERY_QUAL_ARITH_OP_TYPE
struct CMDBQueryQualifierValueStruct
struct CMDBQueryQualifierValueStruct
} CMDBQueryArithOpStruct;
operation;
*operandLeft;
*operandRight;
181
operandLeft
operandRight
CMDBQueryAttributeName structure
The CMDBQueryAttributeName structure holds the attribute name to return in the
query.
typedef struct CMDBQueryAttributeName
{
ARNameType
ARNameType
} CMDBQueryAttributeName;
classAlias;
attributeName;
attributeName
182
CMDBQueryCardinality
CMDBQueryCardinality
The CMDBQueryCardinality structure holds the range definition for the
relationship to walk in the query. If you require the CMDBQueryByPath function
to return all BMC_ComputerSystem CIs that are connected to three or less
BMC_DiskDrive CIs, set the minCount member to 1 and the MaxCount member to
3.
typedef struct CMDBQueryCardinality
{
int
int
}CMDBQueryCardinality;
minCount;
maxCount;
maxCount
183
CMDBQueryObject structure
The CMDBQueryObject structure holds the qualification for the query, such as
whether to retrieve a CI or a relationship class and how many levels to walk in the
graph.
typedef struct CMDBQueryObject
{
CMDBClassNameId
classNameId;
ARNameType
alias;
ARNameType
sourceNodeAlias;
CMDBQueryQualifierStruct
*qualification;
CMDB_QUERY_OBJECT_TYPE
queryObjectType;
CMDB_QUERY_JOIN_TYPE
joinType;
CMDBQueryQualifierStruct
*joinQualification;
union
{
CMDBQueryObjectRelationship relationshipInfo
} u;
} CMDBQueryObject;
sourceNodeAlias
qualification
queryObjectType
184
CMDBQueryObject structure
joinType
joinQualification
relationshipInfo
185
CMDBQueryObjectList structure
The CMDBQueryObjectList structure holds a list of CMDBQueryObject structures.
Depending on the complexity of the query, CMDBQueryObjectList can have
multiple CMDBQueryObject structures. The first query object in the list should
always be a CI, followed by a relationship object, and then a CI object again. This
object structure is represented by C-->(R-->C)*, where (R-->C) can occur more than
once.
typedef struct CMDBQueryObjectList
{
unsigned int
numItems;
CMDBQueryObject
*queryObjectlist;
} CMDBQueryObjectList;
CMDBQueryObjectRelationship structure
The CMDBQueryObjectRelationship structure holds the information about the
relationship, such as the direction and the number of relationships to traverse in
the query.
typedef struct CMDBQueryObjectRelationship
{
unsigned int
direction;
CMDBQueryCardinality
downstreamCardinality;
} CMDBQueryObjectRelationship;
source (on the left), arrow coming out from the node
(CMDB_RELATIONSHIP_DIRECTION_OUT).
1Relationship of a CI where the given CI is the
186
CMDBQueryObjectSelectorList structure
CMDBQueryObjectSelectorList structure
The CMDBQueryObjectSelectorList structure holds a list of
CMDBQueryObjectSelector structures. Depending on the list of attributes and
values requested in the query result, the CMDBQueryObjectSelectorList structure
can have multiple CMDBQueryObjectSelector items.
typedef struct CMDBQueryObjectSelectorList
{
unsigned int
numItems;
CMDBQueryObjectSelector
*queryObjectSelectorList;
unsigned int
flags;
} CMDBQueryObjectSelectorList;
attributes
(CMDB_QUERY_OBJECTSELECTOR_FLAG_DEFAULT
_ALL).
187
CMDBQueryObjectSelectorStruct structure
The CMDBQueryObjectSelector structure holds the list of attributes to retrieve
from the query result.
typedef struct CMDBQueryObjectSelectorStruct
{
ARNameType
alias;
ARNameList
*attributes;
} CMDBQueryObjectSelectorStruct;
attributes
CMDBQueryQualifierAndOrStruct structure
The CMDBQueryQualifierAndOrStruct structure holds the left and right
operands of a query.
typedef struct CMDBQueryQualifierAndOrStruct
{
struct CMDBQueryQualifierStruct *operandLeft;
struct CMDBQueryQualifierStruct *operandRight;
} CMDBQueryQualifierAndOrStruct;
operandRight
188
CMDBQueryQualifierSetOpStruct structure
CMDBQueryQualifierSetOpStruct structure
The CMDBQueryQualifierSetOpStruct structure is used to specify the attribute
and right operand for an IN or NOT IN type of operation.
typedef struct CMDBQueryQualifierSetOpStruct
{
unsigned int
operation;
ARNameType
attribute;
CMDBQueryQualifierValueSetStruct
*operandRight;
} CMDBQueryQualifierSetOpStruct;
attribute
operandRight
189
CMDBQueryQualifierSimpleOpStruct structure
The CMDBQueryQualifierSimpleOpStruct structure holds the attribute and the
right operand for a SIMPLE type of operation.
typedef struct CMDBQueryQualifierSimpleOpStruct
{
unsigned int
operation;
ARNameType
attribute;
CMDBQueryQualifierValueStruct
*operandRight;
} CMDBQueryQualifierSimpleOpStruct;
190
CMDBQueryQualifierSimpleOpStruct structure
attribute
operandRight
191
CMDBQueryQualifierStruct structure
The CMDBQueryQualifierStruct structure holds the qualification for the query.
CIs and relationships that the query returns depend on the qualification specified
in this structure. This is a top-level structure that holds the query qualifications.
typedef struct CMDBQueryQualifierStruct
{
CMDB_QUERY_QUAL_OP_TYPE
union
{
CMDBQueryQualifierAndOrStruct
struct CMDBQueryQualifierStruct
CMDBQueryQualifierSimpleOpStruct
CMDBQueryQualifierSetOpStruct
} u;
} CMDBQueryQualifierStruct;
operation;
andor;
*notQual;
*simpleOp;
*setOp;
andor
notQual
192
CMDBQueryQualifierValueSetStruct structure
simpleOp
setOp
CMDBQueryQualifierValueSetStruct structure
The CMDBQueryQualifierValueSetStruct structure holds literal values or the
query statement for a nested query.
typedef struct CMDBQueryQualifierValueSetStruct
{
unsigned int type;
union
{
ARValueList
valueSet;
struct CMDBNestedQueryStruct
*query;
} u;
} CMDBQueryQualifierValueSetStruct;
nested query
(CMDB_QUERY_QUAL_VALUESET_TYPE_VALUESET).
2 The inner query to use in the nested query statement
(CMDB_QUERY_QUAL_VALUESET_TYPE_QUERY).
valueSet
The list of literal values for the SET query statement, for
example, Model IN Microsoft Windows XP,
Microsoft Windows 2003, Microsoft Windows
2000. This member is filled in if type is set to 1.
query
193
CMDBQueryQualifierValueStruct structure
The CMDBQueryQualifierValueStruct structure holds the set of values and
query conditions for a nested query.
typedef struct CMDBQueryQualifierValueStruct
{
CMDB_QUERY_QUAL_VALUE_TYPE
type;
union
{
ARValueStruct
value;
CMDBQueryAttributeName
attributeName;
CMDBQueryArithOpStruct
arithOp;
} u;
} CMDBQueryQualifierValueStruct;
value
attributeName
arithOp
194
CMDBQueryResultGraph
CMDBQueryResultGraph
The CMDBQueryResultGraph structure is used to return the query results in a list
or a graph format depending on the format requested.
typedef struct CMDBQueryResultGraph
{
CMDB_QUERY_RESULT_FORMAT_TYPE
formatType;
unsigned int
numItems;
unsigned int
*numMatches;
ARNameList
aliasOrderForListFormat;
union
{
CMDBInstanceList *instanceListList;
CMDBGraphQueryResult *graphQueryResult;
} u;
} CMDBQueryResultGraph;
format
(CMDB_QUERY_RESULT_STRUCT_FORMAT_LIST).
1The query results are divided in two parts: a
list of CI nodes and a list of relationship edges,
which helps in constructing a CI and relationship
graph
(CMDB_QUERY_RESULT_STRUCT_FORMAT_CMDB_G
RAPH).
2The query results are returned in a graph
numItems
numMatches
195
aliasOrderForListFormat
instanceListList
graphQueryResult
196
CMDBQuerySortStruct
CMDBQuerySortStruct
The CMDBQuerySortStruct structure is used to sort the results that the CMDBQuery
function returns, based on the attribute specified in the CMDBQuerySortStruct
structure.
typedef struct CMDBQuerySortStruct
{
ARNameType
alias;
ARNameType
attributeName;
unsigned int
sortorder;
} CMDBQuerySortStruct;
attributeName
sortOrder
CMDBQuerySortList
The CMDBQuerySortList structure holds a list of CMDBQuerySortStruct
structures.
typedef struct CMDBQuerySortList
{
unsigned int
numItems;
CMDBQuerySortStruct *querySortList;
} CMDBQuerySortList;
197
CMDBQueryStruct structure
The CMDBQueryStruct structure holds a list of query objects with qualification for
the instances to retrieve. This is a top-level structure, which is used in the
CMDBQueryByPath function.
typedef struct CMDBQueryStruct
{
ARNameType
unsigned int
CMDBQueryObjectList
CMDBQueryObjectOptionalList
CMDBQueryObjectSelectorList
unsigned int
unsigned int
CMDB_QUERY_STRUCT_MASK_TYPE
CMDBQuerySortList
ARBoolean
} CMDBQueryStruct;
datasetId;
datasetMask;
*queryObjects;
*queryObjectsOptional;
*queryObjectsToSelect;
firstRetrieve;
maxRetrieve;
queryMask;
querySortList;
numMatches;
198
CMDBQueryStruct structure
maxRetrieve
queryMask
querySortList
numMatches
query.
FALSENo matched instances to return.
199
CMDBGraphQueryResult
The CMDBGraphQueryResult structure holds the results that the
CMDBQueryByPath function returns. The query returns the results in a graph
format or a linear format. When requested in a graph format, the query results are
grouped and stored in two parts: CIs and relationships.
If the query result contains a CI with two different relationships, the CI list will
includes only one entry for the specific CI. For example, if a BMC_Printer instance
is connected to two different BMC_ComputerSystem instances, the BMC_Printer
instance is listed only once.
The CMDBGraphQueryResult structure is a top-level result structure, which uses
CMDBNodeListList to store the list of CIs and CMDBEdgeListList to store the list
of relationships to return for the query results.
typedef struct CMDBGraphQueryResult
{
CMDBNodeListList
nodeListList;
CMDBEdgeListList
edgeListList;
} CMDBGraphQueryResult;
CMDBStdEdgeResult
The CMDBStdEdgeResult structure holds the relationship part of the query
result.
typedef struct CMDBStdEdgeResult
{
ARNameType
alias;
CMDBStdRelationshipList relationshipList;
} CMDBStdEdgeResult;
relationshipList
200
CMDBEdgeListList
CMDBEdgeListList
The CMDBEdgeListList structure holds a list of CMDBRelationshipResultList
structures that store the relationship part of the query result.
typedef struct CMDBEdgeListList
{
unsigned int
numItems;
CMDBRelationshipResultList *relationshipResultList;
} CMDBEdgeListList;
numItems
CMDBNodeList
The CMDBNodeList structure holds the CI part of the query result.
typedef struct CMDBNodeList
{
ARNameType
alias;
CMDBInstanceList instanceList;
} CMDBNodeList;
instanceList
201
CMDBNodeListList
The CMDBNodeListList structure holds a list of CMDBNodeList structures that
store the CI part of the query result.
typedef struct CMDBNodeListList
{
unsigned int
numItems;
CMDBNodeList
*nodeList;
} CMDBNodeListList;
CMDBRelationshipResult
The CMDBRelationshipResult structure holds the source instance ID, destination
instance ID, and a pointer to the relationship object for the relationship instances
returned in the query results for the specified CI.
typedef struct CMDBRelationshipResult
{
ARNameType
srcInstanceId;
ARNameType
destInstanceId;
CMDBInstanceStruct *relationshipInstance;
} CMDBRelationshipResult;
202
CMDBRelationshipResultList
CMDBRelationshipResultList
The CMDBRelationshipResultList structure holds a list of
CMDBRelationshipResult structures that store the relationship information for
the results returned by the query.
typedef struct CMDBRelationshipResultList
{
ARNameType
alias;
unsigned int
numItems;
CMDBRelationshipResult
*relationshipInstance;
} CMDBRelationshipResultList;
numItems
relationshipInstance
CMDBREClassQualList structure
The CMDBREClassQualList data structure holds a list of
CMDBREClassQualStruct structures.
typedef struct CMDBREClassQuaList
{
unsigned int
numItems;
CMDBREClassQualStruct
*classQualList;
}CMDBREClassQuaList;
classQualList
203
CMDBREClassQualStruct structure
The CMDBREClassQualStruct data structure holds information about the class
qualification.
typedef struct CMDREBClassQualStruct
{
ARNameType
classId;
CMDBQualifierStruct
*qual;
}CMDBREClassQualStruct;
CMDBREDatasetList structure
The CMDBREDatasetList data structure holds a list of CMDBREDatasetPair
structures.
typedef Struct CMDBREDatasetList
{
Unsigned int
numItems;
CMDBREDatasetPair* datasetList;
}CMDBREDatasetList;
datasetList
204
CMDBREDatasetPair structure
CMDBREDatasetPair structure
The CMDBREDatasetPair data structure holds information about the datasets to
use in the reconciliation job.
typedef Struct CMDBREDatasetPair
{
ARNameType workingDataset;
ARNameType dataset;
}CMDBREDatasetPair;
dataset
CMDBREJobRunInfo structure
The CMDBREJobRunInfo data structure holds information about a currently
running Reconciliation Engine job.
typedef struct CMDBREJobRunInfo
{
ARNameType
jobRunId;
ARNameType
jobInstanceId;
ARNameType
jobName;
ARTimestamp
startTime;
ARTimestamp
endTime;
unsigned int
jobState;
} CMDBREJobRunInfo;
205
CMDBREJobRunInfoList structure
The CMDBREJobRunInfoList data structure holds a list of Reconciliation Engine
jobs that are currently running.
typedef struct CMDBREJobRunInfoList
{
unsigned int
numItems;
CMDBREJobRunInfo
*jobRunList;
} CMDBREJobRunInfoList;
CMDBSortList structure
The CMDBSortList structure holds a list of attributes to sort.
typedef struct CMDBSortList
{
unsigned int
numItems;
CMDBSortStruct
*sortList;
} CMDBSortList;
sortList
206
CMDBSortStruct structure
CMDBSortStruct structure
The CMDBSortStruct structure holds the attribute to sort.
typedef struct CMDBSortStruct
{
ARNameType
attributeName;
unsigned int
sortOrder;
} CMDBSortStruct;
CMDBUIComponentInfo structure
The CMDBUIComponentInfo data structure holds the UI components to retrieve.
typedef struct CMDBUIComponentInfo
{
ARNameType
classId;
ARLocaleType
locale;
unsigned int
componentType;
ARNameType
componentId;
char
*tag1;
char
*tag2;
char
*tag3;
char
*tag4;
char
*tag5;
char
*tag6;
char
*tag7;
char
*encodedQual;
} CMDBUIComponentInfo;
207
componentType
208
CMDBUIComponentInfo structure
componentID
209
tag1
tag2
the icon.
CMDB_COMPONENT_TYPE_LOCALIZED_LABELUsed to
specify the attribute name of the localized string. This tag
is left blank if it is a label for a class.
CMDB_COMPONENT_TYPE_CMDB_SAVED_QUERYUsed to
210
CMDBUIComponentResult structure
tag3
type of the icon for the component type (for example, JPG,
BMP, or GIF).
CMDB_COMPONENT_TYPE_CMDB_SAVED_QUERYUsed to
tag4
tag5
tag6
tag7
encodedQual
CMDBUIComponentResult structure
The CMDBUIComponentResult data structure holds the component query result.
typedef struct CMDBUIComponentResult
{
ARNameType
instanceId;
CMDBUIComponentIno
componentInfo;
char
*dataString;
ARAttachStruct
*attachVal;
} CMDBUIComponentResult;
211
CMDBUIComponentResultList structure
The CMDBUIComponentResultList data structure holds the component query
result.
typedef struct CMDBUIComponentResultList
{
unsigned int
numItems;
CMDBUIComponentResult *componentResList;
} CMDBUIComponentResultList;
componentResultList
CMDBVersionInfo structure
The CMDBVersionInfo structure holds version information for the BMC Atrium
Core components.
typedef struct CMDBVersionInfo
{
ARNameType
applicationId;
ARNameType
applicationName;
unsigned int
majorVer;
unsigned int
minorVer;
unsigned int
maintenanceVer;
unsigned int
patchNum;
} CMDBVersionInfo;
212
CMDBVersionInfoList structure
CMDBVersionInfoList structure
The CMDBVersionInfoList structure holds a list of version information elements
for the CMDB component.
typedef struct CMDBVersionInfoList
{
unsigned int
numItems;
CMDBVersionInfo *versionInfoList;
} CMDBVersionInfoList;
CMDBWeakPropagatedAttrs structure
The CMDBWeakPropagatedAttrs structure holds a list of source and target
attributes to use for attribute value propagation when isRole2WeakReference is
TRUE.
The specified source and target attributes must already exist on the role one and
role two classes. This list describes the mapping of the attribute values from the
role one class to be propagated to the role two class.
typedef struct CMDBWeakPropagatedAttrs
{
ARNameType
sourceAttributeName;
ARNameType
targetAttributeName;
} CMDBWeakPropagatedAttrs;
213
CMDBWeakPropagatedAttrsList structure
The CMDBWeakPropagatedAttrsList structure holds a list of
CMDBWeakPropagatedAttrs structures.
typedef struct CMDBWeakPropagatedAttrsList
{
unsigned int
numItems;
CMDBWeakPropagatedAttrs
*attrsList;
} CMDBWeakPropagatedAttrsList;
CMDBXMLExportItemList structure
The CMDBXMLExportItemList data structure holds a list of items to export.
typedef struct CMDBXMLExportItemList
unsigned int
CMDBXMLExportItemStruct
}CMDBXMLExportItemList;
numItems;
*exportItemList;
214
CMDBXMLImportItemList structure
CMDBXMLImportItemList structure
The CMDBXMLImportItemList data structure holds a list of XML items to import.
typedef struct CMDBXMLImportItemList
unsigned int
numItems;
CMDBXMLImportItemStruct *importItemList;
}CMDBXMLImportItemList;
exportItemList
215
216
Appendix
cmdbdriver commands
217
Description
gc
get class
sc
set class
cc
create class
dc
delete class
glc
218
Description
ga
get attribute
sa
set attribute
ca
create
attribute
gma
get multiple
attributes
cma
create
multiple
attributes
Description
sma
set multiple
attributes
da
delete
attribute
Description
gi
get instance
si
set instance
ci
create
instance
di
delete
instance
gli
get list
instance
gmi
get multiple
instances
cmi
create
multiple
instances
gib
get instance
blob
gui
get user
interface
object
219
Description
sjr
cjr
cancel job
run
gjr
gljr
Description
gf
get
af
activate
220
Description
expdf
export def
impdf
import def
expdt
export data
impdt
import data
Table A-6: cmdbdriver commands for import and export C API functions (Sheet 2 of 2)
Command Full name
Description
xexpdf
Xexport def
xexpdt
Xexport data Exports the specified class data for a specific qualification in
XML format. This command corresponds with the
CMDBExportData C API function.
Description
qbp
query by
path
cqobj
create query Creates the query object for the Query By Path command.
object
cqq
create query Creates the query qualifications for the create query object
qual
command.
Description
sync
synch
ssp
set port
221
Description
dver
dr ver
bbet
bgntran
ebet
endran
gver
gver
gac
sudit copy
exp
export
imp
import
222
grq
cg
upgr
upgrade
expp
expand
param
rq
run qual
gwq
graph walk
query
Command full
name
What it does
init
init
term
term
h, ?
help
e, q
exit
log
login
Command full
name
What it does
rec
record
srec
stop rec
oout
open out
cout
close out
ex
execute
223
Command full
name
What it does
bl
bgn loop
el
end loop
Command full
name
What it does
lt
launch
lwt
launch wait
rwt
release wait
st
sleep
rst
random sleep
msst
msec sleep
224
Command
Command full
name
What it does
gsc
get conf
ssc
set conf
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Index
A
C
C API
See also C API data structures overview
compilers 34
compiling on HP machines 34
Index
225
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
C API (continued)
components 19
driver source code 29
header files 29
installation package 29
library files 30
library links 34
overview 19
C API attribute data structures
attachLimits 151
charLimits 149
CMDBAttributeGetStruct 146
CMDBAttributeLimit 147
CMDBAttributeLimitList 151
CMDBAttributeNameId 151
CMDBAttributeValueList 152
CMDBAttributeValueListList 152
CMDBAttributeValueStruct 152
CMDBSortList 206
CMDBSortStruct 207
CMDBWeakPropagatedAttrs 213
CMDBWeakPropagatedAttrsList 214
currencyLimits 150
dateLimits 150
decimalLimits 150
enumLimits 150
integerLimits 149
overview 144
realLimits 149
C API bulk entry transaction functions
CMDBBeginBulkEntryTransaction 72
CMDBEndBulkEntryTransaction 90
overview 67
C API class data structures
CMDBClassRelationship 156
CMDBClassTypeInfo 157
CMDBIndexList 177
CMDBIndexStruct 178
overview 144
C API copy functions 67
CopyCMDBInstanceStruct 67
CopyCMDBQueryStruct 67
C API data model functions
CMDBCreateAttribute 74
CMDBCreateClass 77
CMDBCreateMultipleAttributes 82
CMDBDeleteAttribute 86
CMDBDeleteClass 87
CMDBGetAttribute 94
CMDBGetClass 97
CMDBGetListClass 104
CMDBGetMultipleAttributes 107
226
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
C API instance data structures (continued)
CMDBClassNameId 155
CMDBClassNameIdList 155
CMDBInstanceList 178
CMDBInstanceStruct 179
CMDBQualifierStruct 181
overview 144
C API instance functions
CMDBCreateInstance 81
CMDBCreateMultipleInstances 85
CMDBDeleteInstance 88
CMDBDeleteMultipleInstances 89
CMDBGetCopyAuditData 100
CMDBGetInstance 102
CMDBGetInstanceBLOB 103
CMDBGetListInstance 105
CMDBGetMultipleInstances 110
CMDBSetInstance 131
CMDBSetMultipleInstances 135
overview 70
C API query data structures
CMDBGetObjectList 163
CMDBGetObjectStruct 163
CMDBGetRelationList 163
CMDBGetRelationStruct 164
CMDBGraphAdjacentList 164
CMDBGraphAdjacentStruct 165
CMDBGraphList 165
CMDBGraphStruct 166
CMDBGraphWalkObjectList 166
CMDBGraphWalkObjectStruct 167
CMDBGraphWalkQueryStruct 167
CMDBGraphWalkRelation 169
CMDBGraphWalkRelationList 170
CMDBGraphWalkResultStruct 171
CMDBGraphWalkSelectorAndFilterList 172
CMDBGraphWalkSelectorAndFilterStruct 173
CMDBGraphWalkStateStruct 174
CMDBNestedQueryStruct 180
CMDBQueryArithOpStruct 181
CMDBQueryAttributeName 182
CMDBQueryObject 184
CMDBQueryObjectList 186
CMDBQueryObjectSelectorList 187
CMDBQueryObjectSelectorStruct 188
CMDBQueryQualifierAndOrStruct 188
CMDBQueryQualifierSetOpStruct 189
CMDBQueryQualifierSimpleOpStruct 190
CMDBQueryQualifierStruct 192
CMDBQueryQualifierValueSetStruct 193
CMDBQueryQualifierValueStruct 194
Index
227
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
classes (continued)
attribute index information 178
audit options 153
C API data structures 144
class names 151
configuration item (CI) definitions 144
creating with cmdbdriver 37
creating with core attributes 77
data 144
data structures 144
deleting 87
exporting definitions 93
exporting qualified 92
importing data 121
importing definitions 122
index information 177
managing 68
names 151, 155, 179
namespace names 151, 155
relationship definitions 144
relationship information 156
retrieving 97, 104
retrieving list of UI components 111
setting properties 128
type information 157
CMDBActivateFederatedInContext function 71
CMDBAttributeGetStruct structure 146
CMDBAttributeLimit structure 147
CMDBAttributeLimitList structure 151
CMDBAttributeNameId structure 151
CMDBAttributeValueList structure 152
CMDBAttributeValueListList structure 152
CMDBAttributeValueStruct structure 152
CMDBAuditInfoStruct structure 153
CMDBAuditValueList structure 154
CMDBAuditValueListList structure 155
CMDBBeginBulkEntryTransaction function 72
CMDBCancelJobRun function 73
CMDBClassNameId structure 155
CMDBClassNameIdList structure 155
CMDBClassRelationship structure 156
CMDBClassTypeInfo structure 157
CMDBCreateAttribute function 74
CMDBCreateClass function 77
CMDBCreateGuid function 80
CMDBCreateInstance function 81
CMDBCreateMultipleAttribute function 82
CMDBCreateMultipleAttributes function 82
CMDBCreateMultipleInstances function 85
CMDBDeleteAttribute function 86
CMDBDeleteClass function 87
CMDBDeleteInstance function 88
228
CMDBDeleteMultipleInstances function 89
cmdbdriver program
commands for API functions 218
commands for controlling 223
overview 37
using from command line 39
cmdbdriver.sh file 39
CMDBEndBulkEntryTransaction function 90
CMDBExpandParametersForCI function 91
CMDBExportData function 92
CMDBExportDef function 93
CMDBExportItem structure 158
CMDBExportItemList structure 159
CMDBExportItemStruct structure 159
CMDBFederatedActivateInfo structure 161
CMDBFederatedARInfo structure 162
CMDBGetAttribute function 94
CMDBGetClass function 97
CMDBGetCMDBUIComponents function 111
CMDBGetCopyAuditData function 100
CMDBGetInstance function 102
CMDBGetInstanceBLOB function 103
CMDBGetJobRun function 112
CMDBGetListClass function 104
CMDBGetListInstance function 105
CMDBGetListJobRun function 113
CMDBGetMultipleAttribute function 107
CMDBGetMultipleInstances function 110
CMDBGetObjectList structure 163
CMDBGetObjectStruct structure 163
CMDBGetRelatedFederatedInContext function 114
CMDBGetRelationList structure 163
CMDBGetRelationStruct structure 164
CMDBGetServerPort function 115
CMDBGetVersions function 115
CMDBGraphAdjacentList structure 164
CMDBGraphAdjacentStruct structure 165
CMDBGraphList structure 165
CMDBGraphQuery function 53, 116
CMDBGraphStruct structure 166
CMDBGraphWalkBegin function 118
CMDBGraphWalkEnd function 119
CMDBGraphWalkNext function 120
CMDBGraphWalkObjectList structure 166
CMDBGraphWalkObjectStruct structure 167
CMDBGraphWalkQueryStruct structure 167
CMDBGraphWalkRelation data structure 169
CMDBGraphWalkRelation structure 169
CMDBGraphWalkRelationList structure 170
CMDBGraphWalkResultStruct structure 171
CMDBGraphWalkSelectorAndFilterList
structure 172
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
CMDBGraphWalkSelectorAndFilterStruct
structure 173
CMDBGraphWalkStateStruct structure 174
CMDBImportData function 121
CMDBImportDef function 122
CMDBImportItem structure 175
CMDBImportItemList structure 175
CMDBImportItemStruct structure 176
CMDBIndexList structure 177
CMDBIndexStruct structure 178
CMDBInitialization function 123
CMDBInstanceList structure 178
CMDBInstanceStruct structure 179
CMDBItemTypeAttribute structure 179
CMDBItemTypeClass structure 179
CMDBNestedQueryStruct structure 180
CMDBQualifierStruct structure 181
CMDBQueryArithOpStruct structure 181
CMDBQueryAttributeName structure 182
CMDBQueryByPath function 46, 124
CMDBQueryObject structure 184
CMDBQueryObjectList structure 186
CMDBQueryObjectSelectorList structure 187
CMDBQueryObjectSelectorStruct structure 188
CMDBQueryQualifierAndOrStruct structure 188
CMDBQueryQualifierSetOpStruct structure 189
CMDBQueryQualifierSimpleOpStruct structure 190
CMDBQueryQualifierStruct structure 192
CMDBQueryQualifierValueSetStruct structure 193
CMDBQueryQualifierValueStruct structure 194
CMDBQueryStruct structure 198
CMDBREClassQualList structure 203
CMDBREClassQualStruct structure 204
CMDBREDatasetList structure 204
CMDBREDatasetPair structure 205
CMDBREJobRunInfo structure 205
CMDBREJobRunInfoList structure 206
CMDBRunQualificationForCI function 125
CMDBSetAttribute function 126
CMDBSetClass function 128
CMDBSetInstance function 131
CMDBSetMultipleAttribute function 133
CMDBSetMultipleInstances function 135
CMDBSetServerPort function 136
CMDBSortList structure 206
CMDBSortStruct structure 207
CMDBStartJobRun functions 137
CMDBSynchMetaData function 138
CMDBSystemInit function 139
CMDBTermination function 139
CMDBUIComponentInfo structure 207
CMDBUIComponentResult structure 211
Index
229
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
D
data limits 150
data model functions, C API 68
data structures, C API
attribute 144
class 144
export 144
federation 144
general purpose 144
import 144
instance 144
list of 144
overview 141
query 145
Reconciliation Engine 146
user interface component 146
data structures, printing 43
date limits 150
dateLimits structure 150
debugging APIs 43
debugging calls with data structure contents 43
decimal limits 150
decimalLimits structure 150
definitions
attribute 144
configuration item (CI) 144
exporting class 93
importing class 122
relationship 144
deleting
attributes 86
classes 87
instances 88
instances, multiple 89
E
enum limits 150
enumLimits structure 150
environment functions 68
examples
CMDBGraphQuery function 55
finding all CIs related to instances 51
finding all computers in divisions 47
finding relationships of CI instances 57, 60
expanding
CI parameters 91
federated instances 71
exporting
BMC Atrium CMDB data 68
C API data structures 144
230
exporting (continued)
C API functions 68
class data, qualified 92
class definitions 93
data 144
functions 68
items 158, 159
F
federated instances
activating 71, 161
retrieving 114
federation
AR system data 162
data structures 144
expanding instances 71
functions 68
instance activation data 161
launching instances 71
retrieving instances 114
filtering graph nodes 173
forms, creating 138
free functions 69
FreeCMDBAttributeGetStruct function 69
FreeCMDBAttributeLimit function 69
FreeCMDBAttributeLimitList function 69
FreeCMDBAttributeLimitStruct function 69
FreeCMDBAttributeValueList function 69
FreeCMDBAttributeValueListList function 69
FreeCMDBAuditInfoStruct function 69
FreeCMDBAuditValueList function 69
FreeCMDBAuditValueListList function 69
FreeCMDBClassNameIdList function 69
FreeCMDBClassTypeInfo function 69
FreeCMDBExportItemList function 69
FreeCMDBExportItemStruct function 69
FreeCMDBFederatedActivateInfo function 69
FreeCMDBGetObjectList function 69
FreeCMDBGetRelationList function 69
FreeCMDBGraphAdjacentList function 69
FreeCMDBGraphAdjacentStruct function 69
FreeCMDBGraphList function 69
FreeCMDBGraphStruct function 69
FreeCMDBGraphWalkObjectList function 69
FreeCMDBGraphWalkObjectStruc function 69
FreeCMDBGraphWalkObjectStruct function 69
FreeCMDBGraphWalkQueryStruct function 69
FreeCMDBGraphWalkRelation function 69
FreeCMDBGraphWalkRelationList function 69
FreeCMDBGraphWalkResultStruct function 69
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
FreeCMDBGraphWalkSelectorAndFilterList
function 69
FreeCMDBGraphWalkSelectorAndFilterStruct
function 69
FreeCMDBGraphWalkStateStruct function 69
FreeCMDBImportItemList function 69
FreeCMDBIndexList function 69
FreeCMDBInstanceList function 69
FreeCMDBNestedQueryStruct function 69
FreeCMDBQualifierStruct function 69
FreeCMDBQueryObject function 69
FreeCMDBQueryObjectList function 69
FreeCMDBQueryObjectSelectorList function 69
FreeCMDBQueryQualifierStruct function 69
FreeCMDBQueryQualifierValueStruct function 69
FreeCMDBQueryResultGraph function 69
FreeCMDBQuerySortList function 69
FreeCMDBQuerySortStruct function 69
FreeCMDBQueryStruct function 69
functions, C API
bulk entry transaction 67
copy 67
data model 68
environment 68
export and import 68
federation 68
free 69
instance 70
list of 67
query 70
Reconciliation Engine 70
user interface component 70
utility 70
G
general purpose data structures 144
graph nodes
filtering 173
structure 166
graph walk
beginning 118
ending 119
next chunk 120
object list 166
objects 167
query functions 50
query results 171
query structure 167
relationship to walk 169
starting 118
state 174
graphs
adjacency lists 54
adjacency matrixes 54
C API query data structures 145
lists 165
H
header files
BMC Atrium CMDB program 35, 36
C API 29
HP computers using C API, compiling 34
I
IDs, creating globally unique 80
importing
C API data structures 144
C API functions 68
class data 121
class definitions 122
CMDB data 68
data 144
functions 68
items 175, 176
initializing
C API sessions 123
networks 139
servers 139
installing C API package 29
instance BLOBs, retrieving 103
instances
attributes 179
C API management functions 70
C API structures 144
configuration item (CI) 163
creating configuration item (CI) 81
creating relationship 81
creating with cmdbdriver 37
data 144
definitions 144
deleting 88
expanding CI parameters 91
expanding federated 71
federated 71, 114, 161
finding related 45
launching federated 71
lists 178
management functions 70
relationship 163, 164
retrieving 102, 105, 110
retrieving BLOBs 103
Index
231
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
instances (continued)
retrieving CI audit data 100
retrieving federated 114
retrieving list of 105
retrieving multiple 110
retrieving single 102
searching for related 116
setting attributes for multiple 135
setting CI 131
setting relationship 131
structures 144
integer limits 149
integerLimits attribute structure 149
items to export 158, 159
items to import 175, 176
J
Java API
environment components 35
header files 35, 36
overview 20
program requirements 35
jobs
See reconciliation jobs
L
launching federated instances 71
library
files, C API 30
links, C API 34
limits
attachment 151
character 149
currency 150
date 150
decimal 150
enum 150
integer 149
real 149
linking libraries, C API 34
M
managing
attributes 68
classes 68
data models 68
instances 70
reconciliation jobs 70
232
N
names
class 151, 155
namespace 151, 155
networks, initializing 139
next chunk, graph walk 120
nodes, adjacent 164
P
parameters, expanding CI 91
ports
retrieving 115
setting 136
print routines, BMC Atrium CMDB 43
print.c file 43
printing 43
product support 3
programming BMC Atrium CMDB APIs 22
programs
cmdbdriver 37
header files in Java API 35, 36
propagating attribute values 213
Q
qualifications
reconciliation jobs 203, 204
string 181
strings 181
queries
C API data structures 145
CI and relationship by path 124
example 57, 60
filtering graph walk for 172, 173
functions 70
graph list definitions 165
graph lists 165
graph nodes for 166
nested objects 180
R
real data limits 149
realLimits attribute structure 149
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Reconciliation Engine
C API data structures 146
C API functions 70
managing jobs 70
reconciliation jobs
canceling 73
datasets 204, 205
qualifications 203, 204
retrieving 112, 113
retrieving data for running 112
retrieving list of running 113
retrieving logs 112
running 205, 206
starting 137
relationships
See instances
requirements 21, 35
S
samples
BMC Atrium CMDB API source code 43
C API driver programs 29
source code 43
scripts, using 40
searching for instances 116
server ports
retrieving 115
setting 136
servers
initializing 139
retrieving ports 115
setting ports 136
sessions
initializing C API 123
terminating C API 139
source code
C API driver 29
sample BMC Atrium CMDB API 43
SQL views 44
support, customer 3
U
user interface components
data structures 146
functions 70
query results 211, 212
retrieving 207
retrieving lists 111
utilities
BMC Atrium CMDB 70
functions 70
V
validating attributes, CI 125
versions, retrieving BMC Atrium CMDB
component 115
views, SQL 44
W
web services API
Apache Axis2 36
BMC Atrium Core Web Services
Infrastructure 36
BMC Atrium Core Web Services Registry 36
documentation 36
overview 20
T
technical support 3
terminating C API sessions 139
terminology, Atrium Console versus API 23
Index
233
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
234
*160639*
*160639*
*160639*
*160639*
*160639*