Skip to content

Cannot Change Existing Model By Referencing Cameo ID #5

Description

@dandunbar23

The current plugin does not allow modifying existing elements. For example, adding a stereotype to an existing profile or adding a value property to an existing block won't work. The code does not search the cameo model for existing IDs except when it has already been established that an element has been created.

Particularly, I've been looking at the parent relationship. An ID can be setup in the XML schema, but if that ID points to an existing element instead of a newly created element, it will not modify the existing element. This is due to the way the GetImportedOwner method is implemented (roughly starting line 1068 in ImportXmlSysml.java).

I don't think that modifying existing elements was part of the motivating use case for this tool, so I understand it not looking for existing elements. However, the change is fairly straightforward (will be implemented in an upcoming PR), and it extends the usability of the plugin. I hope this is useful to others.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions