Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing properties for di:DiagramElement in the XMI file #9

Open
barmac opened this issue Jan 9, 2020 · 9 comments
Open

Missing properties for di:DiagramElement in the XMI file #9

barmac opened this issue Jan 9, 2020 · 9 comments

Comments

@barmac
Copy link

barmac commented Jan 9, 2020

Currently, the DMNDI13.xmi file does not specify any properties of the DI::DiagramElement:

      <packagedElement xmi:type="uml:Class" xmi:id="_18_1_f7a0369_1441609962778_700532_4351"
                       name="DI::DiagramElement"
                       isAbstract="true"/>

On the other hand, the DI.xsd file contains multiple properties of that type:

	<xsd:complexType name="DiagramElement" abstract="true">
		<xsd:annotation>
			<xsd:documentation>DiagramElement is the abstract super type of all elements in diagrams, including diagrams themselves. When contained in a diagram, diagram elements are laid out relative to the diagram's origin.</xsd:documentation>
		</xsd:annotation>
		<xsd:sequence>
			<xsd:element name="extension" minOccurs="0">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded" /> 
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
			<xsd:element ref="di:Style" minOccurs="0" maxOccurs="1">
				<xsd:annotation>
					<xsd:documentation>an optional locally-owned style for this diagram element.</xsd:documentation>
				</xsd:annotation>
			</xsd:element>
		</xsd:sequence>
		<xsd:attribute name="sharedStyle" type="xsd:IDREF">
			<xsd:annotation>
				<xsd:documentation>a reference to an optional shared style element for this diagram element.</xsd:documentation>
			</xsd:annotation>
		</xsd:attribute>
		<xsd:attribute name="id" type="xsd:ID"/>
		<xsd:anyAttribute namespace="##other" processContents="lax"/>
	</xsd:complexType>

This causes a problem when we try to parse DMN files based on the XMI schema.

@philippfromme
Copy link

😴 💤

@falko
Copy link
Contributor

falko commented Jan 18, 2023

extensions are always done differently in UML and XML. But the rest should indeed be in the metamodel. Looking at the DMN 1.4 class diagram also shows a localStyle and sharedStyle:

DMN Diagram Element class diagram

But that is wrong because all these are inherited from DI::DiagramElement.

For comparison: Here is the UML model from the DD specification:
image

Proposal: Move localStyle and sharedStyle from DMN:DiagramElement to DI::DiagramElement and add id to DI::DiagramElement. Maybe also add the UML extension mechanism.

@falko falko removed a link to a pull request Jan 18, 2023
@falko
Copy link
Contributor

falko commented Jan 18, 2023

This is too big to fix together with the other typos in #8. So I'd suggest we open a separate OMG issue and PR.

@falko
Copy link
Contributor

falko commented Jan 18, 2023

It's good input for SCE DI though.

@falko
Copy link
Contributor

falko commented Feb 14, 2023

In today's meeting we decided to defer this issue to DMN 1.6 and wait how SCE is solving this. See also: omg-bpm-taskforces/omg-bpm-specs#4

@falko
Copy link
Contributor

falko commented Feb 15, 2023

The intention seems to have been to specialize sharedStyle and localStyle for DMNDiagramElement to only permit DMNStyle

@falko
Copy link
Contributor

falko commented Feb 15, 2023

The XMI is kind of more correct because it only contains the intended connections between DMN:DiagramElement and DMN:Style.

@falko
Copy link
Contributor

falko commented Apr 22, 2024

@barmac since SCE is finished now, we could revisit this issue. I'm afraid though that it is a little too late for DMN 1.6, which has its Content Freeze tomorrow.

@barmac
Copy link
Author

barmac commented Apr 22, 2024

Let's keep this in mind for the next edition. It's not a big deal to be honest.

DMN 1.5

DMN 1.6 right?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants