No “Generate Java Code” Option in Papyrus Designer – Only “Generate code (no transformations)”
Hello,
I am working with Papyrus and trying to generate Java code from my UML class diagram. My goal is to generate not only the class and method structure, but also method logic, such as return statements.
In every tutorial I’ve seen, the option appears as:
Designer → Generate Java Code
This generates complete Java code, including method bodies, especially if OpaqueBehaviors with language = Java are set.
However, in my installation, I only see:
Designer → Generate code (no transformations)
This version only generates the bare structure of the class – no method bodies, no logic, no return values.
My setup: Eclipse version: Eclipse IDE for Modeling (includes Papyrus)
Papyrus
Version: 2024-06 (4.32)
Papyrus Designer: fully installed via the Eclipse Marketplace (all options selected during installation)
What I’ve already tried:
Used “Designer → Synchronize derived elements” on model and package levels in the Model Explorer (nothing happens)
Defined operations with OpaqueBehavior (language set to Java, return code included)
Added profiles and primitive types: JavaPrimitiveTypes, Papyrus Code Generation Profile
Additional context: Code is successfully generated via “Generate code (no transformations)”
The generated .java files contain the class, fields, and method headers
But all method bodies are empty, even when logic is defined in the model
My question: What must I do to enable the “Generate Java Code” option (with transformations), instead of just “Generate code (no transformations)”?
Is there a new requirement in the recent versions of Papyrus Designer? Is there a hidden configuration or an additional plug-in I might be missing?
Thanks in advance for any guidance, Dennis