ModelDriven / Alf-Reference-Implementation

Open-source implementation of the Action Language for fUML (Alf) specification.
30 stars 2 forks source link

ElementFactory.interfaceForName should handle all UML metaclasses #74

Open seidewitz opened 5 years ago

seidewitz commented 5 years ago

The ElementFactory.interfaceForName method is used to get a class object for the wrapper interface named UML metaclass. However, since interfaceForName is static, it only looks for interfaces in the statically known org.modeldriven.alf.uml package, which does not cover all UML metaclasses. If there is no interface for the named metaclass, the method returns null. This is not adequate when the reference implementation is integrated into a tool that implements the complete UML metamodel.

seidewitz commented 4 years ago

The easiest, though somewhat brute force, way to handle this would be to just generate interfaces that cover the entire UML metamodel.