mirror of
https://github.com/octoleo/plantuml.git
synced 2024-12-22 02:49:06 +00:00
Remove version from UML:model
This commit is contained in:
parent
d586be399b
commit
775d2e16c9
@ -92,15 +92,11 @@ public class XmiDescriptionDiagram implements XmlDiagramTransformer {
|
||||
final Element content = document.createElement("XMI.content");
|
||||
xmi.appendChild(content);
|
||||
|
||||
// <UML:Model xmi.id="UMLModel.4" name="Design Model"
|
||||
// visibility="public" isSpecification="false" isRoot="false"
|
||||
// isLeaf="false" isAbstract="false">
|
||||
final Element model = document.createElement("UML:Model");
|
||||
model.setAttribute("xmi.id", CucaDiagramXmiMaker.getModel(diagram));
|
||||
model.setAttribute("name", "PlantUML " + Version.versionString());
|
||||
model.setAttribute("name", "PlantUML");
|
||||
content.appendChild(model);
|
||||
|
||||
// <UML:Namespace.ownedElement>
|
||||
this.ownedElement = document.createElement("UML:Namespace.ownedElement");
|
||||
model.appendChild(ownedElement);
|
||||
|
||||
|
@ -8,7 +8,6 @@ import net.sourceforge.plantuml.sequencediagram.Event;
|
||||
import net.sourceforge.plantuml.sequencediagram.Message;
|
||||
import net.sourceforge.plantuml.sequencediagram.Participant;
|
||||
import net.sourceforge.plantuml.sequencediagram.SequenceDiagram;
|
||||
import net.sourceforge.plantuml.version.Version;
|
||||
|
||||
public class XmiSequenceDiagramArgo extends XmiSequenceDiagram {
|
||||
public XmiSequenceDiagramArgo(SequenceDiagram diagram, Document document) {
|
||||
@ -33,11 +32,8 @@ public class XmiSequenceDiagramArgo extends XmiSequenceDiagram {
|
||||
final Element content = document.createElement("XMI.content");
|
||||
xmi.appendChild(content);
|
||||
|
||||
// <UML:Model xmi.id="UMLModel.4" name="Design Model"
|
||||
// visibility="public" isSpecification="false" isRoot="false"
|
||||
// isLeaf="false" isAbstract="false">
|
||||
final Element model = createElement(diagram, "UML:Model");
|
||||
model.setAttribute("name", "PlantUML " + Version.versionString());
|
||||
model.setAttribute("name", "PlantUML");
|
||||
content.appendChild(model);
|
||||
|
||||
Element ownedElement = document.createElement("UML:Namespace.ownedElement");
|
||||
@ -84,17 +80,15 @@ public class XmiSequenceDiagramArgo extends XmiSequenceDiagram {
|
||||
|
||||
private Node createSendAction(Message message) {
|
||||
Element sendAction = createElement(message, "UML:SendAction");
|
||||
sendAction.appendChild(document.createElement("UML:Action.script")).appendChild(createElement(
|
||||
"UML:ActionExpression", new String[][] {
|
||||
{"xmi.id", getXmiId("UML:ActionExpression", message)},
|
||||
{"body", getDisplayString(message.getLabel()) }
|
||||
}));
|
||||
sendAction.appendChild(document.createElement("UML:Action.script"))
|
||||
.appendChild(createElement("UML:ActionExpression",
|
||||
new String[][] { { "xmi.id", getXmiId("UML:ActionExpression", message) },
|
||||
{ "body", getDisplayString(message.getLabel()) } }));
|
||||
return sendAction;
|
||||
}
|
||||
|
||||
private Element createElement(Object object, String tag) {
|
||||
return createElement(tag,
|
||||
new String[][] { {"xmi.id", getXmiId("UML:ActionExpression", object)}});
|
||||
return createElement(tag, new String[][] { { "xmi.id", getXmiId("UML:ActionExpression", object) } });
|
||||
}
|
||||
|
||||
private Node createRef(String tag, Object target) {
|
||||
|
@ -92,12 +92,9 @@ public class XmiStateDiagram implements XmlDiagramTransformer {
|
||||
final Element content = document.createElement("XMI.content");
|
||||
xmi.appendChild(content);
|
||||
|
||||
// <UML:Model xmi.id="UMLModel.4" name="Design Model"
|
||||
// visibility="public" isSpecification="false" isRoot="false"
|
||||
// isLeaf="false" isAbstract="false">
|
||||
final Element model = document.createElement("UML:Model");
|
||||
model.setAttribute("xmi.id", CucaDiagramXmiMaker.getModel(diagram));
|
||||
model.setAttribute("name", "PlantUML "+Version.versionString());
|
||||
model.setAttribute("name", "PlantUML");
|
||||
content.appendChild(model);
|
||||
|
||||
// <UML:Namespace.ownedElement>
|
||||
|
@ -33,7 +33,7 @@ Expected result MUST be put between triple brackets
|
||||
<XMI.metamodel xmi.name="UML" xmi.version="1.3"/>
|
||||
</XMI.header>
|
||||
<XMI.content>
|
||||
<UML:Model name="PlantUML 1.2022.8beta2" xmi.id="model1">
|
||||
<UML:Model name="PlantUML" xmi.id="model1">
|
||||
<UML:Namespace.ownedElement>
|
||||
<UML:Component name="test" namespace="model1" xmi.id="cl0002">
|
||||
<UML:Classifier.feature/>
|
||||
@ -76,7 +76,7 @@ Expected result MUST be put between triple brackets
|
||||
<XMI.metamodel xmi.name="UML" xmi.version="1.3"/>
|
||||
</XMI.header>
|
||||
<XMI.content>
|
||||
<UML:Model name="PlantUML 1.2022.8beta2" xmi.id="model1">
|
||||
<UML:Model name="PlantUML" xmi.id="model1">
|
||||
<UML:Namespace.ownedElement>
|
||||
<UML:Component name="test" namespace="model1" xmi.id="cl0002">
|
||||
<UML:Classifier.feature/>
|
||||
|
Loading…
Reference in New Issue
Block a user