Skip to content

papyrus_code_generator_based_transformation

Christoph Lehr edited this page Nov 27, 2020 · 2 revisions

Papyrus Code Generator based Transformation

This is deprecated as the programmatic aproach was not further developed, please check out https://github.com/model-UA/uml-to-opcua for more transformation aproaches.

Prerequisites

Install Designer Plugins

The Plugin depends on the availabillity of Papyrus Code Generators, therefore some Papyrus Designer Plugins need the be installed. Add the following update Site to Papyrus: http://download.eclipse.org/modeling/mdt/papyrus/components/designer/ Then install the following items

  • Papyrus base elements for code generation

Installing the Plugin

Download the .jar files from the latest release and drop them into the plugins folder of your Papyrus installation. Current Release https://github.com/model-UA/papyrus-opcua-plugin/releases/tag/v0.0.1-beta1

Using the Plugin

Currently the Plugin only supports transformation of Class Diagrams and no output of errors. Errornous entries will be ignored. A Information Model can be generated by right clicking into a Diagram and selcting the Menu entry Designer->Generate OPC-UA Information Model

Error Logging

Not everything which is modelled in UML can be transformed into OPC-UA information models. Transformation Errors will be shown insided the Error Log of Papyrus which can be shown via Window->Show View->Error Log. Each log entry shows the qualified name of the UML and what the error is.

Debugging the Plugin

With the source code the plugin can debugged inside the Papyrus installation.

Loading the the Plugin

First the following folders have to imported as Eclipse Project into the Workspace.

  • org.eclipse.papyrus.designer.languages.opcua.codegen
  • org.eclipse.papyrus.designer.languages.opcua.codegen.ui

Finally run or debug as Eclipse Application.