Requirements
- Java SE Runtime Environment 11 or higher (available at http://www.oracle.com/)
- Innovator Java API binaries inojapi.jar
Overall Structure
Most parts of this API are generated according to model-driven architecture principals. This means that the structure of the interfaces primarily relies on the Innovator repository server's meta model. The API enables a Java application to work with Innovator components that can be reached via the TCP/IP network. This means that it supports, for example, a client interface to a running Innovator server or provides the ability to communicate to local Innovator client programs.
Some classes are coded by hand to ease the integration into the java runtime environment. Please refer to the package description to get information about using those classes. The API is designed for and implemented using Java 11, which provides the user with a lot of new features and advantages. Generics, in particular, enable type-safe calling of the interface methods and should reduce the need to use unsafe type casting.
The binaries of the API can be found under your Innovator installation path in the $INODIR/java/lib/ext directory. They are automatically added to your class path if you use the Innovator virtual machine launcher (inojava). Otherwise, you have to add this jar archive manually to your class path.
Interfaces and Implementer
There are several interfaces in the API structured in a package structure listed above. The structure and names of these interfaces represent an Innovator meta model entity. We have developed our model in such a way that it is easily understood by anyone familiar with UML. The Innovator meta model was designed similarly to the UML 2 specification using Innovator. An interface normally has an implementation that has to be chosen at creation time. The implementation classes are hidden to the user within the Innovator Java API because the real work is done by the server. That means every call to an interface method will result in a TCP/IP communication where the request is answered, for example, by the repository server; the result then automatically creates the implementer for the resulting interfaces. The implementers can be seen as proxy elements to the server side instances, that encapsulate the communication layer but do not contain any further useful information. This means that you should never need to program with implementation classes and, consequently, there is no description about those implementers in this documentation; in fact, they are not even mentioned, except in this paragraph.
The structure of interfaces and implementers, however, raises some problems and traps that you should be aware of:
-
The Java instanceof operator should be handled with care. For example,
if an API method returns a CLClassifier and you want to know which type of
classifier you have, calling the
result instanceof CLClass
will always return false, because CLClass is an interface and the implementer of CLClass that is instantiated by the method call does not extend CLClass but implements CLClass. Consequently, you should always use the Java reflection method isAssignableFrom to check if a CLClassifier implementer also implements CLClass. - An interface describes a list of instance methods, which means that any static method cannot be called using the interface. According to CORBA calls in Java, they can be called through helper classes. There are several helper classes in the Innovator Java API which contain all static methods to a corresponding interface. For example, the static methods to CLClass can be found in CLClassHelper.
- The creation of new instances cannot be performed by calling new but must be done with help of a static method named create, which also can be found in the corresponding helper class.
Quickstart
The easiest way to write a Java program that can be run from an Innovator client is to use the
following code template. The example uses the base class InnovatorApplicationDefault
for implementing the interface InnovatorApplication
. In general, every Java
application (class with a 'main' static method) can be configured to be executed from the Innovator
clients. However, if you want to use a transparent way, either run a standalone application or you can extend
the default application inside the Innovator context, if you prefer. This enables your program
to react on standard global property values or use an existing Innovator environment to contact
a repository.
The 'run' method is your starting point to navigate through an Innovator model. It can be accessed using, for example, the protected default application member variable 'model'. If you did start your application within Innovator client context, the java program will use the same login and model which is currently open in your Innovator model browser.
import java.util.ArrayList; import java.util.List; import de.mid.innovator.client.InoClientContext; import de.mid.innovator.srv2api.icw2elem.ELElement; import de.mid.innovator.ui.InnovatorApplication; import de.mid.innovator.ui.InnovatorApplicationDefault; import de.mid.innovator.ui.PropertyCfg; import de.mid.innovator.util.InoNlsException; public class Main extends InnovatorApplicationDefault implements InnovatorApplication { private static PropertyCfg[] argumentsCfg = new PropertyCfg[0]; public static void main(String[] args) throws Exception { InnovatorApplicationDefault.create(Main.class, argumentsCfg, args); } public void run() throws InoNlsException { List<ELElement> sel = new ArrayList<ELElement>(); if (InoClientContext.hasContext()) sel = InoClientContext.getInstance().getSelection(); // TODO: code your program here // use instance variable 'model' or InoClientContext to start server queries } public String Usage() { return "My own usage"; } }
Package | Description |
---|---|
de.mid.innovator.client |
The package contains classes that are useful for working with different kinds of Innovator
clients.
|
de.mid.innovator.net |
The package contains classes needed for the network communication via TCP/IP between Innovator
network clients and servers.
|
de.mid.innovator.srv |
All classes in this package are used for communicating with the Innovator repository server
and license server.
|
de.mid.innovator.srv.excellence |
The package contains classes for connecting to an Innovator model
for manipulation and evaluation purposes.
|
de.mid.innovator.srv2api.icw2ac |
Activity modeling emphasizes the sequence and conditions for coordinating
lower-level behaviors, rather than which classifiers own those behaviors.
|
de.mid.innovator.srv2api.icw2acdia |
Diagrams and graphical representations for elements of the icw2ac package.
|
de.mid.innovator.srv2api.icw2bc |
Package for Business Object Modeling.
|
de.mid.innovator.srv2api.icw2be |
The Common Behaviors package specifies the core concepts required for dynamic
elements and provides the infrastructure to support more detailed definitions of
behavior.
|
de.mid.innovator.srv2api.icw2bp |
Package for Business Process Model and Notation (BPMN).
|
de.mid.innovator.srv2api.icw2bpdia |
BPMN Diagrams and graphical representations for elements of the icw2bp package.
|
de.mid.innovator.srv2api.icw2br |
Business resource modeling package.
|
de.mid.innovator.srv2api.icw2brdia |
Diagrams and graphical representations for elements of the icw2br package.
|
de.mid.innovator.srv2api.icw2bs |
State machine for Business Object Modeling.
|
de.mid.innovator.srv2api.icw2bsdia |
Diagrams and graphical representations for elements of the icw2bs package.
|
de.mid.innovator.srv2api.icw2class |
The classes package deals with the basic modeling concepts of UML and, in
particular, classes and their relationships.
|
de.mid.innovator.srv2api.icw2cldia |
Diagrams and graphical representations for elements of the icw2class package.
|
de.mid.innovator.srv2api.icw2db |
The DB package (specialization of the IM package) describes the concepts needed
for modeling a relational database.
|
de.mid.innovator.srv2api.icw2dbdia |
Database Diagrams and representations of tables and foreign keys, as well as
views and from clauses.
|
de.mid.innovator.srv2api.icw2dg |
The documentation package deals with the model documentation configuration and
generation.
|
de.mid.innovator.srv2api.icw2dm |
The purpose of DMN is to provide the constructs that are needed to model
decisions, so that organizational decision-making can be readily depicted in
diagrams, accurately defined by business analysts, and (optionally) automated.
|
de.mid.innovator.srv2api.icw2drdia |
The decision requirements level of a decision model in DMN consists of a
Decision Requirement Graph depicted in one or more Decision Requirement
Diagrams.
|
de.mid.innovator.srv2api.icw2elem |
Describes the common behavior of all elements stored in a model server
repository even configuration elements in profiles and schema elements of the
meta model.
|
de.mid.innovator.srv2api.icw2er |
The ER package (specialization of the IM package) deals with the modeling
concepts for the Entity Relationship Model and, in particular, entities,
attributes and their relationships.
In addition it deals with the concepts of Online Analytical Processing (OLAP) to build a data warehouse for business intelligence (BI) matters. |
de.mid.innovator.srv2api.icw2erdia |
Entity Relationship Diagrams and representations of entities and relationships,
as well as conceptual views and from clauses.
|
de.mid.innovator.srv2api.icw2gc |
Package for concept modeling.
|
de.mid.innovator.srv2api.icw2gcdia |
Concept diagrams and graphical representations for elements of the icw2gc
package.
|
de.mid.innovator.srv2api.icw2ia |
The Interaction package describes the concepts needed to express interactions.
|
de.mid.innovator.srv2api.icw2im |
The IM package specify the Information Management Metamodel core concepts
required for data modeling.
|
de.mid.innovator.srv2api.icw2imdia |
Information Management Metamodel Diagram is a subclass of Class Diagram.
|
de.mid.innovator.srv2api.icw2meta |
Meta model and administration information.
|
de.mid.innovator.srv2api.icw2model |
This packagage contains elements representing the logical model.
|
de.mid.innovator.srv2api.icw2pres |
Diagrams and graphical representations of model elements in diagrams.
|
de.mid.innovator.srv2api.icw2sm |
The StateMachine package defines a set of concepts that can be used for
modeling discrete behavior through finite statetransition systems.
|
de.mid.innovator.srv2api.icw2smdia |
Diagrams and graphical representations for elements of the icw2sm package.
|
de.mid.innovator.srv2api.icw2sqdia |
Diagrams and graphical representations for elements of the icw2ia package.
|
de.mid.innovator.srv2api.icw2util |
Utilities for the cooperation of Innovator components and programs.
|
de.mid.innovator.ui |
The classes in this package can be used to provide transparent user interfaces
with a standard mechanism for supporting command line arguments or Java properties.
|
de.mid.innovator.util |
The package contains some useful utilities for Innovator API applications.
|