-
- Downloads
Ensure that IDs have been assigned to all new model elements before they are...
Ensure that IDs have been assigned to all new model elements before they are hooked to the project / resource - Rationale - Model elements for which no ID has been assigned, have id 0 (which is the default value). - When the new element is hooked to the resource, ResourceUtils.KernelResourceFactory.KernelXMIResource.getId() is called, which internally calls setId() to synchronize the XMI ID with the AF3 ID. In case the ID is still 0, this implicit call will corrupt the ID -> model object map (by override the mapping for key 0). - Changes - ElementCompositorService: Assign IDs *before* hooking new element to the container (but of course using the container to determine the next free ID) - ModelElementCompositorBase: Assign IDs to newly instantiated annotations
Showing
- org.fortiss.tooling.base/trunk/src/org/fortiss/tooling/base/compose/ModelElementCompositorBase.java 4 additions, 1 deletion...tiss/tooling/base/compose/ModelElementCompositorBase.java
- org.fortiss.tooling.kernel/trunk/src/org/fortiss/tooling/kernel/internal/ElementCompositorService.java 4 additions, 4 deletions...iss/tooling/kernel/internal/ElementCompositorService.java
Loading
Please register or sign in to comment