Using the Programming Interface
This chapter describes the ChangeMan ZDD object model and how to access ChangeMan ZDD functionality, using the Automation interface, from your own programs and scripts. Examples are shown in both VBScript and JScript.
See What is Automation for more information.
Naming Conventions
The examples in this document use variable name prefixes to indicate the type of variable, as follows:
Prefix | Variable |
---|---|
obj | Object |
str | String |
var | Variant |
n | Integer |
b | Boolean |
Connecting to ChangeMan ZDD
Connecting to ChangeMan ZDD is similar to connecting to any COM or ActiveX object:
For . . . | You would use . . . |
---|---|
Visual Basic or VBScript | CreateObject |
JScript | new ActiveXObject |
Visual C++ | CoCreateInstance |
For examples of connecting to ChangeMan ZDD, see ZosNetwork.
Object Model
The following table summarizes the types of objects available in the ChangeMan ZDD object model:
Object | Description |
---|---|
ZosChangeManInstance | A ChangeMan ZMF folder. See ZosChangeManInstance. |
ZosChangeManInstances | Collection of all ChangeMan ZMF folders on the same server. See ZosChangeManInstances. |
ZosDataSetFolder | A data set folder. See ZosDataSetFolder. |
ZosDataSetFolders | Collection of all data set folders with the same parent folder. See ZosDataSetFolders. |
ZosDataSetProfile | A data set profile. See ZosDataSetProfile. |
ZosDataSetProfiles | Collection of all data set profiles for a server. See ZosDataSetProfiles. |
ZosFileExtensionMapping | A file extension definition. See ZosFileExtensionMapping. |
ZosFileExtensionMappings | Collection of all file extension definitions for a server. See ZosFileExtensionMappings. |
ZosFileFormatMapping | A file format mapping. See ZosFileFormatMapping. |
ZosFileFormatMappings | Collection of file format mappings for a server or ChangeMan instance. See ZosFileFormatMappings. |
ZosJobFolder | A job folder. See ZosJobFolder. |
ZosJobFolders | Collection of all job folders with the same parent folder. See ZosJobFolders. |
ZosLibypeMapping | A library type definition. See ZosLibypeMapping. |
ZosLibypeMappings | Collection of all library type definitions for a server. See ZosLibypeMappings. |
ZosNameFilters | Collection of all filters for a folder. See ZosNameFilters. |
ZosNetwork | Entire Serena™ Network. See ZosNetwork. |
ZosPrefixMapping | A data set name prefix definition. See ZosPrefixMapping. |
ZosPrefixMappings | Collection of all data set name prefix definitions for a folder. See ZosPrefixMappings. |
ZosServer | A server. See ZosServer. |
ZosServers | Collection of all servers in the network. See ZosServers. |
The ChangeMan ZDD object model is illustrated in the following diagrams. The ZosNetwork object is always the starting point. All of the other objects are obtained as properties of another object. The arrows show how each object is obtained from another object
Collections
You can iterate through any of the collection objects in Visual Basic or VBScript using the "For Each…Next" statement, or in JScript using the "Enumerator" object: