Altova UModel 2024 Professional Edition

UModel Programmer's Reference

Home Prev Top Next

UModel is an Automation Server. That is, it is an application that exposes programmable objects to other applications (called Automation Clients). As a result, an Automation Client can directly access the objects and functionality that the Automation Server makes available. This is beneficial to an Automation Client because it can make use of the functionality of UModel. For example, an Automation Client can use the reverse engineering functionality of UModel. Developers can therefore improve their applications by using the ready-made functionality of UModel.


The programmable objects of UModel are made available to Automation Clients via the UModel API, which is a COM API. The object model of the API and a complete description of all available objects are provided in this documentation (see UModel API Reference).


The UModel API can be accessed from within the following environments:


Scripting Editor

IDE Plug-ins

External programs


Each of these environments is described briefly below.


Scripting Editor

You can customize your installation of UModel by modifying and adding functionality to it. You can also create Forms for user input and modify the user interface so that it contains new menu commands and toolbar shortcuts. All these features are achieved by writing scripts that interact with objects of the Application API. To aid you in carrying out these tasks efficiently, UModel offers you an in-built Scripting Editor. A complete description of the functionality available in the Scripting Editor and how it is to be used is given in the Scripting Editor section of this documentation. The supported programming languages are JScript and VBScript.


IDE Plug-ins

UModel enables you to create your own plug-ins, as DLL files, and integrate them into UModel. The UModel graphical user interface provides commands to enable or disable a plug-in. Typical languages used to implement an IDE plug-in are C# and C++. For more information, see IDE Plug-ins .


External programs

Additionally, you can manipulate UModel with external scripts. For example, you could write a script to open UModel at a given time, then open a UModel project generate UML documentation, and print it out. External scripts would again make use of the API to carry out these tasks, see The UModel API.


Using the UModel API from outside UModel requires an instance of UModel to be started first, see Accessing the API.


Essentially, UModel will be started via its COM registration. Then the Application object associated with the UModel instance is returned. Depending on the COM settings, an object associated with an already running UModel can be returned. Any programming language that supports creation and invocation of COM objects can be used. The most common of these are listed below.


JScript and VBScript script files have a simple syntax and are designed to access COM objects. You can run such scripts directly from the command line or with a double click from Windows Explorer. They are best used for simple automation tasks.

C# is a full-fledged programming language that provides support for COM interoperability.

Java: Altova products come with native Java classes that wrap the Application API and provide a full Java look-and-feel.

Other programming languages that make useful alternatives are: Visual Basic for Applications, Perl, and Python.

© 2018-2024 Altova GmbH