diff --git a/src/net/sourceforge/plantuml/PSystemUtils.java b/src/net/sourceforge/plantuml/PSystemUtils.java index 1c001de8c..3244c3ac9 100644 --- a/src/net/sourceforge/plantuml/PSystemUtils.java +++ b/src/net/sourceforge/plantuml/PSystemUtils.java @@ -44,7 +44,7 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.List; -import net.sourceforge.plantuml.baraye.a.CucaDiagram; +import net.sourceforge.plantuml.baraye.CucaDiagram; import net.sourceforge.plantuml.core.Diagram; import net.sourceforge.plantuml.core.ImageData; import net.sourceforge.plantuml.html.CucaDiagramHtmlMaker; diff --git a/src/net/sourceforge/plantuml/activitydiagram/ActivityDiagram.java b/src/net/sourceforge/plantuml/activitydiagram/ActivityDiagram.java index f4d46cb74..ea68eedde 100644 --- a/src/net/sourceforge/plantuml/activitydiagram/ActivityDiagram.java +++ b/src/net/sourceforge/plantuml/activitydiagram/ActivityDiagram.java @@ -42,9 +42,9 @@ import java.util.Objects; import net.sourceforge.plantuml.Direction; import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.baraye.a.CucaDiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.CucaDiagram; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.core.DiagramDescription; import net.sourceforge.plantuml.core.UmlSource; import net.sourceforge.plantuml.cucadiagram.Code; diff --git a/src/net/sourceforge/plantuml/activitydiagram/ConditionalContext.java b/src/net/sourceforge/plantuml/activitydiagram/ConditionalContext.java index 3bb03eae3..2397e3674 100644 --- a/src/net/sourceforge/plantuml/activitydiagram/ConditionalContext.java +++ b/src/net/sourceforge/plantuml/activitydiagram/ConditionalContext.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.activitydiagram; import java.util.Objects; import net.sourceforge.plantuml.Direction; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.cucadiagram.LeafType; public class ConditionalContext { diff --git a/src/net/sourceforge/plantuml/activitydiagram/command/CommandElse.java b/src/net/sourceforge/plantuml/activitydiagram/command/CommandElse.java index 84e07b586..b9d55f8f7 100644 --- a/src/net/sourceforge/plantuml/activitydiagram/command/CommandElse.java +++ b/src/net/sourceforge/plantuml/activitydiagram/command/CommandElse.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.activitydiagram.command; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.activitydiagram.ActivityDiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/activitydiagram/command/CommandEndPartition.java b/src/net/sourceforge/plantuml/activitydiagram/command/CommandEndPartition.java index 45467fafd..1f1c3b3f8 100644 --- a/src/net/sourceforge/plantuml/activitydiagram/command/CommandEndPartition.java +++ b/src/net/sourceforge/plantuml/activitydiagram/command/CommandEndPartition.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.activitydiagram.command; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.activitydiagram.ActivityDiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/activitydiagram/command/CommandIf.java b/src/net/sourceforge/plantuml/activitydiagram/command/CommandIf.java index 0269e1859..1c86b1cf3 100644 --- a/src/net/sourceforge/plantuml/activitydiagram/command/CommandIf.java +++ b/src/net/sourceforge/plantuml/activitydiagram/command/CommandIf.java @@ -39,7 +39,7 @@ import net.sourceforge.plantuml.Direction; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.activitydiagram.ActivityDiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.command.CommandLinkClass; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; diff --git a/src/net/sourceforge/plantuml/activitydiagram/command/CommandInnerConcurrent.java b/src/net/sourceforge/plantuml/activitydiagram/command/CommandInnerConcurrent.java index 17d0f62ee..2e6670346 100644 --- a/src/net/sourceforge/plantuml/activitydiagram/command/CommandInnerConcurrent.java +++ b/src/net/sourceforge/plantuml/activitydiagram/command/CommandInnerConcurrent.java @@ -37,13 +37,13 @@ package net.sourceforge.plantuml.activitydiagram.command; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.activitydiagram.ActivityDiagram; +import net.sourceforge.plantuml.baraye.EntityUtils; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; import net.sourceforge.plantuml.command.regex.RegexConcat; import net.sourceforge.plantuml.command.regex.RegexLeaf; import net.sourceforge.plantuml.command.regex.RegexResult; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; public class CommandInnerConcurrent extends SingleLineCommand2 { diff --git a/src/net/sourceforge/plantuml/activitydiagram/command/CommandLinkActivity.java b/src/net/sourceforge/plantuml/activitydiagram/command/CommandLinkActivity.java index 399ac8c26..b78b8927b 100644 --- a/src/net/sourceforge/plantuml/activitydiagram/command/CommandLinkActivity.java +++ b/src/net/sourceforge/plantuml/activitydiagram/command/CommandLinkActivity.java @@ -42,8 +42,8 @@ import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; import net.sourceforge.plantuml.activitydiagram.ActivityDiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.classdiagram.command.CommandLinkClass; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; diff --git a/src/net/sourceforge/plantuml/activitydiagram/command/CommandLinkLongActivity.java b/src/net/sourceforge/plantuml/activitydiagram/command/CommandLinkLongActivity.java index f2b15d496..d6b98416f 100644 --- a/src/net/sourceforge/plantuml/activitydiagram/command/CommandLinkLongActivity.java +++ b/src/net/sourceforge/plantuml/activitydiagram/command/CommandLinkLongActivity.java @@ -45,7 +45,7 @@ import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; import net.sourceforge.plantuml.activitydiagram.ActivityDiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.command.CommandLinkClass; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.CommandExecutionResult; diff --git a/src/net/sourceforge/plantuml/activitydiagram/command/CommandPartition.java b/src/net/sourceforge/plantuml/activitydiagram/command/CommandPartition.java index fa7f8ba24..8256b83fa 100644 --- a/src/net/sourceforge/plantuml/activitydiagram/command/CommandPartition.java +++ b/src/net/sourceforge/plantuml/activitydiagram/command/CommandPartition.java @@ -38,8 +38,8 @@ package net.sourceforge.plantuml.activitydiagram.command; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.activitydiagram.ActivityDiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/baraye/a/CucaDiagram.java b/src/net/sourceforge/plantuml/baraye/CucaDiagram.java similarity index 99% rename from src/net/sourceforge/plantuml/baraye/a/CucaDiagram.java rename to src/net/sourceforge/plantuml/baraye/CucaDiagram.java index a02be7825..8601ca8d7 100644 --- a/src/net/sourceforge/plantuml/baraye/a/CucaDiagram.java +++ b/src/net/sourceforge/plantuml/baraye/CucaDiagram.java @@ -33,7 +33,7 @@ * * */ -package net.sourceforge.plantuml.baraye.a; +package net.sourceforge.plantuml.baraye; import java.io.IOException; import java.io.OutputStream; @@ -64,7 +64,6 @@ import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.EntityGender; import net.sourceforge.plantuml.cucadiagram.EntityPortion; import net.sourceforge.plantuml.cucadiagram.EntityPosition; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; import net.sourceforge.plantuml.cucadiagram.GroupHierarchy; import net.sourceforge.plantuml.cucadiagram.GroupType; import net.sourceforge.plantuml.cucadiagram.HideOrShow2; @@ -235,6 +234,10 @@ public abstract class CucaDiagram extends UmlDiagram implements GroupHierarchy, return buildFullyQualified(id); } + final public Ident buildLeafIdentSpecial2(String id) { + return buildFullyQualified(id); + } + private Ident buildLeafIdentSpecialUnused(String id) { // if (namespaceSeparator != null) { // if (id.contains(namespaceSeparator)) { diff --git a/src/net/sourceforge/plantuml/baraye/a/EntityFactory.java b/src/net/sourceforge/plantuml/baraye/EntityFactory.java similarity index 99% rename from src/net/sourceforge/plantuml/baraye/a/EntityFactory.java rename to src/net/sourceforge/plantuml/baraye/EntityFactory.java index 8fb897b95..72ec0772d 100644 --- a/src/net/sourceforge/plantuml/baraye/a/EntityFactory.java +++ b/src/net/sourceforge/plantuml/baraye/EntityFactory.java @@ -33,7 +33,7 @@ * * */ -package net.sourceforge.plantuml.baraye.a; +package net.sourceforge.plantuml.baraye; import java.util.ArrayList; import java.util.Collection; diff --git a/src/net/sourceforge/plantuml/baraye/a/EntityImp.java b/src/net/sourceforge/plantuml/baraye/EntityImp.java similarity index 99% rename from src/net/sourceforge/plantuml/baraye/a/EntityImp.java rename to src/net/sourceforge/plantuml/baraye/EntityImp.java index 67a2735d4..cb5768dd0 100644 --- a/src/net/sourceforge/plantuml/baraye/a/EntityImp.java +++ b/src/net/sourceforge/plantuml/baraye/EntityImp.java @@ -34,7 +34,7 @@ * Contribution: Miguel Esteves * */ -package net.sourceforge.plantuml.baraye.a; +package net.sourceforge.plantuml.baraye; import java.util.ArrayList; import java.util.Collection; @@ -62,7 +62,6 @@ import net.sourceforge.plantuml.cucadiagram.CucaNote; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.DisplayPositioned; import net.sourceforge.plantuml.cucadiagram.EntityPosition; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; import net.sourceforge.plantuml.cucadiagram.GroupRoot; import net.sourceforge.plantuml.cucadiagram.GroupType; import net.sourceforge.plantuml.cucadiagram.Ident; diff --git a/src/net/sourceforge/plantuml/cucadiagram/EntityUtils.java b/src/net/sourceforge/plantuml/baraye/EntityUtils.java similarity index 77% rename from src/net/sourceforge/plantuml/cucadiagram/EntityUtils.java rename to src/net/sourceforge/plantuml/baraye/EntityUtils.java index 3e46c76af..078e87b1e 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/EntityUtils.java +++ b/src/net/sourceforge/plantuml/baraye/EntityUtils.java @@ -33,12 +33,10 @@ * * */ -package net.sourceforge.plantuml.cucadiagram; +package net.sourceforge.plantuml.baraye; -import net.sourceforge.plantuml.baraye.Quark; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.b.EntityImp; +import net.sourceforge.plantuml.cucadiagram.GroupRoot; +import net.sourceforge.plantuml.cucadiagram.Link; public abstract class EntityUtils { @@ -69,22 +67,6 @@ public abstract class EntityUtils { return false; } - public static boolean isPureInnerLink12(EntityImp group, Link link) { - if (group.isGroup() == false) - throw new IllegalArgumentException(); - - final EntityImp e1 = (EntityImp) link.getZEntity1(); - final EntityImp e2 = (EntityImp) link.getZEntity2(); - final Quark group1 = e1.getQuark().getParent(); - final Quark group2 = e2.getQuark().getParent(); - if (group.getQuark().containsLarge(group1) && group.getQuark().containsLarge(group2)) - return true; -// if (isParent(group1, group) && isParent(group2, group)) -// return true; - - return false; - } - public static boolean isPureInnerLink12(IGroup group, Link link) { if (group.isGroup() == false) throw new IllegalArgumentException(); diff --git a/src/net/sourceforge/plantuml/baraye/b/IEntity.java b/src/net/sourceforge/plantuml/baraye/IEntity.java similarity index 98% rename from src/net/sourceforge/plantuml/baraye/b/IEntity.java rename to src/net/sourceforge/plantuml/baraye/IEntity.java index 8009455ee..a17a70be5 100644 --- a/src/net/sourceforge/plantuml/baraye/b/IEntity.java +++ b/src/net/sourceforge/plantuml/baraye/IEntity.java @@ -33,7 +33,7 @@ * Contribution: Miguel Esteves * */ -package net.sourceforge.plantuml.baraye.b; +package net.sourceforge.plantuml.baraye; import java.util.List; import java.util.Map; diff --git a/src/net/sourceforge/plantuml/baraye/b/IGroup.java b/src/net/sourceforge/plantuml/baraye/IGroup.java similarity index 98% rename from src/net/sourceforge/plantuml/baraye/b/IGroup.java rename to src/net/sourceforge/plantuml/baraye/IGroup.java index 39b4a115f..55b350597 100644 --- a/src/net/sourceforge/plantuml/baraye/b/IGroup.java +++ b/src/net/sourceforge/plantuml/baraye/IGroup.java @@ -33,7 +33,7 @@ * * */ -package net.sourceforge.plantuml.baraye.b; +package net.sourceforge.plantuml.baraye; import java.util.Collection; diff --git a/src/net/sourceforge/plantuml/baraye/a/ILeaf.java b/src/net/sourceforge/plantuml/baraye/ILeaf.java similarity index 98% rename from src/net/sourceforge/plantuml/baraye/a/ILeaf.java rename to src/net/sourceforge/plantuml/baraye/ILeaf.java index 9b88ed436..e3fc27706 100644 --- a/src/net/sourceforge/plantuml/baraye/a/ILeaf.java +++ b/src/net/sourceforge/plantuml/baraye/ILeaf.java @@ -33,7 +33,7 @@ * * */ -package net.sourceforge.plantuml.baraye.a; +package net.sourceforge.plantuml.baraye; import java.util.Collection; diff --git a/src/net/sourceforge/plantuml/baraye/Plasma.java b/src/net/sourceforge/plantuml/baraye/Plasma.java index e5a48ec1c..6f4fcf0e6 100644 --- a/src/net/sourceforge/plantuml/baraye/Plasma.java +++ b/src/net/sourceforge/plantuml/baraye/Plasma.java @@ -35,9 +35,10 @@ */ package net.sourceforge.plantuml.baraye; +import java.util.ArrayList; import java.util.Collection; import java.util.Collections; -import java.util.HashMap; +import java.util.LinkedHashMap; import java.util.List; import java.util.Map; @@ -45,7 +46,7 @@ public class Plasma { private String separator; private final Quark root; - private final Map, Quark> quarks = new HashMap<>(); + private final Map, Quark> quarks = new LinkedHashMap<>(); public Plasma(String separator) { final List empty = Collections.emptyList(); @@ -62,6 +63,8 @@ public class Plasma { } public final void setSeparator(String separator) { + if (separator == null) + separator = "\u0000"; this.separator = separator; } @@ -76,7 +79,7 @@ public class Plasma { } if (idx > 0) { result.add(full.substring(0, idx)); - ensurePresent(result); + ensurePresent(new ArrayList<>(result)); } full = full.substring(idx + separator.length()); @@ -86,7 +89,13 @@ public class Plasma { Quark ensurePresent(List result) { Quark quark = quarks.get(result); if (quark == null) { - quark = new Quark(this, result); + if (result.size() == 0) + quark = new Quark(this, null, result); + else { + final Quark parent = ensurePresent(result.subList(0, result.size() - 1)); + quark = new Quark(this, parent, result); + } + System.err.println("PUTTING " + quark); quarks.put(result, quark); } return quark; @@ -94,7 +103,54 @@ public class Plasma { } public Collection quarks() { - return Collections.unmodifiableCollection(quarks.values()); + return Collections.unmodifiableCollection(new ArrayList<>(quarks.values())); + } + +// public boolean exists(String name) { +// for (Quark quark : quarks.values()) +// if (quark.getName().equals(name)) +// return true; +// return false; +// } + + public Quark getIfExists(String name) { + for (Quark quark : quarks.values()) + if (quark.getName().equals(name)) + return quark; + return null; + } + + public Quark getIfExists(List signature) { + return quarks.get(signature); + } + + public int countChildren(Quark parent) { + int count = 0; + for (Quark quark : new ArrayList<>(quarks.values())) + if (quark.getParent() == parent) + count++; + return count; + } + + public List getChildren(Quark parent) { + final List result = new ArrayList<>(); + for (Quark quark : new ArrayList<>(quarks.values())) + if (quark.getParent() == parent) + result.add(quark); + return Collections.unmodifiableList(result); + } + + public void moveAllTo(Quark src, Quark dest) { + for (Quark quark : new ArrayList<>(quarks.values())) { + if (quark == dest) + continue; + if (src.containsLarge(quark)) { + quarks.remove(quark.getSignature()); + quark.internalMove(src, dest); + quarks.put(quark.getSignature(), quark); + } + } + } } diff --git a/src/net/sourceforge/plantuml/baraye/Quark.java b/src/net/sourceforge/plantuml/baraye/Quark.java index 89ba22a9c..b0e5e5d84 100644 --- a/src/net/sourceforge/plantuml/baraye/Quark.java +++ b/src/net/sourceforge/plantuml/baraye/Quark.java @@ -39,26 +39,40 @@ import java.util.ArrayList; import java.util.List; import net.sourceforge.plantuml.cucadiagram.Code; +import net.sourceforge.plantuml.cucadiagram.Ident; -public class Quark implements Code { +public class Quark extends Ident implements Code { private final Plasma plasma; - private final List parts; + private /* final */ Quark parent; + // private final List parts; private Object data; - Quark(Plasma plasma, List parts) { + Quark(Plasma plasma, Quark parent, List parts) { + super(new ArrayList(parts)); this.plasma = plasma; - this.parts = new ArrayList(parts); + this.parent = parent; + if (parent == null) { + if (parts.size() != 0) + throw new IllegalStateException(); + } else { + if (parent.parts.equals(parts.subList(0, parts.size() - 1)) == false) + throw new IllegalStateException(); + + } + // this.parts = new ArrayList(parts); } public Quark getParent() { - if (parts.size() == 0) - return null; - return plasma.ensurePresent(parts.subList(0, parts.size() - 1)); + return parent; +// if (parts.size() == 0) +// return null; +// return plasma.ensurePresent(parts.subList(0, parts.size() - 1)); } @Override public String toString() { + // return parts.toString() + "(parent=" + parent + ")"; return parts.toString(); } @@ -119,6 +133,10 @@ public class Quark implements Code { return parts.size() == 0; } + public int getDepth() { + return parts.size(); + } + // public int size() { // return parts.size(); // } @@ -136,8 +154,41 @@ public class Quark implements Code { } @Override - public Code eventuallyRemoveStartingAndEndingDoubleQuote(String format) { - throw new UnsupportedOperationException(); + public Ident eventuallyRemoveStartingAndEndingDoubleQuote(String format) { + return this; + // throw new UnsupportedOperationException(); + } + + public Quark childIfExists(String name) { + final List sig = new ArrayList<>(getSignature()); + sig.add(name); + return plasma.getIfExists(sig); + } + + public Quark child(String name) { + return plasma.parse(this, name); + } + + public int countChildren() { + return plasma.countChildren(this); + } + + public List getChildren() { + return plasma.getChildren(this); + } + + public void moveTo(Quark dest) { + plasma.moveAllTo(this, dest); + } + + public void internalMove(Quark src, Quark dest) { + if (src.getDepth() + 1 != dest.getDepth()) + throw new UnsupportedOperationException("to be finished"); + final String name = getName(); + parts.clear(); + parts.addAll(dest.getSignature()); + parts.add(name); + this.parent = dest; } } diff --git a/src/net/sourceforge/plantuml/baraye/a/IEntity.java b/src/net/sourceforge/plantuml/baraye/a/IEntity.java deleted file mode 100644 index 91e720fc3..000000000 --- a/src/net/sourceforge/plantuml/baraye/a/IEntity.java +++ /dev/null @@ -1,126 +0,0 @@ -/* ======================================================================== - * PlantUML : a free UML diagram generator - * ======================================================================== - * - * (C) Copyright 2009-2023, Arnaud Roques - * - * Project Info: http://plantuml.com - * - * If you like this project or if you find it useful, you can support us at: - * - * http://plantuml.com/patreon (only 1$ per month!) - * http://plantuml.com/paypal - * - * This file is part of PlantUML. - * - * PlantUML is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * PlantUML distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY - * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public - * License for more details. - * - * You should have received a copy of the GNU General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, - * USA. - * - * - * Original Author: Arnaud Roques - * Contribution: Miguel Esteves - * - */ -package net.sourceforge.plantuml.baraye.a; - -import java.util.List; -import java.util.Map; -import java.util.Set; - -import net.sourceforge.plantuml.Hideable; -import net.sourceforge.plantuml.LineConfigurable; -import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.Removeable; -import net.sourceforge.plantuml.SpecificBackcolorable; -import net.sourceforge.plantuml.Url; -import net.sourceforge.plantuml.command.Position; -import net.sourceforge.plantuml.cucadiagram.Bodier; -import net.sourceforge.plantuml.cucadiagram.Code; -import net.sourceforge.plantuml.cucadiagram.CucaNote; -import net.sourceforge.plantuml.cucadiagram.Display; -import net.sourceforge.plantuml.cucadiagram.EntityPosition; -import net.sourceforge.plantuml.cucadiagram.Ident; -import net.sourceforge.plantuml.cucadiagram.LeafType; -import net.sourceforge.plantuml.cucadiagram.Stereostyles; -import net.sourceforge.plantuml.cucadiagram.Stereotag; -import net.sourceforge.plantuml.cucadiagram.Stereotype; -import net.sourceforge.plantuml.graphic.USymbol; -import net.sourceforge.plantuml.graphic.color.Colors; - -public interface IEntity extends SpecificBackcolorable, Hideable, Removeable, LineConfigurable { - - public Code getCode(); - - public String getCodeGetName(); - - public Ident getIdent(); - - public USymbol getUSymbol(); - - public void setUSymbol(USymbol symbol); - - public LeafType getLeafType(); - - public Display getDisplay(); - - public IGroup getParentContainer(); - - public void setDisplay(Display display); - - public String getUid(); - - public Url getUrl99(); - - public Stereotype getStereotype(); - - public void setStereotype(Stereotype stereotype); - - public Bodier getBodier(); - - public void addUrl(Url url); - - public boolean isGroup(); - - public boolean hasUrl(); - - public int getRawLayout(); - - public void putTip(String member, Display display); - - public Map getTips(); - - public void addStereotag(Stereotag tag); - - public Set stereotags(); - - public boolean isAloneAndUnlinked(); - - public void setThisIsTogether(); - - public String getCodeLine(); - - public void setCodeLine(LineLocation codeLine); - - public void setStereostyle(String stereo); - - public Stereostyles getStereostyles(); - - public void addNote(Display note, Position position, Colors colors); - - public EntityPosition getEntityPosition(); - - public List getNotes(Position position); - -} diff --git a/src/net/sourceforge/plantuml/baraye/a/IGroup.java b/src/net/sourceforge/plantuml/baraye/a/IGroup.java deleted file mode 100644 index 5d4044111..000000000 --- a/src/net/sourceforge/plantuml/baraye/a/IGroup.java +++ /dev/null @@ -1,82 +0,0 @@ -/* ======================================================================== - * PlantUML : a free UML diagram generator - * ======================================================================== - * - * (C) Copyright 2009-2023, Arnaud Roques - * - * Project Info: http://plantuml.com - * - * If you like this project or if you find it useful, you can support us at: - * - * http://plantuml.com/patreon (only 1$ per month!) - * http://plantuml.com/paypal - * - * This file is part of PlantUML. - * - * PlantUML is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * PlantUML distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY - * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public - * License for more details. - * - * You should have received a copy of the GNU General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, - * USA. - * - * - * Original Author: Arnaud Roques - * - * - */ -package net.sourceforge.plantuml.baraye.a; - -import java.util.Collection; - -import net.sourceforge.plantuml.ISkinParam; -import net.sourceforge.plantuml.cucadiagram.Code; -import net.sourceforge.plantuml.cucadiagram.DisplayPositioned; -import net.sourceforge.plantuml.cucadiagram.GroupType; -import net.sourceforge.plantuml.cucadiagram.LeafType; -import net.sourceforge.plantuml.graphic.FontConfiguration; -import net.sourceforge.plantuml.svek.IEntityImage; -import net.sourceforge.plantuml.svek.PackageStyle; -import net.sourceforge.plantuml.svek.SingleStrategy; - -public interface IGroup extends IEntity { - - public boolean containsLeafRecurse(ILeaf entity); - - public Collection getLeafsDirect(); - - public Collection getChildren(); - - public void moveEntitiesTo(IGroup dest); - - public int size(); - - public GroupType getGroupType(); - - public Code getNamespace(); - - public PackageStyle getPackageStyle(); - - public void overrideImage(IEntityImage img, LeafType state); - - public SingleStrategy getSingleStrategy(); - - public FontConfiguration getFontConfigurationForTitle(ISkinParam skinParam); - - public char getConcurrentSeparator(); - - public void setConcurrentSeparator(char separator); - - public void setLegend(DisplayPositioned legend); - - public DisplayPositioned getLegend(); - -} diff --git a/src/net/sourceforge/plantuml/baraye/b/CucaDiagram.java b/src/net/sourceforge/plantuml/baraye/b/CucaDiagram.java deleted file mode 100644 index dab177ea8..000000000 --- a/src/net/sourceforge/plantuml/baraye/b/CucaDiagram.java +++ /dev/null @@ -1,940 +0,0 @@ -/* ======================================================================== - * PlantUML : a free UML diagram generator - * ======================================================================== - * - * (C) Copyright 2009-2023, Arnaud Roques - * - * Project Info: http://plantuml.com - * - * If you like this project or if you find it useful, you can support us at: - * - * http://plantuml.com/patreon (only 1$ per month!) - * http://plantuml.com/paypal - * - * This file is part of PlantUML. - * - * PlantUML is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * PlantUML distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY - * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public - * License for more details. - * - * You should have received a copy of the GNU General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, - * USA. - * - * - * Original Author: Arnaud Roques - * - * - */ -package net.sourceforge.plantuml.baraye.b; - -import java.io.IOException; -import java.io.OutputStream; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.HashSet; -import java.util.List; -import java.util.Map; -import java.util.Objects; -import java.util.Set; -import java.util.concurrent.atomic.AtomicInteger; - -import net.sourceforge.plantuml.BackSlash; -import net.sourceforge.plantuml.FileFormat; -import net.sourceforge.plantuml.FileFormatOption; -import net.sourceforge.plantuml.UmlDiagram; -import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.api.ImageDataSimple; -import net.sourceforge.plantuml.baraye.a.EntityFactory; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; -import net.sourceforge.plantuml.command.CommandExecutionResult; -import net.sourceforge.plantuml.core.ImageData; -import net.sourceforge.plantuml.core.UmlSource; -import net.sourceforge.plantuml.cucadiagram.Code; -import net.sourceforge.plantuml.cucadiagram.CodeImpl; -import net.sourceforge.plantuml.cucadiagram.Display; -import net.sourceforge.plantuml.cucadiagram.EntityGender; -import net.sourceforge.plantuml.cucadiagram.EntityPortion; -import net.sourceforge.plantuml.cucadiagram.EntityPosition; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; -import net.sourceforge.plantuml.cucadiagram.GroupHierarchy; -import net.sourceforge.plantuml.cucadiagram.GroupType; -import net.sourceforge.plantuml.cucadiagram.HideOrShow2; -import net.sourceforge.plantuml.cucadiagram.ICucaDiagram; -import net.sourceforge.plantuml.cucadiagram.Ident; -import net.sourceforge.plantuml.cucadiagram.LeafType; -import net.sourceforge.plantuml.cucadiagram.Link; -import net.sourceforge.plantuml.cucadiagram.LinkConstraint; -import net.sourceforge.plantuml.cucadiagram.NamespaceStrategy; -import net.sourceforge.plantuml.cucadiagram.PortionShower; -import net.sourceforge.plantuml.cucadiagram.dot.CucaDiagramTxtMaker; -import net.sourceforge.plantuml.cucadiagram.entity.IEntityFactory; -import net.sourceforge.plantuml.elk.CucaDiagramFileMakerElk; -import net.sourceforge.plantuml.graphic.USymbol; -import net.sourceforge.plantuml.graphml.CucaDiagramGraphmlMaker; -import net.sourceforge.plantuml.sdot.CucaDiagramFileMakerSmetana; -import net.sourceforge.plantuml.security.SecurityUtils; -import net.sourceforge.plantuml.skin.VisibilityModifier; -import net.sourceforge.plantuml.style.ClockwiseTopRightBottomLeft; -import net.sourceforge.plantuml.svek.CucaDiagramFileMaker; -import net.sourceforge.plantuml.svek.CucaDiagramFileMakerSvek; -import net.sourceforge.plantuml.xmi.CucaDiagramXmiMaker; - -public abstract class CucaDiagram extends UmlDiagram implements GroupHierarchy, PortionShower, ICucaDiagram { - - static private final boolean G1972 = false; - - // private String namespaceSeparator = "."; - // private String namespaceSeparator1 = GO1972 ? "::" : "."; - private String namespaceSeparator = null; - private boolean namespaceSeparatorHasBeenSet = false; - - public final boolean V1972() { - return false; - } - - public final boolean mergeIntricated() { - if (getNamespaceSeparator() == null) { - return false; - } - return this.V1972() && this.getUmlDiagramType() == UmlDiagramType.CLASS; - } - - private final List hides2 = new ArrayList<>(); - private final List removed = new ArrayList<>(); - protected final ZEntityFactory entityFactory = new ZEntityFactory(hides2, removed, this); - // protected final EntityFactory entityFactory = new EntityFactory(hides2, removed, this); -// protected final EntityFactory entityFactory = null; -// private IGroup currentGroup = entityFactory.getRootGroup(); - private List stacks2 = new ArrayList<>(); - private List stacks = new ArrayList<>(); - - private boolean visibilityModifierPresent; - - public abstract IEntity getOrCreateLeaf(Ident ident, Code code, LeafType type, USymbol symbol); - - public Ident cleanIdent(Ident ident) { - return ident; - } - - public CucaDiagram(UmlSource source, UmlDiagramType type, Map orig) { - super(source, type, orig); - this.stacks2.add(Ident.empty()); - } - - private Ident getLastID() { - if (stacks2.size() == 0) { - // Thread.dumpStack(); - return Ident.empty(); - // throw new IllegalArgumentException(); - } - return this.stacks2.get(stacks2.size() - 1); - } - - final public void setNamespaceSeparator(String namespaceSeparator) { - this.namespaceSeparatorHasBeenSet = true; - this.namespaceSeparator = namespaceSeparator; - } - - final public String getNamespaceSeparator() { - if (namespaceSeparatorHasBeenSet == false) - return V1972() ? "::" : "."; - - return namespaceSeparator; - } - - @Override - public boolean hasUrl() { -// for (IEntity entity : getGroups(true)) -// if (entity.hasUrl()) -// return true; -// -// for (IEntity entity : entityFactory.leafs()) -// if (entity.hasUrl()) -// return true; -// -// for (Link link : getLinks()) -// if (link.hasUrl()) -// return true; - - return false; - } - - final public void setLastEntity(ILeaf foo) { - this.lastEntity = foo; - } - - final protected ILeaf getOrCreateLeafDefault(Ident idNewLong, Code code, LeafType type, USymbol symbol) { - Objects.requireNonNull(idNewLong); - Objects.requireNonNull(type); - throw new UnsupportedOperationException(); -// ILeaf result; -// if (this.V1972()) -// result = entityFactory.getLeafStrict(idNewLong); -// else -// result = entityFactory.getLeaf(code); -// -// if (result == null) { -// result = createLeafInternal(idNewLong, code, Display.getWithNewlines(code), type, symbol); -// result.setUSymbol(symbol); -// } -// -// if (result.getLeafType() == LeafType.CLASS && type == LeafType.OBJECT) -// if (result.muteToType(type, symbol) == false) -// return null; -// -// this.lastEntity = result; -// return result; - } - - public ILeaf createLeaf(Ident idNewLong, Code code, Display display, LeafType type, USymbol symbol) { - Objects.requireNonNull(idNewLong); - throw new UnsupportedOperationException(); -// if (entityFactory.getLeafStrict(idNewLong) != null) { -// return null; -// } -// return createLeafInternal(idNewLong, code, display, type, symbol); - } - - final protected ILeaf createLeafInternal(Ident newIdent, Code code, Display display, LeafType type, - USymbol symbol) { - Objects.requireNonNull(newIdent); - throw new UnsupportedOperationException(); -// if (Display.isNull(display)) -// display = Display.getWithNewlines(code).withCreoleMode(CreoleMode.SIMPLE_LINE); -// -// final ILeaf leaf = entityFactory.createLeaf(newIdent, code, display, type, getCurrentGroup(), getHides(), -// getNamespaceSeparator()); -// entityFactory.addLeaf(leaf); -// this.lastEntity = leaf; -// leaf.setUSymbol(symbol); -// return leaf; - } - - final public Ident buildLeafIdent(String id) { - return getLastID().add(id, getNamespaceSeparator()); - } - - final public Ident buildLeafIdentSpecial(String id) { - return buildFullyQualified(id); - } - - private Ident buildLeafIdentSpecialUnused(String id) { -// if (namespaceSeparator != null) { -// if (id.contains(namespaceSeparator)) { - return Ident.empty().add(id, "."); -// } -// } -// return getLastID().add(id, namespaceSeparator); - } - - final public Ident buildFullyQualified(String id) { - throw new UnsupportedOperationException(); - // return entityFactory.buildFullyQualified(getLastID(), Ident.empty().add(id, getNamespaceSeparator())); - } - - final public Code buildCode(String s) { - if (this.V1972()) - throw new UnsupportedOperationException(); - return CodeImpl.of(s); - } - - public boolean leafExist(Code code) { - throw new UnsupportedOperationException(); -// if (this.V1972()) -// throw new UnsupportedOperationException(); -// return entityFactory.getLeaf(code) != null; - } - - public boolean leafExistSmart(Ident ident) { - throw new UnsupportedOperationException(); -// return entityFactory.getLeafSmart(ident) != null; - } - - public boolean leafExistStrict(Ident ident) { - throw new UnsupportedOperationException(); -// return entityFactory.getLeafStrict(ident) != null; - } - - final public Collection getChildrenGroups(IGroup parent) { - if (this.V1972()) - return getChildrenGroupsIdent1972(parent); - final Collection result = new ArrayList<>(); - for (IGroup gg : getGroups(false)) - if (gg.getParentContainer() == parent) - result.add(gg); - - return Collections.unmodifiableCollection(result); - } - - private Collection getChildrenGroupsIdent1972(IGroup parent) { - throw new UnsupportedOperationException(); -// final Collection result = new ArrayList<>(); -// for (IGroup gg : entityFactory.groups2()) -// if (gg.getIdent().parent().equals(parent.getIdent())) -// result.add(gg); -// -// return Collections.unmodifiableCollection(result); - } - - final public void gotoGroup(Ident ident, Code code, Display display, GroupType type, IGroup parent, - NamespaceStrategy strategy) { - if (this.V1972()) { - gotoGroupInternalWithNamespace(ident, code, display, code, type, parent); - return; - - } - if (strategy == NamespaceStrategy.MULTIPLE) { - if (getNamespaceSeparator() != null) - code = getFullyQualifiedCode1972(code); - - gotoGroupInternalWithNamespace(ident, code, display, code, type, parent); - } else if (strategy == NamespaceStrategy.SINGLE) { - final Ident newIdLong = buildLeafIdentSpecial(ident.toString(this.getNamespaceSeparator())); - gotoGroupExternal(newIdLong, code, display, null, type, parent); - stacks2.add(newIdLong); - } else { - throw new IllegalArgumentException(); - } - } - - protected final String getNamespace1972(Code fullyCode, String separator) { - throw new UnsupportedOperationException(); -// String name = fullyCode.getName(); -// Objects.requireNonNull(separator); -// do { -// final int x = name.lastIndexOf(separator); -// if (x == -1) -// return null; -// -// name = name.substring(0, x); -// } while (entityFactory.getLeaf(buildCode(name)) != null); -// return name; - } - - private void gotoGroupInternalWithNamespace(Ident idNewLong, Code code, Display display, Code namespaceNew, - GroupType type, IGroup parent) { - throw new UnsupportedOperationException(); -// this.stacks.add(currentGroup); -// this.stacks2.add(idNewLong); -// -// if (this.V1972()) { -// gotoGroupInternal(idNewLong, code, display, namespaceNew, type, parent); -// return; -// } -// if (getNamespaceSeparator() == null) { -// gotoGroupInternal(idNewLong, code, display, namespaceNew, type, parent); -// return; -// } -// -// final String namespaceCurrent = getNamespace1972(code, getNamespaceSeparator()); -// if (namespaceCurrent == null) { -// gotoGroupInternal(idNewLong, code, display, namespaceNew, type, parent); -// return; -// } -// final IGroup realParent = entityFactory.getGroup(buildCode(namespaceCurrent)); -// if (realParent == null) { -// gotoGroupInternal(idNewLong, code, display, namespaceNew, type, parent); -// return; -// } -// display = Display.create(idNewLong.getLast()); -// IGroup result = entityFactory.createGroup(idNewLong, code, display, namespaceNew, type, realParent, getHides(), -// getNamespaceSeparator()); -// -// entityFactory.addGroup(result); -// currentGroup = result; - - } - - public void endGroup() { - throw new UnsupportedOperationException(); -// if (stacks2.size() > 0) { -// // Thread.dumpStack(); -// stacks2.remove(stacks2.size() - 1); -// } -// if (EntityUtils.groupRoot(currentGroup)) { -// Log.error("No parent group"); -// return; -// } -// if (stacks.size() > 0) -// currentGroup = stacks.remove(stacks.size() - 1); -// else -// currentGroup = currentGroup.getParentContainer(); - } - - private void gotoGroupInternal(Ident idNewLong, final Code code, Display display, final Code namespace, - GroupType type, IGroup parent) { - throw new UnsupportedOperationException(); -// if (this.V1972()) { -// gotoGroupInternal1972(idNewLong, code, display, namespace, type, parent); -// return; -// } -// -// IGroup result = entityFactory.getGroup(code); -// if (result != null) { -// currentGroup = result; -// return; -// } -// if (entityFactory.getLeafStrict(idNewLong) != null) { -// result = entityFactory.muteToGroup(code.getName(), namespace, type, parent); -// result.setDisplay(display); -// } else { -// result = entityFactory.createGroup(idNewLong, code, display, namespace, type, parent, getHides(), -// getNamespaceSeparator()); -// } -// entityFactory.addGroup(result); -// currentGroup = result; - } - - private void gotoGroupInternal1972(Ident idNewLong, final Code code, Display display, final Code namespace, - GroupType type, IGroup parent) { - throw new UnsupportedOperationException(); -// IGroup result = entityFactory.getGroupStrict(idNewLong); -// if (result != null) { -// currentGroup = result; -// return; -// } -// final boolean mutation; -// if (getNamespaceSeparator() == null) -// mutation = entityFactory.getLeafVerySmart(idNewLong) != null; -// else -// mutation = entityFactory.getLeafStrict(idNewLong) != null; -// if (mutation) { -// result = entityFactory.muteToGroup1972(idNewLong, namespace, type, parent); -// result.setDisplay(display); -// } else { -// result = entityFactory.createGroup(idNewLong, code, display, namespace, type, parent, getHides(), -// getNamespaceSeparator()); -// } -// entityFactory.addGroup(result); -// currentGroup = result; -// stacks2.set(stacks2.size() - 1, result.getIdent()); - } - - final protected void gotoGroupExternal(Ident newIdLong, final Code code, Display display, final Code namespace, - GroupType type, IGroup parent) { - throw new UnsupportedOperationException(); -// IGroup result = entityFactory.getGroup(code); -// if (result != null) { -// currentGroup = result; -// return; -// } -// if (entityFactory.getLeaf(code) != null) { -// result = entityFactory.muteToGroup(code.getName(), namespace, type, parent); -// result.setDisplay(display); -// } else { -// result = entityFactory.createGroup(newIdLong, code, display, namespace, type, parent, getHides(), -// getNamespaceSeparator()); -// } -// entityFactory.addGroup(result); -// // entityFactory.thisIsNotArealGroup(newIdLong); -// currentGroup = result; - } - - public final void gotoThisGroup(IGroup group) { - throw new UnsupportedOperationException(); -// currentGroup = group; - } - - final protected Code getFullyQualifiedCode1972(Code code) { - throw new UnsupportedOperationException(); -// final String separator = Objects.requireNonNull(getNamespaceSeparator()); -// final String full = code.getName(); -// if (full.startsWith(separator)) -// return buildCode(full.substring(separator.length())); -// -// if (full.contains(separator)) -// return buildCode(full); -// -// if (EntityUtils.groupRoot(currentGroup)) -// return buildCode(full); -// -// final Code namespace = currentGroup.getNamespace(); -// if (namespace == null) -// return buildCode(full); -// -// return buildCode(namespace.getName() + separator + full); - } - - public final IGroup getCurrentGroup() { - throw new UnsupportedOperationException(); -// return currentGroup; - } - - public final IGroup getGroup(Code code) { - throw new UnsupportedOperationException(); -// final IGroup p = entityFactory.getGroup(code); -// return Objects.requireNonNull(p); - } - - public final IGroup getGroupStrict(Ident ident) { - throw new UnsupportedOperationException(); -// if (!this.V1972()) -// throw new UnsupportedOperationException(); -// final IGroup p = entityFactory.getGroupStrict(ident); -// return Objects.requireNonNull(p); - } - - public final IGroup getGroupVerySmart(Ident ident) { - throw new UnsupportedOperationException(); -// if (!this.V1972()) -// throw new UnsupportedOperationException(); -// final IGroup p = entityFactory.getGroupVerySmart(ident); -// return Objects.requireNonNull(p); - } - - public final boolean isGroup(Code code) { - throw new UnsupportedOperationException(); -// if (this.V1972()) -// return isGroupStrict((Ident) code); -// return leafExist(code) == false && entityFactory.getGroup(code) != null; - } - - public final boolean isGroupStrict(Ident ident) { - throw new UnsupportedOperationException(); -// if (!this.V1972()) -// throw new UnsupportedOperationException(); -// return leafExistStrict(ident) == false && entityFactory.getGroupStrict(ident) != null; - } - - public final boolean isGroupVerySmart(Ident ident) { - throw new UnsupportedOperationException(); -// if (!this.V1972()) -// throw new UnsupportedOperationException(); -// return leafExistSmart(ident) == false && entityFactory.getGroupVerySmart(ident) != null; - } - - public final Collection getGroups(boolean withRootGroup) { - throw new UnsupportedOperationException(); -// if (withRootGroup == false) -// return entityFactory.groups(); -// -// final Collection result = new ArrayList<>(); -// result.add(getRootGroup()); -// result.addAll(entityFactory.groups()); -// return Collections.unmodifiableCollection(result); - } - - public IGroup getRootGroup() { - throw new UnsupportedOperationException(); -// return entityFactory.getRootGroup(); - } - - public final Collection getLeafsvalues() { - throw new UnsupportedOperationException(); -// return entityFactory.leafs2(); - } - - public final int getLeafssize() { - return getLeafsvalues().size(); - } - - public final ILeaf getLeaf(Code code) { - throw new UnsupportedOperationException(); -// return entityFactory.getLeaf(code); - } - - public final ILeaf getLeafStrict(Ident ident) { - throw new UnsupportedOperationException(); -// return entityFactory.getLeafStrict(ident); - } - - public final ILeaf getLeafSmart(Ident ident) { - throw new UnsupportedOperationException(); -// return entityFactory.getLeafSmart(ident); - } - - public /* final */ ILeaf getLeafVerySmart(Ident ident) { - throw new UnsupportedOperationException(); -// return entityFactory.getLeafVerySmart(ident); - } - - final public void addLink(Link link) { - entityFactory.addLink(link); - } - - final protected void removeLink(Link link) { - entityFactory.removeLink(link); - } - - final public List getLinks() { - return entityFactory.getLinks(); - } - - abstract protected List getDotStrings(); - - final public String[] getDotStringSkek() { - final List result = new ArrayList<>(); - for (String s : getDotStrings()) - if (s.startsWith("nodesep") || s.startsWith("ranksep") || s.startsWith("layout")) - result.add(s); - - String aspect = getPragma().getValue("aspect"); - if (aspect != null) { - aspect = aspect.replace(',', '.'); - result.add("aspect=" + aspect + ";"); - } - final String ratio = getPragma().getValue("ratio"); - if (ratio != null) - result.add("ratio=" + ratio + ";"); - - return result.toArray(new String[result.size()]); - } - - private void createFilesGraphml(OutputStream suggestedFile) throws IOException { - final CucaDiagramGraphmlMaker maker = new CucaDiagramGraphmlMaker(this); - maker.createFiles(suggestedFile); - } - - private void createFilesXmi(OutputStream suggestedFile, FileFormat fileFormat) throws IOException { - final CucaDiagramXmiMaker maker = new CucaDiagramXmiMaker(this, fileFormat); - maker.createFiles(suggestedFile); - } - - private void createFilesScxml(OutputStream suggestedFile) throws IOException { -// final StateDiagramScxmlMaker maker = new StateDiagramScxmlMaker((StateDiagram) this); -// maker.createFiles(suggestedFile); - throw new UnsupportedOperationException(); - } - - @Override - protected ImageData exportDiagramInternal(OutputStream os, int index, FileFormatOption fileFormatOption) - throws IOException { - final FileFormat fileFormat = fileFormatOption.getFileFormat(); - - if (fileFormat == FileFormat.ATXT || fileFormat == FileFormat.UTXT) { - try { - createFilesTxt(os, index, fileFormat); - } catch (Throwable t) { - t.printStackTrace(SecurityUtils.createPrintStream(os)); - } - return ImageDataSimple.ok(); - } - - if (fileFormat == FileFormat.GRAPHML) { - createFilesGraphml(os); - return ImageDataSimple.ok(); - } - - if (fileFormat.name().startsWith("XMI")) { - createFilesXmi(os, fileFormat); - return ImageDataSimple.ok(); - } - - if (fileFormat == FileFormat.SCXML) { - createFilesScxml(os); - return ImageDataSimple.ok(); - } - - if (getUmlDiagramType() == UmlDiagramType.COMPOSITE) { - throw new UnsupportedOperationException(); - } - - final CucaDiagramFileMaker maker; - if (this.isUseElk()) - maker = new CucaDiagramFileMakerElk(this, fileFormatOption.getDefaultStringBounder(getSkinParam())); - else if (this.isUseSmetana()) - maker = new CucaDiagramFileMakerSmetana(this, fileFormatOption.getDefaultStringBounder(getSkinParam())); - else - maker = new CucaDiagramFileMakerSvek(this); - - final ImageData result = maker.createFile(os, getDotStrings(), fileFormatOption); - - if (result == null) - return ImageDataSimple.error(); - - this.warningOrError = result.getWarningOrError(); - return result; - } - - private String warningOrError; - - @Override - public String getWarningOrError() { - final String generalWarningOrError = super.getWarningOrError(); - if (warningOrError == null) - return generalWarningOrError; - - if (generalWarningOrError == null) - return warningOrError; - - return generalWarningOrError + BackSlash.NEWLINE + warningOrError; - } - - private void createFilesTxt(OutputStream os, int index, FileFormat fileFormat) throws IOException { - final CucaDiagramTxtMaker maker = new CucaDiagramTxtMaker(this, fileFormat); - maker.createFiles(os, index); - } - - public boolean isAutarkic(IGroup g) { - if (g.getGroupType() == GroupType.PACKAGE) - return false; - - if (g.getGroupType() == GroupType.INNER_ACTIVITY) - return true; - - if (g.getGroupType() == GroupType.CONCURRENT_ACTIVITY) - return true; - - if (g.getGroupType() == GroupType.CONCURRENT_STATE) - return true; - - if (getChildrenGroups(g).size() > 0) - return false; - - for (Link link : getLinks()) - if (EntityUtils.isPureInnerLink3(g, link) == false) - return false; - - for (ILeaf leaf : g.getLeafsDirect()) - if (leaf.getEntityPosition() != EntityPosition.NORMAL) - return false; - - return true; - } - - private static boolean isNumber(String s) { - return s.matches("[+-]?(\\.?\\d+|\\d+\\.\\d*)"); - } - - public void resetPragmaLabel() { - getPragma().undefine("labeldistance"); - getPragma().undefine("labelangle"); - } - - public String getLabeldistance() { - if (getPragma().isDefine("labeldistance")) { - final String s = getPragma().getValue("labeldistance"); - if (isNumber(s)) - return s; - - } - if (getPragma().isDefine("defaultlabeldistance")) { - final String s = getPragma().getValue("defaultlabeldistance"); - if (isNumber(s)) - return s; - - } - // Default in dot 1.0 - return "1.7"; - } - - public String getLabelangle() { - if (getPragma().isDefine("labelangle")) { - final String s = getPragma().getValue("labelangle"); - if (isNumber(s)) - return s; - - } - if (getPragma().isDefine("defaultlabelangle")) { - final String s = getPragma().getValue("defaultlabelangle"); - if (isNumber(s)) - return s; - - } - // Default in dot -25 - return "25"; - } - - final public boolean isEmpty(IGroup gToTest) { - for (IEntity gg : getGroups(false)) { - if (gg == gToTest) - continue; - - if (gg.getParentContainer() == gToTest) - return false; - - } - return gToTest.size() == 0; - } - - public final boolean isVisibilityModifierPresent() { - return visibilityModifierPresent; - } - - public final void setVisibilityModifierPresent(boolean visibilityModifierPresent) { - this.visibilityModifierPresent = visibilityModifierPresent; - } - - public final boolean showPortion(EntityPortion portion, IEntity entity) { - if (getSkinParam().strictUmlStyle() && portion == EntityPortion.CIRCLED_CHARACTER) - return false; - - boolean result = true; - for (HideOrShow cmd : hideOrShows) - if (cmd.portion == portion && cmd.gender.contains(entity)) - result = cmd.show; - - return result; - } - - public final void hideOrShow(EntityGender gender, EntityPortion portions, boolean show) { - for (EntityPortion portion : portions.asSet()) - this.hideOrShows.add(new HideOrShow(gender, portion, show)); - - } - - public void hideOrShow(Set visibilities, boolean show) { - if (show) - hides.removeAll(visibilities); - else - hides.addAll(visibilities); - } - - public void hideOrShow2(String what, boolean show) { - this.hides2.add(new HideOrShow2(what, show)); - } - - public void removeOrRestore(String what, boolean show) { - this.removed.add(new HideOrShow2(what, show)); - } - - private final List hideOrShows = new ArrayList<>(); - private final Set hides = new HashSet<>(); - - static class HideOrShow { - private final EntityGender gender; - private final EntityPortion portion; - private final boolean show; - - public HideOrShow(EntityGender gender, EntityPortion portion, boolean show) { - this.gender = gender; - this.portion = portion; - this.show = show; - } - } - - public final Set getHides() { - return Collections.unmodifiableSet(hides); - } - - final public boolean isStandalone(IEntity ent) { - for (final Link link : getLinks()) - if (link.getEntity1() == ent || link.getEntity2() == ent) - return false; - - return true; - } - - final public boolean isStandaloneForArgo(IEntity ent) { - for (final Link link : getLinks()) { - if (link.isHidden() || link.isInvis()) - continue; - if (link.getEntity1() == ent || link.getEntity2() == ent) - return false; - } - - return true; - } - - final public Link getLastLink() { - final List links = getLinks(); - for (int i = links.size() - 1; i >= 0; i--) { - final Link link = links.get(i); - if (link.getEntity1().getLeafType() != LeafType.NOTE && link.getEntity2().getLeafType() != LeafType.NOTE) - return link; - - } - return null; - } - - final public List getTwoLastLinks() { - final List result = new ArrayList<>(); - final List links = getLinks(); - for (int i = links.size() - 1; i >= 0; i--) { - final Link link = links.get(i); - if (link.getEntity1().getLeafType() != LeafType.NOTE && link.getEntity2().getLeafType() != LeafType.NOTE) { - result.add(link); - if (result.size() == 2) - return Collections.unmodifiableList(result); - - } - } - return null; - } - - private ILeaf lastEntity = null; - - final public ILeaf getLastEntity() { - return lastEntity; - } - - final public IEntityFactory getIEntityFactory() { - return entityFactory; - } - - final public EntityFactory getEntityFactory() { - throw new UnsupportedOperationException(); - // return entityFactory; - } - - public void applySingleStrategy() { -// final MagmaList magmaList = new MagmaList(); -// -// for (IGroup g : getGroups(true)) { -// final List standalones = new ArrayList<>(); -// -// for (ILeaf ent : g.getLeafsDirect()) -// if (isStandalone(ent)) -// standalones.add(ent); -// -// if (standalones.size() < 3) -// continue; -// -// final Magma magma = new Magma(this, standalones); -// magma.putInSquare(); -// magmaList.add(magma); -// } -// -// for (IGroup g : getGroups(true)) { -// final MagmaList magmas = magmaList.getMagmas(g); -// if (magmas.size() < 3) -// continue; -// -// magmas.putInSquare(); -// } - - } - - public boolean isHideEmptyDescriptionForState() { - return false; - } - - protected void incRawLayout() { - entityFactory.incRawLayout(); - } - - public CommandExecutionResult constraintOnLinks(Link link1, Link link2, Display display) { - final LinkConstraint linkConstraint = new LinkConstraint(link1, link2, display); - link1.setLinkConstraint(linkConstraint); - link2.setLinkConstraint(linkConstraint); - return CommandExecutionResult.ok(); - } - - @Override - public ClockwiseTopRightBottomLeft getDefaultMargins() { - // Strange numbers here for backwards compatibility - return ClockwiseTopRightBottomLeft.topRightBottomLeft(0, 5, 5, 0); - } - - private final AtomicInteger cpt = new AtomicInteger(1); - - public int getUniqueSequence() { - return cpt.addAndGet(1); - } - - public String getUniqueSequence(String prefix) { - return prefix + getUniqueSequence(); - } - -} diff --git a/src/net/sourceforge/plantuml/baraye/b/EntityImp.java b/src/net/sourceforge/plantuml/baraye/b/EntityImp.java deleted file mode 100644 index 45a33151c..000000000 --- a/src/net/sourceforge/plantuml/baraye/b/EntityImp.java +++ /dev/null @@ -1,896 +0,0 @@ -/* ======================================================================== - * PlantUML : a free UML diagram generator - * ======================================================================== - * - * (C) Copyright 2009-2023, Arnaud Roques - * - * Project Info: http://plantuml.com - * - * If you like this project or if you find it useful, you can support us at: - * - * http://plantuml.com/patreon (only 1$ per month!) - * http://plantuml.com/paypal - * - * This file is part of PlantUML. - * - * PlantUML is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * PlantUML distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY - * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public - * License for more details. - * - * You should have received a copy of the GNU General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, - * USA. - * - * - * Original Author: Arnaud Roques - * Contribution: Hisashi Miyashita - * Contribution: Miguel Esteves - * - */ -package net.sourceforge.plantuml.baraye.b; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.EnumMap; -import java.util.HashSet; -import java.util.LinkedHashMap; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Map; -import java.util.Objects; -import java.util.Set; - -import net.sourceforge.plantuml.Direction; -import net.sourceforge.plantuml.FontParam; -import net.sourceforge.plantuml.Guillemet; -import net.sourceforge.plantuml.Hideable; -import net.sourceforge.plantuml.ISkinParam; -import net.sourceforge.plantuml.LineConfigurable; -import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.Removeable; -import net.sourceforge.plantuml.SpecificBackcolorable; -import net.sourceforge.plantuml.StringUtils; -import net.sourceforge.plantuml.Url; -import net.sourceforge.plantuml.baraye.Quark; -import net.sourceforge.plantuml.command.Position; -import net.sourceforge.plantuml.cucadiagram.Bodier; -import net.sourceforge.plantuml.cucadiagram.Code; -import net.sourceforge.plantuml.cucadiagram.CucaNote; -import net.sourceforge.plantuml.cucadiagram.Display; -import net.sourceforge.plantuml.cucadiagram.DisplayPositioned; -import net.sourceforge.plantuml.cucadiagram.EntityPosition; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; -import net.sourceforge.plantuml.cucadiagram.GroupType; -import net.sourceforge.plantuml.cucadiagram.ICucaDiagram; -import net.sourceforge.plantuml.cucadiagram.Ident; -import net.sourceforge.plantuml.cucadiagram.LeafType; -import net.sourceforge.plantuml.cucadiagram.Link; -import net.sourceforge.plantuml.cucadiagram.Stereostyles; -import net.sourceforge.plantuml.cucadiagram.Stereotag; -import net.sourceforge.plantuml.cucadiagram.Stereotype; -import net.sourceforge.plantuml.cucadiagram.dot.Neighborhood; -import net.sourceforge.plantuml.graphic.FontConfiguration; -import net.sourceforge.plantuml.graphic.HorizontalAlignment; -import net.sourceforge.plantuml.graphic.TextBlock; -import net.sourceforge.plantuml.graphic.TextBlockEmpty; -import net.sourceforge.plantuml.graphic.USymbol; -import net.sourceforge.plantuml.graphic.USymbols; -import net.sourceforge.plantuml.graphic.color.ColorType; -import net.sourceforge.plantuml.graphic.color.Colors; -import net.sourceforge.plantuml.skin.VisibilityModifier; -import net.sourceforge.plantuml.style.Style; -import net.sourceforge.plantuml.svek.IEntityImage; -import net.sourceforge.plantuml.svek.Kal; -import net.sourceforge.plantuml.svek.Margins; -import net.sourceforge.plantuml.svek.PackageStyle; -import net.sourceforge.plantuml.svek.SingleStrategy; -import net.sourceforge.plantuml.svek.image.EntityImageStateCommon; -import net.sourceforge.plantuml.ugraphic.UFont; -import net.sourceforge.plantuml.ugraphic.color.HColor; - -final public class EntityImp - implements SpecificBackcolorable, Hideable, Removeable, LineConfigurable, ILeaf, IGroup { - - private final ZEntityFactory entityFactory; - - private Quark quark; - - private Url url; - - private final Bodier bodier; - private final String uid; - private Display display = Display.empty(); - private DisplayPositioned legend = null; - - private LeafType leafType; - private Stereotype stereotype; - private Stereostyles stereostyles = Stereostyles.NONE; - private String generic; - - private GroupType groupType; - - // Other - private Margins margins = Margins.NONE; - private final Collection portShortNames = new HashSet<>(); - private int xposition; - private IEntityImage svekImage; - - private USymbol symbol; - private final int rawLayout; - private char concurrentSeparator; - private LineLocation codeLine; - - private Set tags = new LinkedHashSet<>(); - private final List notesTop = new ArrayList<>(); - private final List notesBottom = new ArrayList<>(); - - // @Override - public void addNote(Display note, Position position, Colors colors) { - if (position == Position.TOP) - notesTop.add(CucaNote.build(note, position, colors)); - else if (position == Position.BOTTOM) - notesBottom.add(CucaNote.build(note, position, colors)); - } - - // @Override - public List getNotes(Position position) { - if (position == Position.TOP) - return Collections.unmodifiableList(notesTop); - if (position == Position.BOTTOM) - return Collections.unmodifiableList(notesBottom); - throw new IllegalArgumentException(); - } - - public void addStereotag(Stereotag tag) { - this.tags.add(tag); - } - - public Set stereotags() { - return Collections.unmodifiableSet(tags); - } - - // Back to Entity - private EntityImp(Quark quark, ZEntityFactory entityFactory, Bodier bodier, int rawLayout) { - this.quark = Objects.requireNonNull(quark); - this.uid = StringUtils.getUid("cl", entityFactory.getDiagram().getUniqueSequence()); - this.entityFactory = entityFactory; - this.bodier = bodier; - this.rawLayout = rawLayout; - } - - EntityImp(Quark quark, ZEntityFactory entityFactory, Bodier bodier, LeafType leafType, int rawLayout) { - this(Objects.requireNonNull(quark), entityFactory, bodier, rawLayout); - // System.err.println("ID for leaf=" + code + " " + ident); - // ident.checkSameAs(code, namespaceSeparator); - this.leafType = leafType; - } - - EntityImp(Quark quark, ZEntityFactory entityFactory, Bodier bodier, GroupType groupType, int rawLayout) { - this(Objects.requireNonNull(quark), entityFactory, bodier, rawLayout); - // System.err.println("ID for group=" + code + " " + ident); - this.groupType = groupType; - } - - public LeafType getLeafType() { - return leafType; - } - - public boolean muteToType(LeafType newType, USymbol newSymbol) { - checkNotGroup(); - Objects.requireNonNull(newType); - if (leafType != LeafType.STILL_UNKNOWN) { - if (newType == this.leafType) - return true; - - if (leafType != LeafType.ANNOTATION && leafType != LeafType.ABSTRACT_CLASS && leafType != LeafType.CLASS - && leafType != LeafType.ENUM && leafType != LeafType.INTERFACE) { - return false; - // throw new IllegalArgumentException("type=" + leafType); - } - if (newType != LeafType.ANNOTATION && newType != LeafType.ABSTRACT_CLASS && newType != LeafType.CLASS - && newType != LeafType.ENUM && newType != LeafType.INTERFACE && newType != LeafType.OBJECT) { - return false; - // throw new IllegalArgumentException("newtype=" + newType); - } - } - if (leafType == LeafType.CLASS && newType == LeafType.OBJECT) - bodier.muteClassToObject(); - - this.leafType = newType; - this.symbol = newSymbol; - return true; - } - - public Quark getQuark() { - return quark; - } - - public String getCodeGetName() { - return getQuark().getName(); - } - - public Display getDisplay() { -// if (intricated) -// return entityFactory.getIntricatedDisplay(ident); - return display; - } - - public void setDisplay(Display display) { - this.display = display; - } - - public String getUid() { - return uid; - } - - public Stereotype getStereotype() { - return stereotype; - } - - public final void setStereotype(Stereotype stereotype) { - this.stereotype = stereotype; - } - -// public final IGroup getParentContainer() { -// return entityFactory.getParentContainer(ident, parentContainer); -// // Objects.requireNonNull(parentContainer); -// // return parentContainer; -// } - - @Override - public String toString() { - return quark.toString() + " " + display + "(" + leafType + ")[" + groupType + "] " + getUid(); - } - - public final Url getUrl99() { - return url; - } - - public boolean hasUrl() { - if (Display.isNull(display) == false && display.hasUrl()) - return true; - - if (bodier.hasUrl()) - return true; - - return url != null; - } - - public final void addUrl(Url url) { - this.url = url; - } - - public final Margins getMargins() { - checkNotGroup(); - return margins; - } - - public final void ensureMargins(Margins newMargins) { - // checkNotGroup(); - this.margins = this.margins.merge(newMargins); - } - - public int getXposition() { - checkNotGroup(); - return xposition; - } - - public void setXposition(int pos) { - checkNotGroup(); - xposition = pos; - } - - public final IEntityImage getSvekImage() { - checkNotGroup(); - return svekImage; - } - - public final void setSvekImage(IEntityImage svekImage) { - checkNotGroup(); - this.svekImage = svekImage; - } - - public final void setGeneric(String generic) { - checkNotGroup(); - this.generic = generic; - } - - public final String getGeneric() { - checkNotGroup(); - return generic; - } - - public Bodier getBodier() { - return bodier; - } - - public EntityPosition getEntityPosition() { -// if (leafType == LeafType.PORT) -// return EntityPosition.PORT; - - if (leafType == LeafType.PORTIN) - return EntityPosition.PORTIN; - - if (leafType == LeafType.PORTOUT) - return EntityPosition.PORTOUT; - - if (leafType != LeafType.STATE) - return EntityPosition.NORMAL; - - if (quark.isRoot()) - return EntityPosition.NORMAL; - - final Stereotype stereotype = getStereotype(); - if (stereotype == null) - return EntityPosition.NORMAL; - - return EntityPosition.fromStereotype(stereotype.getLabel(Guillemet.DOUBLE_COMPARATOR)); - - } - - // ---------- - - private void checkGroup() { - if (isGroup() == false) - throw new UnsupportedOperationException(); - - } - - private void checkNotGroup() { - if (isGroup()) - throw new UnsupportedOperationException(); - - } - -// public boolean containsLeafRecurse(ILeaf leaf) { -// if (Objects.requireNonNull(leaf).isGroup()) -// throw new IllegalArgumentException(); -// -// checkGroup(); -// if (leaf.getParentContainer() == this) -// return true; -// -// for (IGroup child : getChildren()) -// if (child.containsLeafRecurse(leaf)) -// return true; -// -// return false; -// } - -// public Collection getLeafsDirect() { -// checkGroup(); -// final List result = new ArrayList<>(); -// for (ILeaf ent : entityFactory.leafs()) { -// if (ent.isGroup()) -// throw new IllegalStateException(); -// -// if (ent.getParentContainer() == this) -// result.add(ent); -// -// } -// return Collections.unmodifiableCollection(result); -// } - -// public Collection getChildren() { -// checkGroup(); -// final Collection result = new ArrayList<>(); -// for (IGroup g : entityFactory.groups()) -// if (g != this && g.getParentContainer() == this) -// result.add(g); -// -// return Collections.unmodifiableCollection(result); -// } - -// public void moveEntitiesTo(IGroup dest) { -// if (entityFactory.namespaceSeparator.V1972()) { -// moveEntitiesTo1972(dest); -// return; -// } -// checkGroup(); -// if (dest.isGroup() == false) -// throw new UnsupportedOperationException(); -// -// for (ILeaf ent : getLeafsDirect()) -// ((ZEntityImpl) ent).parentContainer = dest; -// -// for (IGroup g : dest.getChildren()) -// // ((EntityImpl) g).parentContainer = dest; -// throw new IllegalStateException(); -// -// for (IGroup g : getChildren()) { -// if (g == dest) -// continue; -// -// ((ZEntityImpl) g).parentContainer = dest; -// } -// -// } - -// private void moveEntitiesTo1972(IGroup dest) { -// checkGroup(); -// if (dest.isGroup() == false) -// throw new UnsupportedOperationException(); -// -// // System.err.println("moveEntitiesTo1972::before1::groups2=" + -// // entityFactory.groups2()); -// final Ident firstIdent = getIdent(); -// final Ident destIdent = dest.getIdent(); -// // System.err.println("moveEntitiesTo1972::this=" + firstIdent); -// // System.err.println("moveEntitiesTo1972::dest=" + destIdent); -// if (destIdent.startsWith(firstIdent) == false) -// throw new UnsupportedOperationException(); -// -// // System.err.println("moveEntitiesTo1972::before2::groups2=" + -// // entityFactory.groups2()); -// for (ILeaf ent : new ArrayList<>(entityFactory.leafs2())) { -// Ident ident = ent.getIdent(); -// if (ident.equals(firstIdent) == false && ident.startsWith(firstIdent) -// && ident.startsWith(destIdent) == false) { -// // System.err.print("moving leaf ident1=" + ident); -// entityFactory.leafs2.remove(ident); -// ident = ident.move(firstIdent, destIdent); -// // System.err.println(" to ident2=" + ident); -// ((ZEntityImpl) ent).ident = ident; -// ((ZEntityImpl) ent).code = ident; -// entityFactory.leafs2.put(ident, ent); -// } -// } -// // System.err.println("moveEntitiesTo1972::before3::groups2=" + -// // entityFactory.groups2()); -// for (IGroup ent : new ArrayList<>(entityFactory.groups2())) { -// Ident ident = ent.getIdent(); -// // System.err.println("found=" + ident + " " + ident.startsWith(firstIdent) + " -// // " -// // + ident.startsWith(destIdent)); -// if (ident.equals(firstIdent) == false && ident.startsWith(firstIdent) -// && ident.startsWith(destIdent) == false) { -// // System.err.print("moving gr ident1=" + ident); -// entityFactory.groups2.remove(ident); -// ident = ident.move(firstIdent, destIdent); -// // System.err.println(" to ident2=" + ident); -// ((ZEntityImpl) ent).ident = ident; -// ((ZEntityImpl) ent).code = ident; -// entityFactory.groups2.put(ident, ent); -// // System.err.println("-->groups2=" + entityFactory.groups2()); -// } -// } -// // System.err.println("moveEntitiesTo1972::after::groups2=" + -// // entityFactory.groups2()); -// // for (IGroup g : dest.getChildren()) { -// // // ((EntityImpl) g).parentContainer = dest; -// // throw new IllegalStateException(); -// // } -// // -// // for (IGroup g : getChildren()) { -// // if (g == dest) { -// // continue; -// // } -// // ((EntityImpl) g).parentContainer = dest; -// // } -// -// } - -// public int size() { -// checkGroup(); -// return getLeafsDirect().size(); -// } - - public GroupType getGroupType() { - checkGroup(); - return groupType; - } - -// public Code getNamespace() { -// checkGroup(); -// return namespace; -// } - - public PackageStyle getPackageStyle() { - checkGroup(); - if (stereotype == null) - return null; - - return stereotype.getPackageStyle(); - } - - public boolean isGroup() { - if (groupType != null && leafType != null) - throw new IllegalStateException(); - - assert groupType == null || leafType == null; - if (groupType != null) - return true; - - if (leafType != null) - return false; - - throw new IllegalStateException(); - } - - // ---- other - - public void overrideImage(IEntityImage img, LeafType leafType) { - checkGroup(); - this.svekImage = img; - this.url = null; - - for (final Link link : new ArrayList<>(entityFactory.getLinks())) - if (EntityUtils.isPureInnerLink12(this, link)) - entityFactory.removeLink(link); - -// if (entityFactory.namespaceSeparator.V1972()) { -// entityFactory.removeGroup(getIdent()); -// for (ILeaf ent : new ArrayList<>(entityFactory.leafs())) -// if (this != ent && getIdent().equals(ent.getIdent().parent())) -// entityFactory.removeLeaf(ent.getIdent()); -// -// } else { -// entityFactory.removeGroup(getCodeGetName()); -// for (ILeaf ent : new ArrayList<>(entityFactory.leafs())) -// if (this != ent && this == ent.getParentContainer()) -// entityFactory.removeLeaf(ent.getCodeGetName()); -// } -// -// entityFactory.addLeaf(this); -// this.groupType = null; -// this.leafType = leafType; - throw new UnsupportedOperationException("to be finished"); - } - -// void muteToGroup(Code namespaceNew, GroupType groupType, IGroup parentContainer) { -// checkNotGroup(); -// if (parentContainer.isGroup() == false) -// throw new IllegalArgumentException(); -// -// this.namespace = namespaceNew; -// this.groupType = groupType; -// this.leafType = null; -// this.parentContainer = parentContainer; -// } - - public USymbol getUSymbol() { - if (getLeafType() == LeafType.CIRCLE) - return USymbols.INTERFACE; - - // if (symbol != null && stereotype != null && stereotype.getSprite() != null) { - // return symbol.withStereoAlignment(HorizontalAlignment.RIGHT); - // } - return symbol; - } - - public void setUSymbol(USymbol symbol) { - this.symbol = symbol; - } - - public SingleStrategy getSingleStrategy() { - return SingleStrategy.SQUARE; - } - - public boolean isHidden() { - return false; -// if (parentContainer != null && parentContainer.isHidden()) -// return true; -// -// return isHiddenInternal(); - } - -// private boolean isHiddenInternal() { -// if (isGroup()) { -// if (entityFactory.isHidden(this)) -// return true; -// -// if (getLeafsDirect().size() == 0) -// return false; -// -// for (ILeaf leaf : getLeafsDirect()) -// if (((ZEntityImpl) leaf).isHiddenInternal() == false) -// return false; -// -// for (IGroup g : getChildren()) -// if (((ZEntityImpl) g).isHiddenInternal() == false) -// return false; -// -// return true; -// } -// return entityFactory.isHidden(this); -// } - - public boolean isRemoved() { - return false; -// if (parentContainer != null && parentContainer.isRemoved()) -// return true; -// -// return isRemovedInternal(); - } - -// private boolean isRemovedInternal() { -// if (isGroup()) { -// if (entityFactory.isRemoved(this)) -// return true; -// -// if (getLeafsDirect().size() == 0 && getChildren().size() == 0) -// return false; -// -// for (ILeaf leaf : getLeafsDirect()) -// if (((ZEntityImpl) leaf).isRemovedInternal() == false) -// return false; -// -// for (IGroup g : getChildren()) -// if (((ZEntityImpl) g).isRemovedInternal() == false) -// return false; -// -// return true; -// } -// return entityFactory.isRemoved(this); -// } - - public boolean isAloneAndUnlinked() { - return false; -// if (isGroup()) -// return false; -// -// for (Link link : entityFactory.getLinks()) -// if (link.contains(this)) { -// final ILeaf other = (ILeaf) link.getOther(this); -// final boolean removed = entityFactory.isRemovedIgnoreUnlinked(other); -// if (removed == false && link.getType().isInvisible() == false) -// return false; -// } -// -// return true; - } - - private FontParam getTitleFontParam() { - return getGroupType() == GroupType.STATE ? FontParam.STATE : FontParam.PACKAGE; - } - - public FontConfiguration getFontConfigurationForTitle(final ISkinParam skinParam) { - final FontParam fontParam = getTitleFontParam(); - final HColor fontHtmlColor = skinParam.getFontHtmlColor(getStereotype(), fontParam, FontParam.PACKAGE); - final UFont font = skinParam.getFont(getStereotype(), true, fontParam, FontParam.PACKAGE); - final FontConfiguration fontConfiguration = FontConfiguration.create(font, fontHtmlColor, - skinParam.getHyperlinkColor(), skinParam.useUnderlineForHyperlink(), skinParam.getTabSize()); - return fontConfiguration; - } - - public final int getRawLayout() { - return rawLayout; - } - - public char getConcurrentSeparator() { - return concurrentSeparator; - } - - public void setConcurrentSeparator(char separator) { - this.concurrentSeparator = separator; - } - - private Neighborhood neighborhood; - - public void setNeighborhood(Neighborhood neighborhood) { - this.neighborhood = neighborhood; - } - - public Neighborhood getNeighborhood() { - return neighborhood; - } - - private final Map tips = new LinkedHashMap(); - - public void putTip(String member, Display display) { - tips.put(member, display); - } - - public Map getTips() { - return Collections.unmodifiableMap(tips); - } - - private Colors colors = Colors.empty(); - - public Colors getColors() { - return colors; - } - - public void setColors(Colors colors) { - this.colors = colors; - } - - public void setSpecificColorTOBEREMOVED(ColorType type, HColor color) { - if (color != null) - this.colors = colors.add(type, color); - - } - - public Collection getPortShortNames() { - checkNotGroup(); - return Collections.unmodifiableCollection(portShortNames); - } - - public void addPortShortName(String portShortName) { - portShortNames.add(portShortName); - } - - private VisibilityModifier visibility; - - public void setVisibilityModifier(VisibilityModifier visibility) { - this.visibility = visibility; - - } - - public VisibilityModifier getVisibilityModifier() { - return visibility; - } - - public void setLegend(DisplayPositioned legend) { - checkGroup(); - this.legend = legend; - } - - public DisplayPositioned getLegend() { - return legend; - } - -// private boolean intricated; -// -// public void setIntricated(boolean intricated) { -// this.intricated = intricated; -// } - -// private IGroup originalGroup; -// -// public void setOriginalGroup(IGroup originalGroup) { -// this.originalGroup = originalGroup; -// this.legend = originalGroup.getLegend(); -// } - - public IGroup getOriginalGroup() { - throw new UnsupportedOperationException(); - // return originalGroup; - } - - private boolean together; - - public void setThisIsTogether() { - this.together = true; - } - - public String getCodeLine() { - if (this.codeLine == null) - return null; - - return "" + this.codeLine.getPosition(); - } - - public void setCodeLine(LineLocation codeLine) { - this.codeLine = codeLine; - } - - // @Override - public void setStereostyle(String stereo) { - this.stereostyles = Stereostyles.build(stereo); - } - - // @Override - public Stereostyles getStereostyles() { - return stereostyles; - } - - private final Map> kals = new EnumMap<>(Direction.class); - - public void addKal(Kal kal) { - final Direction position = kal.getPosition(); - List list = kals.get(position); - if (list == null) { - list = new ArrayList<>(); - kals.put(position, list); - } - list.add(kal); - } - - public List getKals(Direction position) { - final List result = kals.get(position); - if (result == null) - return Collections.emptyList(); - return Collections.unmodifiableList(result); - } - - public ICucaDiagram getDiagram() { - return entityFactory.getDiagram(); - } - - private boolean isStatic; - - // @Override - public void setStatic(boolean isStatic) { - this.isStatic = isStatic; - } - - // @Override - public boolean isStatic() { - return isStatic; - } - - // For group - - public TextBlock getStateHeader(ISkinParam skinParam) { - checkGroup(); - final Style style = EntityImageStateCommon.getStyleStateHeader(this, skinParam); - final List details = getBodier().getRawBody(); - - if (details.size() == 0) - return new TextBlockEmpty(); - - if (style == null) - throw new IllegalArgumentException(); - final FontConfiguration fontConfiguration = FontConfiguration.create(skinParam, style); - - Display display = null; - for (CharSequence s : details) - if (display == null) - display = Display.getWithNewlines(s.toString()); - else - display = display.addAll(Display.getWithNewlines(s.toString())); - - return display.create(fontConfiguration, HorizontalAlignment.LEFT, skinParam); - - } - - @Override - public Code getCode() { - return quark; - } - - @Override - public Ident getIdent() { - throw new UnsupportedOperationException(); - } - - @Override - public IGroup getParentContainer() { - return (IGroup) quark.getParent().getData(); - } - - @Override - public void setContainer(IGroup container) { - throw new UnsupportedOperationException(); - } - - @Override - public boolean containsLeafRecurse(ILeaf entity) { - throw new UnsupportedOperationException(); - } - - @Override - public Collection getLeafsDirect() { - throw new UnsupportedOperationException(); - } - - @Override - public Collection getChildren() { - throw new UnsupportedOperationException(); - } - - @Override - public void moveEntitiesTo(IGroup dest) { - throw new UnsupportedOperationException(); - } - - @Override - public int size() { - throw new UnsupportedOperationException(); - } - - @Override - public Code getNamespace() { - throw new UnsupportedOperationException(); - } - -} diff --git a/src/net/sourceforge/plantuml/baraye/b/ILeaf.java b/src/net/sourceforge/plantuml/baraye/b/ILeaf.java deleted file mode 100644 index 8432802dd..000000000 --- a/src/net/sourceforge/plantuml/baraye/b/ILeaf.java +++ /dev/null @@ -1,83 +0,0 @@ -/* ======================================================================== - * PlantUML : a free UML diagram generator - * ======================================================================== - * - * (C) Copyright 2009-2023, Arnaud Roques - * - * Project Info: http://plantuml.com - * - * If you like this project or if you find it useful, you can support us at: - * - * http://plantuml.com/patreon (only 1$ per month!) - * http://plantuml.com/paypal - * - * This file is part of PlantUML. - * - * PlantUML is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * PlantUML distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY - * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public - * License for more details. - * - * You should have received a copy of the GNU General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, - * USA. - * - * - * Original Author: Arnaud Roques - * - * - */ -package net.sourceforge.plantuml.baraye.b; - -import java.util.Collection; - -import net.sourceforge.plantuml.cucadiagram.LeafType; -import net.sourceforge.plantuml.cucadiagram.dot.Neighborhood; -import net.sourceforge.plantuml.graphic.USymbol; -import net.sourceforge.plantuml.skin.VisibilityModifier; -import net.sourceforge.plantuml.svek.IEntityImage; -import net.sourceforge.plantuml.svek.Margins; - -public interface ILeaf extends IEntity { - - public void setContainer(IGroup container); - - public Margins getMargins(); - - public int getXposition(); - - public void setXposition(int pos); - - public IEntityImage getSvekImage(); - - public String getGeneric(); - - public boolean muteToType(LeafType newType, USymbol newSymbol); - - public void setGeneric(String generic); - - public void setSvekImage(IEntityImage svekImage); - - public void setNeighborhood(Neighborhood neighborhood); - - public Neighborhood getNeighborhood(); - - public Collection getPortShortNames(); - - public void addPortShortName(String portShortName); - - public void setVisibilityModifier(VisibilityModifier visibility); - - public VisibilityModifier getVisibilityModifier(); - - public void setStatic(boolean isStatic); - - public boolean isStatic(); - -} diff --git a/src/net/sourceforge/plantuml/baraye/b/ZEntityFactory.java b/src/net/sourceforge/plantuml/baraye/b/ZEntityFactory.java deleted file mode 100644 index 1c39b52d1..000000000 --- a/src/net/sourceforge/plantuml/baraye/b/ZEntityFactory.java +++ /dev/null @@ -1,501 +0,0 @@ -/* ======================================================================== - * PlantUML : a free UML diagram generator - * ======================================================================== - * - * (C) Copyright 2009-2023, Arnaud Roques - * - * Project Info: http://plantuml.com - * - * If you like this project or if you find it useful, you can support us at: - * - * http://plantuml.com/patreon (only 1$ per month!) - * http://plantuml.com/paypal - * - * This file is part of PlantUML. - * - * PlantUML is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * PlantUML distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY - * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public - * License for more details. - * - * You should have received a copy of the GNU General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, - * USA. - * - * - * Original Author: Arnaud Roques - * - * - */ -package net.sourceforge.plantuml.baraye.b; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.List; -import java.util.Objects; -import java.util.Set; - -import net.sourceforge.plantuml.ISkinParam; -import net.sourceforge.plantuml.baraye.Plasma; -import net.sourceforge.plantuml.baraye.Quark; -import net.sourceforge.plantuml.baraye.a.ILeaf; -import net.sourceforge.plantuml.cucadiagram.Bodier; -import net.sourceforge.plantuml.cucadiagram.BodierJSon; -import net.sourceforge.plantuml.cucadiagram.BodierMap; -import net.sourceforge.plantuml.cucadiagram.BodyFactory; -import net.sourceforge.plantuml.cucadiagram.Display; -import net.sourceforge.plantuml.cucadiagram.GroupType; -import net.sourceforge.plantuml.cucadiagram.HideOrShow2; -import net.sourceforge.plantuml.cucadiagram.ICucaDiagram; -import net.sourceforge.plantuml.cucadiagram.Ident; -import net.sourceforge.plantuml.cucadiagram.LeafType; -import net.sourceforge.plantuml.cucadiagram.Link; -import net.sourceforge.plantuml.cucadiagram.Stereotype; -import net.sourceforge.plantuml.cucadiagram.entity.IEntityFactory; -import net.sourceforge.plantuml.skin.VisibilityModifier; - -public final class ZEntityFactory implements IEntityFactory { - - private final List links = new ArrayList<>(); - - private int rawLayout; - - private final Plasma plasma; - - private final List hides2; - private final List removed; - /* private */ final public ICucaDiagram namespaceSeparator; - // private final boolean mergeIntricated; - // private Map emptyGroupsAsNode = new HashMap(); - - public ILeaf getLeafForEmptyGroup(IGroup g) { -// return emptyGroupsAsNode.get(g); - throw new UnsupportedOperationException(); - } - - public ILeaf createLeafForEmptyGroup(IGroup g, ISkinParam skinParam) { - throw new UnsupportedOperationException(); -// final ILeaf folder = this.createLeaf(g.getIdent(), g.getCode(), g.getDisplay(), LeafType.EMPTY_PACKAGE, -// g.getParentContainer(), null, this.namespaceSeparator.getNamespaceSeparator()); -// ((ZEntityImpl) folder).setOriginalGroup(g); -// final USymbol symbol = g.getUSymbol(); -// folder.setUSymbol(symbol); -// folder.setStereotype(g.getStereotype()); -// folder.setColors(g.getColors()); -// if (g.getUrl99() != null) -// folder.addUrl(g.getUrl99()); -// for (Stereotag tag : g.stereotags()) -// folder.addStereotag(tag); -// -// emptyGroupsAsNode.put(g, folder); -// return folder; - } -// -// public Display getIntricatedDisplay(Ident ident) { -// final Set known = new HashSet<>(groups2.keySet()); -// known.removeAll(hiddenBecauseOfIntrication); -// String sep = namespaceSeparator.getNamespaceSeparator(); -// if (sep == null) -// sep = "."; -// -// for (int check = ident.size() - 1; check > 0; check--) -// if (known.contains(ident.getPrefix(check))) -// // if (hiddenBecauseOfIntrication.contains(ident.getPrefix(check)) == false) -// return Display.getWithNewlines(ident.getSuffix(check).toString(sep)) -// .withCreoleMode(CreoleMode.SIMPLE_LINE); -// -// return Display.getWithNewlines(ident.toString(sep)).withCreoleMode(CreoleMode.SIMPLE_LINE); -// } -// -// private final Collection hiddenBecauseOfIntrication = new ArrayList<>(); -// - public IGroup isIntricated(IGroup parent) { -// final int leafs = parent.getLeafsDirect().size(); -// final Collection children = parent.getChildren(); -// if (leafs == 0 && children.size() == 1) { -// final IGroup g = children.iterator().next(); -// if (g.getLeafsDirect().size() == 0 && g.getChildren().size() == 0 && g.getGroupType() == GroupType.PACKAGE) -// return null; -// -// for (Link link : this.getLinks()) -// if (link.contains(parent)) -// return null; -// -// ((ZEntityImpl) g).setIntricated(true); -// hiddenBecauseOfIntrication.add(parent.getIdent()); -// return g; -// } -// return null; - throw new UnsupportedOperationException(); - } - - public ZEntityFactory(List hides2, List removed, ICucaDiagram namespaceSeparator) { - this.hides2 = hides2; - this.removed = removed; - this.namespaceSeparator = namespaceSeparator; - // this.plasma = new Plasma(namespaceSeparator.getNamespaceSeparator()); - this.plasma = new Plasma("."); - } - - public boolean isHidden(EntityImp leaf) { - return false; -// final IEntity other = isNoteWithSingleLinkAttachedTo(leaf); -// if (other instanceof ILeaf) -// return isHidden((ILeaf) other); -// -// boolean hidden = false; -// for (HideOrShow2 hide : hides2) -// hidden = hide.apply(hidden, leaf); -// -// return hidden; - } - - public boolean isRemoved(Stereotype stereotype) { - boolean result = false; - for (HideOrShow2 hide : removed) - result = hide.apply(result, stereotype); - - return result; - } - - public boolean isRemoved(EntityImp leaf) { - return false; -// final IEntity other = isNoteWithSingleLinkAttachedTo(leaf); -// if (other instanceof ILeaf) -// return isRemoved((ILeaf) other); -// -// boolean result = false; -// for (HideOrShow2 hide : removed) -// result = hide.apply(result, leaf); -// -// return result; - } - -// private IEntity isNoteWithSingleLinkAttachedTo(ILeaf leaf) { -// if (leaf.getLeafType() != LeafType.NOTE) -// return null; -// IEntity result = null; -// for (Link link : this.getLinks()) { -// if (link.getType().isInvisible()) -// continue; -// if (link.contains(leaf)) { -// if (result != null) -// return result; -// result = link.getOther(leaf); -// } -// } -// return result; -// -// } - -// public boolean isRemovedIgnoreUnlinked(ILeaf leaf) { -// boolean result = false; -// for (HideOrShow2 hide : removed) -// if (hide.isAboutUnlinked() == false) -// result = hide.apply(result, leaf); -// -// return result; -// } - - public EntityImp createLeaf(Quark quark, Display display, LeafType entityType, Set hides, - String namespaceSeparator) { - final Bodier bodier; - if (Objects.requireNonNull(entityType) == LeafType.MAP) - bodier = new BodierMap(); - else if (Objects.requireNonNull(entityType) == LeafType.JSON) - bodier = new BodierJSon(); - else - bodier = BodyFactory.createLeaf(entityType, hides); - - final EntityImp result = new EntityImp(quark, this, bodier, entityType, rawLayout); - // bodier.setLeaf(result); - result.setDisplay(display); - return result; - } - - public EntityImp createGroup(Quark quark, Display display, GroupType groupType, Set hides, - String namespaceSeparator) { - Objects.requireNonNull(groupType); - if (quark.getData() != null) - return (EntityImp) quark.getData(); -// for (Entry ent : groups2.entrySet()) -// if (ent.getKey().equals(ident)) -// return ent.getValue(); - - final Bodier bodier = BodyFactory.createGroup(hides); - final EntityImp result = new EntityImp(quark, this, bodier, groupType, rawLayout); - if (Display.isNull(display) == false) - result.setDisplay(display); - - return result; - } - - public void addLeaf(ILeaf entity) { -// if (namespaceSeparator.V1972() == false) -// leafsByCode.put(entity.getCodeGetName(), entity); -// leafs2.put(entity.getIdent(), entity); -// if (namespaceSeparator.V1972()) -// ensureParentIsCreated(entity.getIdent()); - throw new UnsupportedOperationException(); - } -// -// public void addGroup(IGroup group) { -// if (namespaceSeparator.V1972() == false) -// groupsByCode.put(group.getCodeGetName(), group); -// groups2.put(group.getIdent(), group); -// if (namespaceSeparator.V1972()) -// ensureParentIsCreated(group.getIdent()); -// } -// -// private void ensureParentIsCreated(Ident ident) { -// if (groups2.get(ident.parent()) != null) -// return; -// getParentContainer(ident, null); -// } - -// void removeGroup(String name) { -// if (namespaceSeparator.V1972()) -// throw new UnsupportedOperationException(); -// final IEntity removed = Objects.requireNonNull(groupsByCode.remove(name)); -// final IEntity removed2 = groups2.remove(removed.getIdent()); -// if (removed != removed2) { -// bigError(); -// } -// } -// -// void removeGroup(Ident ident) { -// Objects.requireNonNull(groups2.remove(Objects.requireNonNull(ident))); -// } -// - public static void bigError() { - // Thread.dumpStack(); - // System.exit(0); - throw new IllegalArgumentException(); - } - -// void removeLeaf(String name) { -// if (namespaceSeparator.V1972()) -// throw new UnsupportedOperationException(); -// final IEntity removed = Objects.requireNonNull(leafsByCode.remove(Objects.requireNonNull(name))); -// final IEntity removed2 = leafs2.remove(removed.getIdent()); -// if (removed != removed2) { -// bigError(); -// } -// } -// -// void removeLeaf(Ident ident) { -// final IEntity removed = leafs2.remove(Objects.requireNonNull(ident)); -// if (removed == null) { -// System.err.println("leafs2=" + leafs2.keySet()); -// throw new IllegalArgumentException(ident.toString()); -// } -// } -// -// private void removeLeaf1972(ILeaf leaf) { -// final boolean removed = leafs2.values().remove(leaf); -// if (removed == false) { -// System.err.println("leafs2=" + leafs2.keySet()); -// throw new IllegalArgumentException(leaf.toString()); -// } -// } -// -// public IGroup muteToGroup(String name, Code namespace, GroupType type, IGroup parent) { -// if (namespaceSeparator.V1972()) -// throw new UnsupportedOperationException(); -// final ILeaf leaf = leafsByCode.get(name); -// ((ZEntityImpl) leaf).muteToGroup(namespace, type, parent); -// final IGroup result = (IGroup) leaf; -// removeLeaf(name); -// return result; -// } - -// public IGroup muteToGroup1972(Ident ident, Code namespace, GroupType type, IGroup parent) { -// if (!namespaceSeparator.V1972()) -// throw new UnsupportedOperationException(); -// final ILeaf leaf; -// if (namespaceSeparator.getNamespaceSeparator() == null) -// leaf = getLeafVerySmart(ident); -// else -// leaf = leafs2.get(ident); -// ((ZEntityImpl) leaf).muteToGroup(namespace, type, parent); -// final IGroup result = (IGroup) leaf; -// removeLeaf1972(leaf); -// return result; -// } - - public IGroup getRootGroup() { - throw new UnsupportedOperationException(); -// return rootGroup; - } - - public final ILeaf getLeafStrict(Ident ident) { - throw new UnsupportedOperationException(); -// return leafs2.get(ident); - } -// -// public final ILeaf getLeafSmart(Ident ident) { -// if (!namespaceSeparator.V1972()) -// throw new UnsupportedOperationException(); -// final ILeaf result = leafs2.get(ident); -// if (result == null && ident.size() == 1) -// for (Entry ent : leafs2.entrySet()) -// if (ent.getKey().getLast().equals(ident.getLast())) -// return ent.getValue(); -// -// return result; -// } -// -// public final ILeaf getLeafVerySmart(Ident ident) { -// if (!namespaceSeparator.V1972()) -// throw new UnsupportedOperationException(); -// final ILeaf result = leafs2.get(ident); -// if (result == null) -// for (Entry ent : leafs2.entrySet()) -// if (ent.getKey().getLast().equals(ident.getLast())) -// return ent.getValue(); -// -// return result; -// } -// -// public Ident buildFullyQualified(Ident currentPath, Ident id) { -// if (currentPath.equals(id) == false) -// if (leafs2.containsKey(id) || groups2.containsKey(id)) -// return id; -// -// if (id.size() > 1) -// return id; -// -// return currentPath.add(id); -// } -// -// public final IGroup getGroupStrict(Ident ident) { -// if (namespaceSeparator.getNamespaceSeparator() == null) -// return getGroupVerySmart(ident); -// -// final IGroup result = groups2.get(ident); -// return result; -// } -// -// public final IGroup getGroupVerySmart(Ident ident) { -// final IGroup result = groups2.get(ident); -// if (result == null) -// for (Entry ent : groups2.entrySet()) -// if (ent.getKey().getLast().equals(ident.getLast())) -// return ent.getValue(); -// -// return result; -// } -// -// public final ILeaf getLeaf(Code code) { -// if (namespaceSeparator.V1972()) -// throw new UnsupportedOperationException(); -// final ILeaf result = leafsByCode.get(code.getName()); -// if (result != null && result != leafs2.get(result.getIdent())) -// bigError(); -// -// return result; -// } -// -// public final IGroup getGroup(Code code) { -// if (namespaceSeparator.V1972()) -// throw new UnsupportedOperationException(); -// final IGroup result = groupsByCode.get(code.getName()); -// if (result != null && result != groups2.get(result.getIdent())) -// bigError(); -// -// return result; -// } - - public final Collection leafs() { -// if (namespaceSeparator.V1972()) -// return leafs2(); -// final Collection result = Collections.unmodifiableCollection(leafsByCode.values()); -// if (new ArrayList<>(result).equals(new ArrayList<>(leafs2())) == false) -// bigError(); -// -// return result; - throw new UnsupportedOperationException(); - } - - public final Collection groups() { -// if (namespaceSeparator.V1972()) -// return groups2(); -// final Collection result = Collections.unmodifiableCollection(groupsByCode.values()); -// if (new ArrayList<>(result).equals(new ArrayList<>(groups2())) == false) -// bigError(); -// -// return result; - throw new UnsupportedOperationException(); - } -// -// public final Collection groups2() { -// final Collection result = Collections.unmodifiableCollection(groups2.values()); -// return Collections.unmodifiableCollection(result); -// } -// -// public final Collection leafs2() { -// final Collection result = Collections.unmodifiableCollection(leafs2.values()); -// return Collections.unmodifiableCollection(result); -// } - - public void incRawLayout() { - rawLayout++; - } - - public final List getLinks() { - return Collections.unmodifiableList(links); - } - - public void addLink(Link link) { - if (link.isSingle() && containsSimilarLink(link)) - return; - - links.add(link); - } - - private boolean containsSimilarLink(Link other) { - for (Link link : links) - if (other.sameConnections(link)) - return true; - - return false; - } - - public void removeLink(Link link) { - final boolean ok = links.remove(link); - if (ok == false) - throw new IllegalArgumentException(); - - } - -// public IGroup getParentContainer(Ident ident, IGroup parentContainer) { -// if (namespaceSeparator.V1972()) { -// final Ident parent = ident.parent(); -// if (parent.isRoot()) -// return this.rootGroup; -// -// IGroup result = getGroupStrict(parent); -// if (result != null) -// return result; -// -// final Display display = Display.getWithNewlines(parent.getName()); -// result = createGroup(parent, parent, display, null, GroupType.PACKAGE, null, -// Collections.emptySet(), namespaceSeparator.getNamespaceSeparator()); -// addGroup(result); -// return result; -// } -// return Objects.requireNonNull(parentContainer); -// } - - public ICucaDiagram getDiagram() { - return namespaceSeparator; - } - -} diff --git a/src/net/sourceforge/plantuml/classdiagram/AbstractEntityDiagram.java b/src/net/sourceforge/plantuml/classdiagram/AbstractEntityDiagram.java index bd9cd8799..1e71eb7c5 100644 --- a/src/net/sourceforge/plantuml/classdiagram/AbstractEntityDiagram.java +++ b/src/net/sourceforge/plantuml/classdiagram/AbstractEntityDiagram.java @@ -42,7 +42,7 @@ import java.util.List; import java.util.Map; import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.baraye.a.CucaDiagram; +import net.sourceforge.plantuml.baraye.CucaDiagram; import net.sourceforge.plantuml.core.DiagramDescription; import net.sourceforge.plantuml.core.UmlSource; diff --git a/src/net/sourceforge/plantuml/classdiagram/ClassDiagram.java b/src/net/sourceforge/plantuml/classdiagram/ClassDiagram.java index 8ba2175c1..5c552479f 100644 --- a/src/net/sourceforge/plantuml/classdiagram/ClassDiagram.java +++ b/src/net/sourceforge/plantuml/classdiagram/ClassDiagram.java @@ -42,14 +42,14 @@ import java.util.Objects; import net.sourceforge.plantuml.FileFormatOption; import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityUtils; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.core.ImageData; import net.sourceforge.plantuml.core.UmlSource; import net.sourceforge.plantuml.creole.CreoleMode; import net.sourceforge.plantuml.cucadiagram.Code; import net.sourceforge.plantuml.cucadiagram.Display; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; import net.sourceforge.plantuml.cucadiagram.GroupType; import net.sourceforge.plantuml.cucadiagram.Ident; import net.sourceforge.plantuml.cucadiagram.LeafType; diff --git a/src/net/sourceforge/plantuml/classdiagram/command/CommandAddMethod.java b/src/net/sourceforge/plantuml/classdiagram/command/CommandAddMethod.java index 1f169f5a2..9057b12dc 100644 --- a/src/net/sourceforge/plantuml/classdiagram/command/CommandAddMethod.java +++ b/src/net/sourceforge/plantuml/classdiagram/command/CommandAddMethod.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.classdiagram.command; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; diff --git a/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateClass.java b/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateClass.java index f080c3fce..0d9674d8f 100644 --- a/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateClass.java +++ b/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateClass.java @@ -41,7 +41,7 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; diff --git a/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateClassMultilines.java b/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateClassMultilines.java index f515dbe2c..d94cca3e2 100644 --- a/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateClassMultilines.java +++ b/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateClassMultilines.java @@ -41,8 +41,8 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.CommandExecutionResult; diff --git a/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateElementFull2.java b/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateElementFull2.java index 08f3e0b04..0a6359fb8 100644 --- a/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateElementFull2.java +++ b/src/net/sourceforge/plantuml/classdiagram/command/CommandCreateElementFull2.java @@ -42,7 +42,7 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; diff --git a/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShow2.java b/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShow2.java index ee9ff042d..d102597ba 100644 --- a/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShow2.java +++ b/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShow2.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.classdiagram.command; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.CucaDiagram; +import net.sourceforge.plantuml.baraye.CucaDiagram; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShowByGender.java b/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShowByGender.java index 4b2f2f9a1..63c88c1b0 100644 --- a/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShowByGender.java +++ b/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShowByGender.java @@ -38,7 +38,8 @@ package net.sourceforge.plantuml.classdiagram.command; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.UmlDiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.EntityUtils; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; @@ -50,7 +51,6 @@ import net.sourceforge.plantuml.cucadiagram.Code; import net.sourceforge.plantuml.cucadiagram.EntityGender; import net.sourceforge.plantuml.cucadiagram.EntityGenderUtils; import net.sourceforge.plantuml.cucadiagram.EntityPortion; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; import net.sourceforge.plantuml.cucadiagram.Ident; import net.sourceforge.plantuml.cucadiagram.LeafType; import net.sourceforge.plantuml.descdiagram.DescriptionDiagram; diff --git a/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShowSpecificClass.java b/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShowSpecificClass.java index 16cf80cc1..c2405b643 100644 --- a/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShowSpecificClass.java +++ b/src/net/sourceforge/plantuml/classdiagram/command/CommandHideShowSpecificClass.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.classdiagram.command; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.CucaDiagram; +import net.sourceforge.plantuml.baraye.CucaDiagram; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/classdiagram/command/CommandLinkClass.java b/src/net/sourceforge/plantuml/classdiagram/command/CommandLinkClass.java index 13aa06b48..b409841ea 100644 --- a/src/net/sourceforge/plantuml/classdiagram/command/CommandLinkClass.java +++ b/src/net/sourceforge/plantuml/classdiagram/command/CommandLinkClass.java @@ -43,7 +43,7 @@ import net.sourceforge.plantuml.UmlDiagramType; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.RegexConcat; @@ -168,8 +168,8 @@ final public class CommandLinkClass extends SingleLineCommand2 { diff --git a/src/net/sourceforge/plantuml/command/CommandNamespace.java b/src/net/sourceforge/plantuml/command/CommandNamespace.java index caf01b1e6..192cebbf0 100644 --- a/src/net/sourceforge/plantuml/command/CommandNamespace.java +++ b/src/net/sourceforge/plantuml/command/CommandNamespace.java @@ -39,8 +39,8 @@ import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.command.regex.IRegex; import net.sourceforge.plantuml.command.regex.RegexConcat; diff --git a/src/net/sourceforge/plantuml/command/CommandNamespace2.java b/src/net/sourceforge/plantuml/command/CommandNamespace2.java index d8ee3435d..2bc48bbda 100644 --- a/src/net/sourceforge/plantuml/command/CommandNamespace2.java +++ b/src/net/sourceforge/plantuml/command/CommandNamespace2.java @@ -39,8 +39,8 @@ import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.command.regex.IRegex; import net.sourceforge.plantuml.command.regex.RegexConcat; diff --git a/src/net/sourceforge/plantuml/command/CommandNamespaceEmpty.java b/src/net/sourceforge/plantuml/command/CommandNamespaceEmpty.java index 575217c04..2576bc11a 100644 --- a/src/net/sourceforge/plantuml/command/CommandNamespaceEmpty.java +++ b/src/net/sourceforge/plantuml/command/CommandNamespaceEmpty.java @@ -39,8 +39,8 @@ import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.command.regex.IRegex; import net.sourceforge.plantuml.command.regex.RegexConcat; diff --git a/src/net/sourceforge/plantuml/command/CommandPackage.java b/src/net/sourceforge/plantuml/command/CommandPackage.java index 44661729c..b70c300d8 100644 --- a/src/net/sourceforge/plantuml/command/CommandPackage.java +++ b/src/net/sourceforge/plantuml/command/CommandPackage.java @@ -40,8 +40,8 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.classdiagram.command.CommandCreateClassMultilines; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/command/CommandPackageEmpty.java b/src/net/sourceforge/plantuml/command/CommandPackageEmpty.java index d983c4456..f767160bc 100644 --- a/src/net/sourceforge/plantuml/command/CommandPackageEmpty.java +++ b/src/net/sourceforge/plantuml/command/CommandPackageEmpty.java @@ -37,8 +37,8 @@ package net.sourceforge.plantuml.command; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.StringUtils; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.command.regex.IRegex; import net.sourceforge.plantuml.command.regex.RegexConcat; diff --git a/src/net/sourceforge/plantuml/command/note/CommandConstraintOnLinks.java b/src/net/sourceforge/plantuml/command/note/CommandConstraintOnLinks.java index 62aafacf7..4becc8869 100644 --- a/src/net/sourceforge/plantuml/command/note/CommandConstraintOnLinks.java +++ b/src/net/sourceforge/plantuml/command/note/CommandConstraintOnLinks.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.command.note; import java.util.List; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.CucaDiagram; +import net.sourceforge.plantuml.baraye.CucaDiagram; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; diff --git a/src/net/sourceforge/plantuml/command/note/CommandFactoryNote.java b/src/net/sourceforge/plantuml/command/note/CommandFactoryNote.java index 5d4ad4923..57a67ed93 100644 --- a/src/net/sourceforge/plantuml/command/note/CommandFactoryNote.java +++ b/src/net/sourceforge/plantuml/command/note/CommandFactoryNote.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.command.note; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.classdiagram.command.CommandCreateClassMultilines; import net.sourceforge.plantuml.command.BlocLines; diff --git a/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteActivity.java b/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteActivity.java index 142df2748..3ea7688db 100644 --- a/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteActivity.java +++ b/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteActivity.java @@ -41,7 +41,7 @@ import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; import net.sourceforge.plantuml.activitydiagram.ActivityDiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.Command; import net.sourceforge.plantuml.command.CommandExecutionResult; diff --git a/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteOnEntity.java b/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteOnEntity.java index fa0670232..d04c2256c 100644 --- a/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteOnEntity.java +++ b/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteOnEntity.java @@ -41,7 +41,7 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.classdiagram.command.CommandCreateClassMultilines; import net.sourceforge.plantuml.command.BlocLines; diff --git a/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteOnLink.java b/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteOnLink.java index b9004c6d1..df0d6daeb 100644 --- a/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteOnLink.java +++ b/src/net/sourceforge/plantuml/command/note/CommandFactoryNoteOnLink.java @@ -40,7 +40,7 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.CucaDiagram; +import net.sourceforge.plantuml.baraye.CucaDiagram; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.Command; import net.sourceforge.plantuml.command.CommandExecutionResult; diff --git a/src/net/sourceforge/plantuml/command/note/CommandFactoryTipOnEntity.java b/src/net/sourceforge/plantuml/command/note/CommandFactoryTipOnEntity.java index b1a2f4a38..597df9b63 100644 --- a/src/net/sourceforge/plantuml/command/note/CommandFactoryTipOnEntity.java +++ b/src/net/sourceforge/plantuml/command/note/CommandFactoryTipOnEntity.java @@ -39,7 +39,7 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.Command; diff --git a/src/net/sourceforge/plantuml/compositediagram/CompositeDiagram.java b/src/net/sourceforge/plantuml/compositediagram/CompositeDiagram.java index fbe892ffc..89ec0e936 100644 --- a/src/net/sourceforge/plantuml/compositediagram/CompositeDiagram.java +++ b/src/net/sourceforge/plantuml/compositediagram/CompositeDiagram.java @@ -39,7 +39,7 @@ import java.util.Map; import java.util.Objects; import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.core.UmlSource; import net.sourceforge.plantuml.cucadiagram.Code; diff --git a/src/net/sourceforge/plantuml/compositediagram/command/CommandCreateBlock.java b/src/net/sourceforge/plantuml/compositediagram/command/CommandCreateBlock.java index d09ea41ba..221cfb54f 100644 --- a/src/net/sourceforge/plantuml/compositediagram/command/CommandCreateBlock.java +++ b/src/net/sourceforge/plantuml/compositediagram/command/CommandCreateBlock.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.compositediagram.command; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/compositediagram/command/CommandCreatePackageBlock.java b/src/net/sourceforge/plantuml/compositediagram/command/CommandCreatePackageBlock.java index b434f5c85..8a130cca6 100644 --- a/src/net/sourceforge/plantuml/compositediagram/command/CommandCreatePackageBlock.java +++ b/src/net/sourceforge/plantuml/compositediagram/command/CommandCreatePackageBlock.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.compositediagram.command; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/compositediagram/command/CommandEndPackageBlock.java b/src/net/sourceforge/plantuml/compositediagram/command/CommandEndPackageBlock.java index 5719e265b..3816152ab 100644 --- a/src/net/sourceforge/plantuml/compositediagram/command/CommandEndPackageBlock.java +++ b/src/net/sourceforge/plantuml/compositediagram/command/CommandEndPackageBlock.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.compositediagram.command; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/compositediagram/command/CommandLinkBlock.java b/src/net/sourceforge/plantuml/compositediagram/command/CommandLinkBlock.java index 466d397c6..86fc1daa3 100644 --- a/src/net/sourceforge/plantuml/compositediagram/command/CommandLinkBlock.java +++ b/src/net/sourceforge/plantuml/compositediagram/command/CommandLinkBlock.java @@ -35,7 +35,7 @@ package net.sourceforge.plantuml.compositediagram.command; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/cucadiagram/Bodier.java b/src/net/sourceforge/plantuml/cucadiagram/Bodier.java index 9eea99ca5..427550f7d 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/Bodier.java +++ b/src/net/sourceforge/plantuml/cucadiagram/Bodier.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.cucadiagram; import java.util.List; import net.sourceforge.plantuml.ISkinParam; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.TextBlock; import net.sourceforge.plantuml.style.Style; diff --git a/src/net/sourceforge/plantuml/cucadiagram/BodierJSon.java b/src/net/sourceforge/plantuml/cucadiagram/BodierJSon.java index 7df73e953..ab906c63b 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/BodierJSon.java +++ b/src/net/sourceforge/plantuml/cucadiagram/BodierJSon.java @@ -39,7 +39,7 @@ import java.util.List; import java.util.Objects; import net.sourceforge.plantuml.ISkinParam; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.TextBlock; import net.sourceforge.plantuml.json.JsonValue; diff --git a/src/net/sourceforge/plantuml/cucadiagram/BodierLikeClassOrObject.java b/src/net/sourceforge/plantuml/cucadiagram/BodierLikeClassOrObject.java index 197a0960e..4123872e9 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/BodierLikeClassOrObject.java +++ b/src/net/sourceforge/plantuml/cucadiagram/BodierLikeClassOrObject.java @@ -44,7 +44,7 @@ import java.util.Set; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.UrlBuilder; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.creole.Parser; import net.sourceforge.plantuml.creole.legacy.CreoleParser; import net.sourceforge.plantuml.graphic.FontConfiguration; diff --git a/src/net/sourceforge/plantuml/cucadiagram/BodierMap.java b/src/net/sourceforge/plantuml/cucadiagram/BodierMap.java index 51fa841d6..744dd0d3d 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/BodierMap.java +++ b/src/net/sourceforge/plantuml/cucadiagram/BodierMap.java @@ -46,7 +46,7 @@ import java.util.regex.Pattern; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.LineBreakStrategy; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.TextBlock; import net.sourceforge.plantuml.style.Style; diff --git a/src/net/sourceforge/plantuml/cucadiagram/BodierSimple.java b/src/net/sourceforge/plantuml/cucadiagram/BodierSimple.java index 84f108b49..7dab8f8c9 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/BodierSimple.java +++ b/src/net/sourceforge/plantuml/cucadiagram/BodierSimple.java @@ -41,7 +41,7 @@ import java.util.List; import java.util.Objects; import net.sourceforge.plantuml.ISkinParam; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.HorizontalAlignment; import net.sourceforge.plantuml.graphic.TextBlock; diff --git a/src/net/sourceforge/plantuml/cucadiagram/BodyEnhanced1.java b/src/net/sourceforge/plantuml/cucadiagram/BodyEnhanced1.java index 1551b9890..6a9f10156 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/BodyEnhanced1.java +++ b/src/net/sourceforge/plantuml/cucadiagram/BodyEnhanced1.java @@ -46,7 +46,7 @@ import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XRectangle2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.creole.CreoleMode; import net.sourceforge.plantuml.creole.Parser; import net.sourceforge.plantuml.creole.legacy.CreoleParser; diff --git a/src/net/sourceforge/plantuml/cucadiagram/BodyEnhanced2.java b/src/net/sourceforge/plantuml/cucadiagram/BodyEnhanced2.java index f6a6f22a4..415f82e37 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/BodyEnhanced2.java +++ b/src/net/sourceforge/plantuml/cucadiagram/BodyEnhanced2.java @@ -36,11 +36,13 @@ package net.sourceforge.plantuml.cucadiagram; import java.util.ArrayList; +import java.util.Iterator; import java.util.List; -import net.sourceforge.plantuml.Guillemet; +import net.sourceforge.plantuml.EmbeddedDiagram; import net.sourceforge.plantuml.ISkinSimple; import net.sourceforge.plantuml.LineBreakStrategy; +import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.HorizontalAlignment; import net.sourceforge.plantuml.graphic.StringBounder; @@ -82,8 +84,14 @@ public class BodyEnhanced2 extends BodyEnhancedAbstract { char separator = 0; TextBlock title = null; Display display = Display.empty(); - for (CharSequence s : rawBody) - if (isBlockSeparator(s.toString())) { + final Iterator it = rawBody.iterator(); + while (it.hasNext()) { + final CharSequence s = it.next(); + final String type = EmbeddedDiagram.getEmbeddedType(StringUtils.trinNoTrace(s)); + if (type != null) { + display = display.add(s); + display = addOneSingleLineManageEmbedded2(it, display); + } else if (isBlockSeparator(s.toString())) { blocks.add(decorate(getTextBlock(display), separator, title, stringBounder)); separator = s.charAt(0); title = getTitle(s.toString(), skinParam); @@ -93,6 +101,7 @@ public class BodyEnhanced2 extends BodyEnhancedAbstract { // s = Guillemet.GUILLEMET.manageGuillemet(s.toString()); display = display.add(s); } + } blocks.add(decorate(getTextBlock(display), separator, title, stringBounder)); @@ -108,6 +117,23 @@ public class BodyEnhanced2 extends BodyEnhancedAbstract { return area; } + private static Display addOneSingleLineManageEmbedded2(Iterator it, Display display) { + int nested = 1; + while (it.hasNext()) { + final CharSequence s = it.next(); + display = display.add(s); + if (EmbeddedDiagram.getEmbeddedType(StringUtils.trinNoTrace(s)) != null) + // if (s.getTrimmed().getString().startsWith(EmbeddedDiagram.EMBEDDED_START)) + nested++; + else if (StringUtils.trinNoTrace(s).equals(EmbeddedDiagram.EMBEDDED_END)) { + nested--; + if (nested == 0) + return display; + } + } + return display; + } + private TextBlock getTextBlock(Display display) { final TextBlock result = display.create9(titleConfig, align, skinParam, lineBreakStrategy); return result; diff --git a/src/net/sourceforge/plantuml/cucadiagram/BodyFactory.java b/src/net/sourceforge/plantuml/cucadiagram/BodyFactory.java index 5735b319c..5a6a0de84 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/BodyFactory.java +++ b/src/net/sourceforge/plantuml/cucadiagram/BodyFactory.java @@ -41,7 +41,7 @@ import java.util.Set; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.ISkinSimple; import net.sourceforge.plantuml.LineBreakStrategy; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.HorizontalAlignment; import net.sourceforge.plantuml.graphic.TextBlock; diff --git a/src/net/sourceforge/plantuml/cucadiagram/CodeImpl.java b/src/net/sourceforge/plantuml/cucadiagram/CodeImpl.java index 45c220baf..639130f76 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/CodeImpl.java +++ b/src/net/sourceforge/plantuml/cucadiagram/CodeImpl.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.cucadiagram; import java.util.Objects; import net.sourceforge.plantuml.StringUtils; -import net.sourceforge.plantuml.baraye.a.EntityFactory; +import net.sourceforge.plantuml.baraye.EntityFactory; public class CodeImpl implements Code { diff --git a/src/net/sourceforge/plantuml/cucadiagram/EntityGender.java b/src/net/sourceforge/plantuml/cucadiagram/EntityGender.java index a46b85c9c..703036619 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/EntityGender.java +++ b/src/net/sourceforge/plantuml/cucadiagram/EntityGender.java @@ -35,7 +35,7 @@ */ package net.sourceforge.plantuml.cucadiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; public interface EntityGender { public boolean contains(IEntity test); diff --git a/src/net/sourceforge/plantuml/cucadiagram/EntityGenderUtils.java b/src/net/sourceforge/plantuml/cucadiagram/EntityGenderUtils.java index 2132cf472..85eb73bb5 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/EntityGenderUtils.java +++ b/src/net/sourceforge/plantuml/cucadiagram/EntityGenderUtils.java @@ -36,8 +36,9 @@ package net.sourceforge.plantuml.cucadiagram; import net.sourceforge.plantuml.Guillemet; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.EntityUtils; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; public class EntityGenderUtils { diff --git a/src/net/sourceforge/plantuml/cucadiagram/GroupHierarchy.java b/src/net/sourceforge/plantuml/cucadiagram/GroupHierarchy.java index fce403f80..20e10681e 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/GroupHierarchy.java +++ b/src/net/sourceforge/plantuml/cucadiagram/GroupHierarchy.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.cucadiagram; import java.util.Collection; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IGroup; public interface GroupHierarchy { diff --git a/src/net/sourceforge/plantuml/cucadiagram/GroupPrinter.java b/src/net/sourceforge/plantuml/cucadiagram/GroupPrinter.java index ec376ce62..4824cdff9 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/GroupPrinter.java +++ b/src/net/sourceforge/plantuml/cucadiagram/GroupPrinter.java @@ -38,8 +38,8 @@ package net.sourceforge.plantuml.cucadiagram; import java.io.IOException; import java.io.PrintWriter; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.log.Logme; import net.sourceforge.plantuml.security.SFile; diff --git a/src/net/sourceforge/plantuml/cucadiagram/GroupRoot.java b/src/net/sourceforge/plantuml/cucadiagram/GroupRoot.java index 687e2628a..40403e3a5 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/GroupRoot.java +++ b/src/net/sourceforge/plantuml/cucadiagram/GroupRoot.java @@ -45,9 +45,9 @@ import java.util.Set; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.Url; -import net.sourceforge.plantuml.baraye.a.EntityFactory; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityFactory; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.command.Position; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.USymbol; diff --git a/src/net/sourceforge/plantuml/cucadiagram/HideOrShow2.java b/src/net/sourceforge/plantuml/cucadiagram/HideOrShow2.java index 56b466304..2f145698c 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/HideOrShow2.java +++ b/src/net/sourceforge/plantuml/cucadiagram/HideOrShow2.java @@ -35,7 +35,7 @@ */ package net.sourceforge.plantuml.cucadiagram; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; public class HideOrShow2 { diff --git a/src/net/sourceforge/plantuml/cucadiagram/ICucaDiagram.java b/src/net/sourceforge/plantuml/cucadiagram/ICucaDiagram.java index 969de1bf4..d87dac1f9 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/ICucaDiagram.java +++ b/src/net/sourceforge/plantuml/cucadiagram/ICucaDiagram.java @@ -43,9 +43,9 @@ import net.sourceforge.plantuml.FileFormatOption; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.Pragma; import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.baraye.a.EntityFactory; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityFactory; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.core.UmlSource; import net.sourceforge.plantuml.style.StyleBuilder; import net.sourceforge.plantuml.ugraphic.ImageBuilder; diff --git a/src/net/sourceforge/plantuml/cucadiagram/Ident.java b/src/net/sourceforge/plantuml/cucadiagram/Ident.java index dea085f92..aabd009dd 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/Ident.java +++ b/src/net/sourceforge/plantuml/cucadiagram/Ident.java @@ -40,14 +40,14 @@ import java.util.Collections; import java.util.List; import net.sourceforge.plantuml.StringUtils; -import net.sourceforge.plantuml.baraye.a.CucaDiagram; -import net.sourceforge.plantuml.baraye.a.EntityFactory; +import net.sourceforge.plantuml.baraye.CucaDiagram; +import net.sourceforge.plantuml.baraye.EntityFactory; public class Ident implements Code { - private final List parts; + final protected List parts; - private Ident(List parts) { + public /*private*/ Ident(List parts) { this.parts = parts; } diff --git a/src/net/sourceforge/plantuml/cucadiagram/Link.java b/src/net/sourceforge/plantuml/cucadiagram/Link.java index 380ca440d..2d3b7fd42 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/Link.java +++ b/src/net/sourceforge/plantuml/cucadiagram/Link.java @@ -46,10 +46,10 @@ import net.sourceforge.plantuml.SpecificBackcolorable; import net.sourceforge.plantuml.UmlDiagramType; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.EntityImp; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityImp; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.entity.IEntityFactory; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.HorizontalAlignment; diff --git a/src/net/sourceforge/plantuml/cucadiagram/Magma.java b/src/net/sourceforge/plantuml/cucadiagram/Magma.java index 0c61366ad..851b348eb 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/Magma.java +++ b/src/net/sourceforge/plantuml/cucadiagram/Magma.java @@ -37,9 +37,9 @@ package net.sourceforge.plantuml.cucadiagram; import java.util.List; -import net.sourceforge.plantuml.baraye.a.CucaDiagram; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.CucaDiagram; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; public class Magma { diff --git a/src/net/sourceforge/plantuml/cucadiagram/MagmaList.java b/src/net/sourceforge/plantuml/cucadiagram/MagmaList.java index 36eaee6a0..b5a620e09 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/MagmaList.java +++ b/src/net/sourceforge/plantuml/cucadiagram/MagmaList.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.cucadiagram; import java.util.ArrayList; import java.util.List; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IGroup; public class MagmaList { diff --git a/src/net/sourceforge/plantuml/cucadiagram/MethodsOrFieldsArea.java b/src/net/sourceforge/plantuml/cucadiagram/MethodsOrFieldsArea.java index 789efb004..3391b4e50 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/MethodsOrFieldsArea.java +++ b/src/net/sourceforge/plantuml/cucadiagram/MethodsOrFieldsArea.java @@ -49,7 +49,7 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XRectangle2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.creole.CreoleMode; import net.sourceforge.plantuml.graphic.AbstractTextBlock; import net.sourceforge.plantuml.graphic.FontConfiguration; diff --git a/src/net/sourceforge/plantuml/cucadiagram/PortionShower.java b/src/net/sourceforge/plantuml/cucadiagram/PortionShower.java index 6e5a3200f..395d16e16 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/PortionShower.java +++ b/src/net/sourceforge/plantuml/cucadiagram/PortionShower.java @@ -35,7 +35,7 @@ */ package net.sourceforge.plantuml.cucadiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; public interface PortionShower { diff --git a/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramSimplifierActivity.java b/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramSimplifierActivity.java index 5cd5e37cc..bf9420ef6 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramSimplifierActivity.java +++ b/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramSimplifierActivity.java @@ -40,7 +40,7 @@ import java.util.ArrayList; import java.util.Collection; import java.util.List; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.cucadiagram.ICucaDiagram; import net.sourceforge.plantuml.cucadiagram.LeafType; import net.sourceforge.plantuml.graphic.StringBounder; diff --git a/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramSimplifierState.java b/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramSimplifierState.java index 6075fcc22..13476d2b7 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramSimplifierState.java +++ b/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramSimplifierState.java @@ -41,7 +41,7 @@ import java.util.Collection; import java.util.LinkedHashSet; import java.util.List; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.cucadiagram.GroupRoot; import net.sourceforge.plantuml.cucadiagram.GroupType; import net.sourceforge.plantuml.cucadiagram.ICucaDiagram; diff --git a/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramTxtMaker.java b/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramTxtMaker.java index 80def3296..d048ff770 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramTxtMaker.java +++ b/src/net/sourceforge/plantuml/cucadiagram/dot/CucaDiagramTxtMaker.java @@ -50,7 +50,7 @@ import net.sourceforge.plantuml.BackSlash; import net.sourceforge.plantuml.FileFormat; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.EntityPortion; import net.sourceforge.plantuml.cucadiagram.ICucaDiagram; diff --git a/src/net/sourceforge/plantuml/cucadiagram/dot/DotData.java b/src/net/sourceforge/plantuml/cucadiagram/dot/DotData.java index 57f5f0ba4..2bbda7e73 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/dot/DotData.java +++ b/src/net/sourceforge/plantuml/cucadiagram/dot/DotData.java @@ -46,10 +46,10 @@ import java.util.Objects; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.Pragma; import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.baraye.a.EntityFactory; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityFactory; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.EntityPortion; import net.sourceforge.plantuml.cucadiagram.GroupHierarchy; import net.sourceforge.plantuml.cucadiagram.Link; diff --git a/src/net/sourceforge/plantuml/cucadiagram/dot/Neighborhood.java b/src/net/sourceforge/plantuml/cucadiagram/dot/Neighborhood.java index b5f8f76f6..9ee26a699 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/dot/Neighborhood.java +++ b/src/net/sourceforge/plantuml/cucadiagram/dot/Neighborhood.java @@ -43,7 +43,7 @@ import java.util.Set; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; import net.sourceforge.plantuml.awt.geom.XRectangle2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Link; import net.sourceforge.plantuml.svek.Bibliotekon; import net.sourceforge.plantuml.svek.SvekLine; diff --git a/src/net/sourceforge/plantuml/cucadiagram/entity/IEntityFactory.java b/src/net/sourceforge/plantuml/cucadiagram/entity/IEntityFactory.java index 0f5e66ca4..7885a8b2b 100644 --- a/src/net/sourceforge/plantuml/cucadiagram/entity/IEntityFactory.java +++ b/src/net/sourceforge/plantuml/cucadiagram/entity/IEntityFactory.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.cucadiagram.entity; import java.util.Collection; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Stereotype; public interface IEntityFactory { diff --git a/src/net/sourceforge/plantuml/descdiagram/CommandCreateDomain.java b/src/net/sourceforge/plantuml/descdiagram/CommandCreateDomain.java index 4f16188e0..35b266512 100644 --- a/src/net/sourceforge/plantuml/descdiagram/CommandCreateDomain.java +++ b/src/net/sourceforge/plantuml/descdiagram/CommandCreateDomain.java @@ -40,8 +40,8 @@ import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.classdiagram.command.GenericRegexProducer; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; diff --git a/src/net/sourceforge/plantuml/descdiagram/DescriptionDiagram.java b/src/net/sourceforge/plantuml/descdiagram/DescriptionDiagram.java index 4ceb2424c..6b39cceaf 100644 --- a/src/net/sourceforge/plantuml/descdiagram/DescriptionDiagram.java +++ b/src/net/sourceforge/plantuml/descdiagram/DescriptionDiagram.java @@ -40,7 +40,7 @@ import java.util.Objects; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.core.UmlSource; import net.sourceforge.plantuml.cucadiagram.Code; diff --git a/src/net/sourceforge/plantuml/descdiagram/EntityImageDesignedDomain.java b/src/net/sourceforge/plantuml/descdiagram/EntityImageDesignedDomain.java index 5d18b93da..73af15874 100644 --- a/src/net/sourceforge/plantuml/descdiagram/EntityImageDesignedDomain.java +++ b/src/net/sourceforge/plantuml/descdiagram/EntityImageDesignedDomain.java @@ -43,7 +43,7 @@ import net.sourceforge.plantuml.LineParam; import net.sourceforge.plantuml.SkinParamUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.Stereotype; import net.sourceforge.plantuml.graphic.FontConfiguration; diff --git a/src/net/sourceforge/plantuml/descdiagram/EntityImageDomain.java b/src/net/sourceforge/plantuml/descdiagram/EntityImageDomain.java index 844d17135..d261c8f76 100644 --- a/src/net/sourceforge/plantuml/descdiagram/EntityImageDomain.java +++ b/src/net/sourceforge/plantuml/descdiagram/EntityImageDomain.java @@ -43,7 +43,7 @@ import net.sourceforge.plantuml.LineParam; import net.sourceforge.plantuml.SkinParamUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.Stereotype; import net.sourceforge.plantuml.graphic.FontConfiguration; diff --git a/src/net/sourceforge/plantuml/descdiagram/EntityImageMachine.java b/src/net/sourceforge/plantuml/descdiagram/EntityImageMachine.java index f0d8e6f09..1fc8f9f42 100644 --- a/src/net/sourceforge/plantuml/descdiagram/EntityImageMachine.java +++ b/src/net/sourceforge/plantuml/descdiagram/EntityImageMachine.java @@ -43,7 +43,7 @@ import net.sourceforge.plantuml.LineParam; import net.sourceforge.plantuml.SkinParamUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.Stereotype; import net.sourceforge.plantuml.graphic.FontConfiguration; diff --git a/src/net/sourceforge/plantuml/descdiagram/EntityImageRequirement.java b/src/net/sourceforge/plantuml/descdiagram/EntityImageRequirement.java index 54e2f4d05..f938c2b61 100644 --- a/src/net/sourceforge/plantuml/descdiagram/EntityImageRequirement.java +++ b/src/net/sourceforge/plantuml/descdiagram/EntityImageRequirement.java @@ -43,7 +43,7 @@ import net.sourceforge.plantuml.LineParam; import net.sourceforge.plantuml.SkinParamUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.creole.Stencil; import net.sourceforge.plantuml.cucadiagram.BodyFactory; import net.sourceforge.plantuml.cucadiagram.Display; diff --git a/src/net/sourceforge/plantuml/descdiagram/command/CommandArchimate.java b/src/net/sourceforge/plantuml/descdiagram/command/CommandArchimate.java index a0eb4034f..93ccc7e3d 100644 --- a/src/net/sourceforge/plantuml/descdiagram/command/CommandArchimate.java +++ b/src/net/sourceforge/plantuml/descdiagram/command/CommandArchimate.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.descdiagram.command; import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.StringUtils; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/descdiagram/command/CommandArchimateMultilines.java b/src/net/sourceforge/plantuml/descdiagram/command/CommandArchimateMultilines.java index 6b0421d9e..ba04ff52c 100644 --- a/src/net/sourceforge/plantuml/descdiagram/command/CommandArchimateMultilines.java +++ b/src/net/sourceforge/plantuml/descdiagram/command/CommandArchimateMultilines.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.descdiagram.command; import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.UrlBuilder; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.CommandExecutionResult; diff --git a/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementFull.java b/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementFull.java index 98c183a21..8297539a9 100644 --- a/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementFull.java +++ b/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementFull.java @@ -42,8 +42,9 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityUtils; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.classdiagram.command.CommandCreateClassMultilines; import net.sourceforge.plantuml.command.CommandExecutionResult; @@ -56,7 +57,6 @@ import net.sourceforge.plantuml.command.regex.RegexOr; import net.sourceforge.plantuml.command.regex.RegexResult; import net.sourceforge.plantuml.cucadiagram.Code; import net.sourceforge.plantuml.cucadiagram.Display; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; import net.sourceforge.plantuml.cucadiagram.Ident; import net.sourceforge.plantuml.cucadiagram.LeafType; import net.sourceforge.plantuml.cucadiagram.Stereotag; diff --git a/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementMultilines.java b/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementMultilines.java index 93faa9a7d..1c806a8db 100644 --- a/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementMultilines.java +++ b/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementMultilines.java @@ -42,7 +42,7 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.CommandExecutionResult; diff --git a/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementParenthesis.java b/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementParenthesis.java index a788090f9..af5a631ac 100644 --- a/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementParenthesis.java +++ b/src/net/sourceforge/plantuml/descdiagram/command/CommandCreateElementParenthesis.java @@ -41,8 +41,8 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.command.CommandExecutionResult; diff --git a/src/net/sourceforge/plantuml/descdiagram/command/CommandLinkElement.java b/src/net/sourceforge/plantuml/descdiagram/command/CommandLinkElement.java index 63846d1a2..1f17ef39e 100644 --- a/src/net/sourceforge/plantuml/descdiagram/command/CommandLinkElement.java +++ b/src/net/sourceforge/plantuml/descdiagram/command/CommandLinkElement.java @@ -38,8 +38,8 @@ package net.sourceforge.plantuml.descdiagram.command; import net.sourceforge.plantuml.Direction; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.StringUtils; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; @@ -244,10 +244,12 @@ public class CommandLinkElement extends SingleLineCommand2 { throws NoSuchColorException { final String ent1String = arg.get("ENT1", 0); final String ent2String = arg.get("ENT2", 0); - final Ident ident1 = diagram.buildFullyQualified(ent1String); - final Ident ident2 = diagram.buildFullyQualified(ent2String); - Ident ident1pure = Ident.empty().add(ent1String, diagram.getNamespaceSeparator()); - Ident ident2pure = Ident.empty().add(ent2String, diagram.getNamespaceSeparator()); + final String ent1 = StringUtils.eventuallyRemoveStartingAndEndingDoubleQuote(ent1String); + final String ent2 = StringUtils.eventuallyRemoveStartingAndEndingDoubleQuote(ent2String); + final Ident ident1 = diagram.buildLeafIdentSpecial(ent1); + final Ident ident2 = diagram.buildLeafIdentSpecial(ent2); + Ident ident1pure = Ident.empty().add(ent1, diagram.getNamespaceSeparator()); + Ident ident2pure = Ident.empty().add(ent2, diagram.getNamespaceSeparator()); final Code code1 = diagram.V1972() ? ident1 : diagram.buildCode(ent1String); final Code code2 = diagram.V1972() ? ident2 : diagram.buildCode(ent2String); @@ -309,13 +311,13 @@ public class CommandLinkElement extends SingleLineCommand2 { final Ident ident3 = diagram.buildFullyQualified(tmp3); final Code code3 = diagram.V1972() ? ident3 : diagram.buildCode(tmp3); if (codeChar == '(') { - return getOrCreateLeaf1972(diagram, ident3, code3, LeafType.USECASE, USymbols.USECASE, pure); + return getOrCreateLeaf1972(diagram, ident, code3, LeafType.USECASE, USymbols.USECASE, pure); } else if (codeChar == ':') { - return getOrCreateLeaf1972(diagram, ident3, code3, LeafType.DESCRIPTION, + return getOrCreateLeaf1972(diagram, ident, code3, LeafType.DESCRIPTION, diagram.getSkinParam().actorStyle().toUSymbol(), pure); } else if (codeChar == '[') { final USymbol sym = diagram.getSkinParam().componentStyle().toUSymbol(); - return getOrCreateLeaf1972(diagram, ident3, code3, LeafType.DESCRIPTION, sym, pure); + return getOrCreateLeaf1972(diagram, ident, code3, LeafType.DESCRIPTION, sym, pure); } return getOrCreateLeaf1972(diagram, ident, code, null, null, pure); diff --git a/src/net/sourceforge/plantuml/descdiagram/command/CommandPackageWithUSymbol.java b/src/net/sourceforge/plantuml/descdiagram/command/CommandPackageWithUSymbol.java index e7e7550f0..dd65eca55 100644 --- a/src/net/sourceforge/plantuml/descdiagram/command/CommandPackageWithUSymbol.java +++ b/src/net/sourceforge/plantuml/descdiagram/command/CommandPackageWithUSymbol.java @@ -40,8 +40,8 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.classdiagram.command.CommandCreateClassMultilines; import net.sourceforge.plantuml.command.CommandExecutionResult; diff --git a/src/net/sourceforge/plantuml/elk/CucaDiagramFileMakerElk.java b/src/net/sourceforge/plantuml/elk/CucaDiagramFileMakerElk.java index b1b108d56..7339e07c8 100644 --- a/src/net/sourceforge/plantuml/elk/CucaDiagramFileMakerElk.java +++ b/src/net/sourceforge/plantuml/elk/CucaDiagramFileMakerElk.java @@ -55,10 +55,10 @@ import net.sourceforge.plantuml.UmlDiagramType; import net.sourceforge.plantuml.api.ImageDataSimple; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.EntityFactory; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityFactory; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.core.ImageData; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.GroupType; diff --git a/src/net/sourceforge/plantuml/graphml/GraphmlDescriptionDiagram.java b/src/net/sourceforge/plantuml/graphml/GraphmlDescriptionDiagram.java index 211fa8685..b97924a0d 100644 --- a/src/net/sourceforge/plantuml/graphml/GraphmlDescriptionDiagram.java +++ b/src/net/sourceforge/plantuml/graphml/GraphmlDescriptionDiagram.java @@ -52,7 +52,7 @@ import javax.xml.transform.stream.StreamResult; import org.w3c.dom.Document; import org.w3c.dom.Element; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.cucadiagram.GroupRoot; import net.sourceforge.plantuml.descdiagram.DescriptionDiagram; import net.sourceforge.plantuml.xmi.XmlDiagramTransformer; diff --git a/src/net/sourceforge/plantuml/html/CucaDiagramHtmlMaker.java b/src/net/sourceforge/plantuml/html/CucaDiagramHtmlMaker.java index cc3824c35..3bb4f26f5 100644 --- a/src/net/sourceforge/plantuml/html/CucaDiagramHtmlMaker.java +++ b/src/net/sourceforge/plantuml/html/CucaDiagramHtmlMaker.java @@ -45,8 +45,8 @@ import java.util.List; import net.sourceforge.plantuml.FileImageData; import net.sourceforge.plantuml.StringUtils; -import net.sourceforge.plantuml.baraye.a.CucaDiagram; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.CucaDiagram; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.cucadiagram.LeafType; import net.sourceforge.plantuml.cucadiagram.Link; import net.sourceforge.plantuml.cucadiagram.Stereotype; diff --git a/src/net/sourceforge/plantuml/html/LinkHtmlPrinter.java b/src/net/sourceforge/plantuml/html/LinkHtmlPrinter.java index fd4fea19d..7028fadd3 100644 --- a/src/net/sourceforge/plantuml/html/LinkHtmlPrinter.java +++ b/src/net/sourceforge/plantuml/html/LinkHtmlPrinter.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.html; import java.io.PrintWriter; import net.sourceforge.plantuml.StringUtils; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.cucadiagram.LeafType; import net.sourceforge.plantuml.cucadiagram.Link; import net.sourceforge.plantuml.cucadiagram.LinkDecor; diff --git a/src/net/sourceforge/plantuml/mda/MDADiagramImpl.java b/src/net/sourceforge/plantuml/mda/MDADiagramImpl.java index e8a3aa370..d3737924b 100644 --- a/src/net/sourceforge/plantuml/mda/MDADiagramImpl.java +++ b/src/net/sourceforge/plantuml/mda/MDADiagramImpl.java @@ -44,8 +44,8 @@ import net.sourceforge.plantuml.BlockUml; import net.sourceforge.plantuml.SourceStringReader; import net.sourceforge.plantuml.api.mda.option2.MDADiagram; import net.sourceforge.plantuml.api.mda.option2.MDAPackage; -import net.sourceforge.plantuml.baraye.a.EntityFactory; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.EntityFactory; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.core.Diagram; diff --git a/src/net/sourceforge/plantuml/mda/MDAEntityImpl.java b/src/net/sourceforge/plantuml/mda/MDAEntityImpl.java index 54704026d..3f1dc7778 100644 --- a/src/net/sourceforge/plantuml/mda/MDAEntityImpl.java +++ b/src/net/sourceforge/plantuml/mda/MDAEntityImpl.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.mda; import net.sourceforge.plantuml.api.mda.option2.MDAEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; public class MDAEntityImpl implements MDAEntity { diff --git a/src/net/sourceforge/plantuml/mda/MDAPackageImpl.java b/src/net/sourceforge/plantuml/mda/MDAPackageImpl.java index 5cb6ebdcf..78667ebf1 100644 --- a/src/net/sourceforge/plantuml/mda/MDAPackageImpl.java +++ b/src/net/sourceforge/plantuml/mda/MDAPackageImpl.java @@ -41,8 +41,8 @@ import java.util.Collections; import net.sourceforge.plantuml.api.mda.option2.MDAEntity; import net.sourceforge.plantuml.api.mda.option2.MDAPackage; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.GroupRoot; public class MDAPackageImpl implements MDAPackage { diff --git a/src/net/sourceforge/plantuml/objectdiagram/AbstractClassOrObjectDiagram.java b/src/net/sourceforge/plantuml/objectdiagram/AbstractClassOrObjectDiagram.java index ea901ad31..e8abb6143 100644 --- a/src/net/sourceforge/plantuml/objectdiagram/AbstractClassOrObjectDiagram.java +++ b/src/net/sourceforge/plantuml/objectdiagram/AbstractClassOrObjectDiagram.java @@ -40,8 +40,8 @@ import java.util.List; import java.util.Map; import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.core.UmlSource; diff --git a/src/net/sourceforge/plantuml/objectdiagram/command/CommandAddData.java b/src/net/sourceforge/plantuml/objectdiagram/command/CommandAddData.java index e00b19582..0edf1ea7b 100644 --- a/src/net/sourceforge/plantuml/objectdiagram/command/CommandAddData.java +++ b/src/net/sourceforge/plantuml/objectdiagram/command/CommandAddData.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.objectdiagram.command; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateEntityObject.java b/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateEntityObject.java index 2c2c58573..c6c59d40f 100644 --- a/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateEntityObject.java +++ b/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateEntityObject.java @@ -40,7 +40,7 @@ import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateEntityObjectMultilines.java b/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateEntityObjectMultilines.java index 5c11b186d..0ef5c0b7f 100644 --- a/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateEntityObjectMultilines.java +++ b/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateEntityObjectMultilines.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.objectdiagram.command; import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.StringLocated; import net.sourceforge.plantuml.UrlBuilder; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.CommandMultilines2; diff --git a/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateJson.java b/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateJson.java index 9141bb509..33b966209 100644 --- a/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateJson.java +++ b/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateJson.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.objectdiagram.command; import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.StringLocated; import net.sourceforge.plantuml.UrlBuilder; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.CommandControl; import net.sourceforge.plantuml.command.CommandExecutionResult; diff --git a/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateJsonSingleLine.java b/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateJsonSingleLine.java index f1bfa556d..593a61819 100644 --- a/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateJsonSingleLine.java +++ b/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateJsonSingleLine.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.objectdiagram.command; import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.UrlBuilder; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateMap.java b/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateMap.java index 95be84c3d..639e8bf43 100644 --- a/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateMap.java +++ b/src/net/sourceforge/plantuml/objectdiagram/command/CommandCreateMap.java @@ -38,8 +38,8 @@ package net.sourceforge.plantuml.objectdiagram.command; import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.StringLocated; import net.sourceforge.plantuml.UrlBuilder; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.command.BlocLines; import net.sourceforge.plantuml.command.CommandExecutionResult; diff --git a/src/net/sourceforge/plantuml/sdot/CucaDiagramFileMakerSmetana.java b/src/net/sourceforge/plantuml/sdot/CucaDiagramFileMakerSmetana.java index cee5cfe20..6efb21052 100644 --- a/src/net/sourceforge/plantuml/sdot/CucaDiagramFileMakerSmetana.java +++ b/src/net/sourceforge/plantuml/sdot/CucaDiagramFileMakerSmetana.java @@ -69,11 +69,11 @@ import net.sourceforge.plantuml.UmlDiagram; import net.sourceforge.plantuml.api.ImageDataSimple; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.EntityFactory; -import net.sourceforge.plantuml.baraye.a.EntityImp; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityFactory; +import net.sourceforge.plantuml.baraye.EntityImp; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.core.ImageData; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.GroupType; diff --git a/src/net/sourceforge/plantuml/statediagram/StateDiagram.java b/src/net/sourceforge/plantuml/statediagram/StateDiagram.java index c83ecba97..d370d6942 100644 --- a/src/net/sourceforge/plantuml/statediagram/StateDiagram.java +++ b/src/net/sourceforge/plantuml/statediagram/StateDiagram.java @@ -39,14 +39,14 @@ import java.util.Map; import java.util.Objects; import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityUtils; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.classdiagram.AbstractEntityDiagram; import net.sourceforge.plantuml.core.UmlSource; import net.sourceforge.plantuml.cucadiagram.Code; import net.sourceforge.plantuml.cucadiagram.Display; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; import net.sourceforge.plantuml.cucadiagram.GroupType; import net.sourceforge.plantuml.cucadiagram.Ident; import net.sourceforge.plantuml.cucadiagram.LeafType; diff --git a/src/net/sourceforge/plantuml/statediagram/command/CommandAddField.java b/src/net/sourceforge/plantuml/statediagram/command/CommandAddField.java index fc0fc37f8..25b335c02 100644 --- a/src/net/sourceforge/plantuml/statediagram/command/CommandAddField.java +++ b/src/net/sourceforge/plantuml/statediagram/command/CommandAddField.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.statediagram.command; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/statediagram/command/CommandCreatePackage2.java b/src/net/sourceforge/plantuml/statediagram/command/CommandCreatePackage2.java index db05db7ca..165f579d6 100644 --- a/src/net/sourceforge/plantuml/statediagram/command/CommandCreatePackage2.java +++ b/src/net/sourceforge/plantuml/statediagram/command/CommandCreatePackage2.java @@ -39,8 +39,8 @@ import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/statediagram/command/CommandCreatePackageState.java b/src/net/sourceforge/plantuml/statediagram/command/CommandCreatePackageState.java index 206e7f5e1..cd6d9294d 100644 --- a/src/net/sourceforge/plantuml/statediagram/command/CommandCreatePackageState.java +++ b/src/net/sourceforge/plantuml/statediagram/command/CommandCreatePackageState.java @@ -39,8 +39,8 @@ import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.classdiagram.command.CommandCreateClassMultilines; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; diff --git a/src/net/sourceforge/plantuml/statediagram/command/CommandCreateState.java b/src/net/sourceforge/plantuml/statediagram/command/CommandCreateState.java index 3fa302263..1d5f8576f 100644 --- a/src/net/sourceforge/plantuml/statediagram/command/CommandCreateState.java +++ b/src/net/sourceforge/plantuml/statediagram/command/CommandCreateState.java @@ -39,7 +39,7 @@ import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.UrlBuilder; import net.sourceforge.plantuml.UrlMode; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.command.CommandCreateClassMultilines; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; diff --git a/src/net/sourceforge/plantuml/statediagram/command/CommandEndState.java b/src/net/sourceforge/plantuml/statediagram/command/CommandEndState.java index 6a7d4bf29..296fc144c 100644 --- a/src/net/sourceforge/plantuml/statediagram/command/CommandEndState.java +++ b/src/net/sourceforge/plantuml/statediagram/command/CommandEndState.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.statediagram.command; import net.sourceforge.plantuml.LineLocation; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/statediagram/command/CommandLinkStateCommon.java b/src/net/sourceforge/plantuml/statediagram/command/CommandLinkStateCommon.java index ed6268e15..6e8748305 100644 --- a/src/net/sourceforge/plantuml/statediagram/command/CommandLinkStateCommon.java +++ b/src/net/sourceforge/plantuml/statediagram/command/CommandLinkStateCommon.java @@ -40,7 +40,7 @@ import net.sourceforge.plantuml.Direction; import net.sourceforge.plantuml.LineLocation; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.UmlDiagramType; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.command.CommandExecutionResult; import net.sourceforge.plantuml.command.SingleLineCommand2; import net.sourceforge.plantuml.command.regex.IRegex; diff --git a/src/net/sourceforge/plantuml/svek/AbstractEntityImage.java b/src/net/sourceforge/plantuml/svek/AbstractEntityImage.java index d98d33ee8..380c5a097 100644 --- a/src/net/sourceforge/plantuml/svek/AbstractEntityImage.java +++ b/src/net/sourceforge/plantuml/svek/AbstractEntityImage.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.svek; import java.util.Objects; import net.sourceforge.plantuml.ISkinParam; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.cucadiagram.Stereotype; import net.sourceforge.plantuml.graphic.AbstractTextBlock; import net.sourceforge.plantuml.graphic.StringBounder; diff --git a/src/net/sourceforge/plantuml/svek/Bibliotekon.java b/src/net/sourceforge/plantuml/svek/Bibliotekon.java index 62a846403..4fa74adbd 100644 --- a/src/net/sourceforge/plantuml/svek/Bibliotekon.java +++ b/src/net/sourceforge/plantuml/svek/Bibliotekon.java @@ -43,9 +43,9 @@ import java.util.LinkedHashMap; import java.util.List; import java.util.Map; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Link; import net.sourceforge.plantuml.graphic.StringBounder; @@ -53,7 +53,7 @@ public class Bibliotekon { private final List allCluster = new ArrayList<>(); - private final Map nodeMap = new LinkedHashMap();; + private final Map nodeMap = new LinkedHashMap(); private final List lines0 = new ArrayList<>(); private final List lines1 = new ArrayList<>(); diff --git a/src/net/sourceforge/plantuml/svek/Cluster.java b/src/net/sourceforge/plantuml/svek/Cluster.java index 44092e501..d76079ce6 100644 --- a/src/net/sourceforge/plantuml/svek/Cluster.java +++ b/src/net/sourceforge/plantuml/svek/Cluster.java @@ -54,13 +54,13 @@ import net.sourceforge.plantuml.UmlDiagramType; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.EntityImp; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.EntityImp; +import net.sourceforge.plantuml.baraye.EntityUtils; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.command.Position; import net.sourceforge.plantuml.cucadiagram.CucaNote; import net.sourceforge.plantuml.cucadiagram.EntityPosition; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; import net.sourceforge.plantuml.cucadiagram.ICucaDiagram; import net.sourceforge.plantuml.cucadiagram.Stereotype; import net.sourceforge.plantuml.cucadiagram.dot.GraphvizVersion; diff --git a/src/net/sourceforge/plantuml/svek/ClusterHeader.java b/src/net/sourceforge/plantuml/svek/ClusterHeader.java index a79bdd3b2..9a93cbcef 100644 --- a/src/net/sourceforge/plantuml/svek/ClusterHeader.java +++ b/src/net/sourceforge/plantuml/svek/ClusterHeader.java @@ -42,7 +42,7 @@ import java.util.List; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.activitydiagram3.ftile.EntityImageLegend; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.EntityImp; +import net.sourceforge.plantuml.baraye.EntityImp; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.DisplayPositioned; import net.sourceforge.plantuml.cucadiagram.EntityPortion; diff --git a/src/net/sourceforge/plantuml/svek/DotStringFactory.java b/src/net/sourceforge/plantuml/svek/DotStringFactory.java index 665a2fcfb..26cf652dd 100644 --- a/src/net/sourceforge/plantuml/svek/DotStringFactory.java +++ b/src/net/sourceforge/plantuml/svek/DotStringFactory.java @@ -50,8 +50,8 @@ import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.UmlDiagramType; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.EntityFactory; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.EntityFactory; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.command.Position; import net.sourceforge.plantuml.cucadiagram.ICucaDiagram; import net.sourceforge.plantuml.cucadiagram.Rankdir; diff --git a/src/net/sourceforge/plantuml/svek/GeneralImageBuilder.java b/src/net/sourceforge/plantuml/svek/GeneralImageBuilder.java index ce8ae9e67..0a88f4c75 100644 --- a/src/net/sourceforge/plantuml/svek/GeneralImageBuilder.java +++ b/src/net/sourceforge/plantuml/svek/GeneralImageBuilder.java @@ -58,11 +58,11 @@ import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.UmlDiagramType; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XRectangle2D; -import net.sourceforge.plantuml.baraye.a.EntityFactory; -import net.sourceforge.plantuml.baraye.a.EntityImp; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityFactory; +import net.sourceforge.plantuml.baraye.EntityImp; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.core.UmlSource; import net.sourceforge.plantuml.cucadiagram.EntityPosition; import net.sourceforge.plantuml.cucadiagram.GroupRoot; diff --git a/src/net/sourceforge/plantuml/svek/GroupPngMakerActivity.java b/src/net/sourceforge/plantuml/svek/GroupPngMakerActivity.java index 9211e9bd6..400ce0225 100644 --- a/src/net/sourceforge/plantuml/svek/GroupPngMakerActivity.java +++ b/src/net/sourceforge/plantuml/svek/GroupPngMakerActivity.java @@ -42,9 +42,9 @@ import java.util.List; import net.sourceforge.plantuml.ColorParam; import net.sourceforge.plantuml.ISkinParam; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; +import net.sourceforge.plantuml.baraye.EntityUtils; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.cucadiagram.GroupHierarchy; import net.sourceforge.plantuml.cucadiagram.GroupType; import net.sourceforge.plantuml.cucadiagram.ICucaDiagram; diff --git a/src/net/sourceforge/plantuml/svek/GroupPngMakerState.java b/src/net/sourceforge/plantuml/svek/GroupPngMakerState.java index e0e0cc232..f58fc5859 100644 --- a/src/net/sourceforge/plantuml/svek/GroupPngMakerState.java +++ b/src/net/sourceforge/plantuml/svek/GroupPngMakerState.java @@ -40,11 +40,11 @@ import java.util.Collection; import java.util.List; import net.sourceforge.plantuml.ISkinParam; -import net.sourceforge.plantuml.baraye.a.EntityImp; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityImp; +import net.sourceforge.plantuml.baraye.EntityUtils; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Display; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; import net.sourceforge.plantuml.cucadiagram.GroupHierarchy; import net.sourceforge.plantuml.cucadiagram.GroupType; import net.sourceforge.plantuml.cucadiagram.ICucaDiagram; diff --git a/src/net/sourceforge/plantuml/svek/Kal.java b/src/net/sourceforge/plantuml/svek/Kal.java index ea9ae4178..74cd317fc 100644 --- a/src/net/sourceforge/plantuml/svek/Kal.java +++ b/src/net/sourceforge/plantuml/svek/Kal.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.svek; import net.sourceforge.plantuml.Direction; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.EntityImp; +import net.sourceforge.plantuml.baraye.EntityImp; import net.sourceforge.plantuml.creole.CreoleMode; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.Link; diff --git a/src/net/sourceforge/plantuml/svek/SvekLine.java b/src/net/sourceforge/plantuml/svek/SvekLine.java index 95e721dfb..4a66b8621 100644 --- a/src/net/sourceforge/plantuml/svek/SvekLine.java +++ b/src/net/sourceforge/plantuml/svek/SvekLine.java @@ -56,9 +56,9 @@ import net.sourceforge.plantuml.UmlDiagramType; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.EntityImp; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.EntityImp; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.command.Position; import net.sourceforge.plantuml.creole.CreoleMode; import net.sourceforge.plantuml.cucadiagram.CucaNote; diff --git a/src/net/sourceforge/plantuml/svek/SvekNode.java b/src/net/sourceforge/plantuml/svek/SvekNode.java index 366572dfe..62be366c8 100644 --- a/src/net/sourceforge/plantuml/svek/SvekNode.java +++ b/src/net/sourceforge/plantuml/svek/SvekNode.java @@ -42,9 +42,9 @@ import net.sourceforge.plantuml.Hideable; import net.sourceforge.plantuml.StringUtils; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.EntityImp; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityImp; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.EntityPosition; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.posimo.Positionable; diff --git a/src/net/sourceforge/plantuml/svek/image/AbstractEntityImageBorder.java b/src/net/sourceforge/plantuml/svek/image/AbstractEntityImageBorder.java index 28f8cc620..0a4415634 100644 --- a/src/net/sourceforge/plantuml/svek/image/AbstractEntityImageBorder.java +++ b/src/net/sourceforge/plantuml/svek/image/AbstractEntityImageBorder.java @@ -39,7 +39,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.EntityPosition; import net.sourceforge.plantuml.cucadiagram.Rankdir; import net.sourceforge.plantuml.cucadiagram.Stereotype; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageActivity.java b/src/net/sourceforge/plantuml/svek/image/EntityImageActivity.java index 40e6ee441..542acac85 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageActivity.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageActivity.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Stereotype; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.HorizontalAlignment; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageArcCircle.java b/src/net/sourceforge/plantuml/svek/image/EntityImageArcCircle.java index c18d361da..6587c8fa2 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageArcCircle.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageArcCircle.java @@ -39,7 +39,7 @@ import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.Guillemet; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.Stereotype; import net.sourceforge.plantuml.graphic.FontConfiguration; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageAssociation.java b/src/net/sourceforge/plantuml/svek/image/EntityImageAssociation.java index b58629217..4ee446ed8 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageAssociation.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageAssociation.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.style.PName; import net.sourceforge.plantuml.style.SName; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageAssociationPoint.java b/src/net/sourceforge/plantuml/svek/image/EntityImageAssociationPoint.java index 151bcc686..963ef6952 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageAssociationPoint.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageAssociationPoint.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.style.PName; import net.sourceforge.plantuml.style.SName; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageBranch.java b/src/net/sourceforge/plantuml/svek/image/EntityImageBranch.java index 5e0933dcc..4eaab92c8 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageBranch.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageBranch.java @@ -40,7 +40,7 @@ import java.util.Map; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.style.PName; import net.sourceforge.plantuml.style.SName; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageCircleEnd.java b/src/net/sourceforge/plantuml/svek/image/EntityImageCircleEnd.java index 1514e4b3d..21cc85fd6 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageCircleEnd.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageCircleEnd.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.graphic.color.ColorType; import net.sourceforge.plantuml.style.PName; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageCircleStart.java b/src/net/sourceforge/plantuml/svek/image/EntityImageCircleStart.java index 972510908..8bbc50549 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageCircleStart.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageCircleStart.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.graphic.color.ColorType; import net.sourceforge.plantuml.style.PName; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageClass.java b/src/net/sourceforge/plantuml/svek/image/EntityImageClass.java index 2c2f46f01..03080ac70 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageClass.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageClass.java @@ -44,8 +44,8 @@ import net.sourceforge.plantuml.LineConfigurable; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XRectangle2D; -import net.sourceforge.plantuml.baraye.a.EntityImp; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityImp; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.creole.Stencil; import net.sourceforge.plantuml.cucadiagram.EntityPortion; import net.sourceforge.plantuml.cucadiagram.LeafType; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageClassHeader.java b/src/net/sourceforge/plantuml/svek/image/EntityImageClassHeader.java index 8ddf0963a..583894bc9 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageClassHeader.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageClassHeader.java @@ -40,7 +40,7 @@ import net.sourceforge.plantuml.Guillemet; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.SkinParamUtils; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.EntityPortion; import net.sourceforge.plantuml.cucadiagram.LeafType; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageDeepHistory.java b/src/net/sourceforge/plantuml/svek/image/EntityImageDeepHistory.java index bcf3f7b11..6b406f693 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageDeepHistory.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageDeepHistory.java @@ -36,7 +36,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.ISkinParam; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.style.SName; public class EntityImageDeepHistory extends EntityImagePseudoState { diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageDescription.java b/src/net/sourceforge/plantuml/svek/image/EntityImageDescription.java index 8074cc998..f697e90f3 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageDescription.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageDescription.java @@ -47,8 +47,8 @@ import net.sourceforge.plantuml.Guillemet; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.BodyFactory; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.EntityPortion; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageEmptyPackage.java b/src/net/sourceforge/plantuml/svek/image/EntityImageEmptyPackage.java index df6b77e06..b4fd5cb2e 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageEmptyPackage.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageEmptyPackage.java @@ -42,8 +42,8 @@ import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.activitydiagram3.ftile.EntityImageLegend; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.EntityImp; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityImp; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.DisplayPositioned; import net.sourceforge.plantuml.cucadiagram.EntityPortion; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageGroup.java b/src/net/sourceforge/plantuml/svek/image/EntityImageGroup.java index 61b548883..8d9bcb438 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageGroup.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageGroup.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.svek.AbstractEntityImage; import net.sourceforge.plantuml.svek.ShapeType; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageJson.java b/src/net/sourceforge/plantuml/svek/image/EntityImageJson.java index 96c80d948..34067081f 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageJson.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageJson.java @@ -42,7 +42,7 @@ import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.LineConfigurable; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.creole.Stencil; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.EntityPortion; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterface.java b/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterface.java index 21a98698b..9402ff6a1 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterface.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterface.java @@ -41,7 +41,7 @@ import java.util.Map; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.LeafType; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.HorizontalAlignment; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterfaceEye1.java b/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterfaceEye1.java index e34b30e19..c0fce51ec 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterfaceEye1.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterfaceEye1.java @@ -44,7 +44,7 @@ import net.sourceforge.plantuml.SkinParamUtils; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Stereotype; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.HorizontalAlignment; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterfaceEye2.java b/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterfaceEye2.java index c2b453bd8..14cfd6900 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterfaceEye2.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageLollipopInterfaceEye2.java @@ -40,7 +40,7 @@ import net.sourceforge.plantuml.Guillemet; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.BodyFactory; import net.sourceforge.plantuml.cucadiagram.EntityPortion; import net.sourceforge.plantuml.cucadiagram.PortionShower; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageMap.java b/src/net/sourceforge/plantuml/svek/image/EntityImageMap.java index 05cd46a55..6b64bff83 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageMap.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageMap.java @@ -45,7 +45,7 @@ import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.LineConfigurable; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.creole.Stencil; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.EntityPortion; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageNote.java b/src/net/sourceforge/plantuml/svek/image/EntityImageNote.java index 172f66e7f..fd2aa4943 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageNote.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageNote.java @@ -49,8 +49,8 @@ import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XLine2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.creole.Stencil; import net.sourceforge.plantuml.cucadiagram.BodyFactory; import net.sourceforge.plantuml.cucadiagram.Display; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageObject.java b/src/net/sourceforge/plantuml/svek/image/EntityImageObject.java index cfae9727c..8eb19b856 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageObject.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageObject.java @@ -46,7 +46,7 @@ import net.sourceforge.plantuml.LineConfigurable; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XRectangle2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.creole.Stencil; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.EntityPortion; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImagePort.java b/src/net/sourceforge/plantuml/svek/image/EntityImagePort.java index d6f82ad96..4fef3fb49 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImagePort.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImagePort.java @@ -40,7 +40,7 @@ import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.EntityPosition; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.graphic.color.ColorType; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImagePseudoState.java b/src/net/sourceforge/plantuml/svek/image/EntityImagePseudoState.java index a532ba900..d034a2069 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImagePseudoState.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImagePseudoState.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.Stereotype; import net.sourceforge.plantuml.graphic.FontConfiguration; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageState.java b/src/net/sourceforge/plantuml/svek/image/EntityImageState.java index ad1de2181..80ddac1b8 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageState.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageState.java @@ -39,7 +39,7 @@ import java.util.Collections; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.creole.CreoleMode; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.Stereotype; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageState2.java b/src/net/sourceforge/plantuml/svek/image/EntityImageState2.java index 431321a2f..6c64bf740 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageState2.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageState2.java @@ -38,7 +38,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.BodyFactory; import net.sourceforge.plantuml.cucadiagram.Stereotype; import net.sourceforge.plantuml.graphic.HorizontalAlignment; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageStateBorder.java b/src/net/sourceforge/plantuml/svek/image/EntityImageStateBorder.java index dc2ea1c05..4b6aad551 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageStateBorder.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageStateBorder.java @@ -39,7 +39,7 @@ import net.sourceforge.plantuml.FontParam; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.EntityPosition; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.graphic.color.ColorType; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageStateCommon.java b/src/net/sourceforge/plantuml/svek/image/EntityImageStateCommon.java index b129c3b3b..71b42ef5e 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageStateCommon.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageStateCommon.java @@ -39,8 +39,8 @@ import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.LineConfigurable; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.b.EntityImp; +import net.sourceforge.plantuml.baraye.EntityImp; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.creole.CreoleMode; import net.sourceforge.plantuml.graphic.FontConfiguration; import net.sourceforge.plantuml.graphic.HorizontalAlignment; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageStateEmptyDescription.java b/src/net/sourceforge/plantuml/svek/image/EntityImageStateEmptyDescription.java index 036def3ec..1161d2485 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageStateEmptyDescription.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageStateEmptyDescription.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.ugraphic.UGraphic; import net.sourceforge.plantuml.ugraphic.UStroke; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageSynchroBar.java b/src/net/sourceforge/plantuml/svek/image/EntityImageSynchroBar.java index d39c4050c..c4ff58f76 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageSynchroBar.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageSynchroBar.java @@ -37,7 +37,7 @@ package net.sourceforge.plantuml.svek.image; import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.awt.geom.XDimension2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Rankdir; import net.sourceforge.plantuml.graphic.StringBounder; import net.sourceforge.plantuml.style.PName; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageTips.java b/src/net/sourceforge/plantuml/svek/image/EntityImageTips.java index 9a1fcdc37..1f509dd83 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageTips.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageTips.java @@ -43,8 +43,8 @@ import net.sourceforge.plantuml.UmlDiagramType; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; import net.sourceforge.plantuml.awt.geom.XRectangle2D; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.command.Position; import net.sourceforge.plantuml.cucadiagram.BodyFactory; import net.sourceforge.plantuml.cucadiagram.Display; diff --git a/src/net/sourceforge/plantuml/svek/image/EntityImageUseCase.java b/src/net/sourceforge/plantuml/svek/image/EntityImageUseCase.java index 010576367..2fc0e8408 100644 --- a/src/net/sourceforge/plantuml/svek/image/EntityImageUseCase.java +++ b/src/net/sourceforge/plantuml/svek/image/EntityImageUseCase.java @@ -44,7 +44,7 @@ import net.sourceforge.plantuml.ISkinParam; import net.sourceforge.plantuml.Url; import net.sourceforge.plantuml.awt.geom.XDimension2D; import net.sourceforge.plantuml.awt.geom.XPoint2D; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.creole.Stencil; import net.sourceforge.plantuml.cucadiagram.BodyFactory; import net.sourceforge.plantuml.cucadiagram.Display; diff --git a/src/net/sourceforge/plantuml/timingdiagram/graphic/Ribbon.java b/src/net/sourceforge/plantuml/timingdiagram/graphic/Ribbon.java index 52e613758..f382705f2 100644 --- a/src/net/sourceforge/plantuml/timingdiagram/graphic/Ribbon.java +++ b/src/net/sourceforge/plantuml/timingdiagram/graphic/Ribbon.java @@ -52,6 +52,7 @@ import net.sourceforge.plantuml.graphic.TextBlockUtils; import net.sourceforge.plantuml.graphic.UDrawable; import net.sourceforge.plantuml.graphic.color.ColorType; import net.sourceforge.plantuml.graphic.color.Colors; +import net.sourceforge.plantuml.style.PName; import net.sourceforge.plantuml.style.Style; import net.sourceforge.plantuml.timingdiagram.ChangeState; import net.sourceforge.plantuml.timingdiagram.TimeConstraint; @@ -183,13 +184,20 @@ public class Ribbon implements PDrawing { } private void drawPentaA(UGraphic ug, double len, ChangeState change) { - SymbolContext context = change.getContext(skinParam, style); - final HColor back = initialColors.getColor(ColorType.BACK); - if (back != null) - context = context.withBackColor(back); - final HColor line = initialColors.getColor(ColorType.LINE); - if (line != null) - context = context.withForeColor(line); + SymbolContext context; + if (change == null) { + final HColor back = style.value(PName.BackGroundColor).asColor(skinParam.getIHtmlColorSet()); + final HColor line = style.value(PName.LineColor).asColor(skinParam.getIHtmlColorSet()); + context = new SymbolContext(back, line).withStroke(style.getStroke()); + } else { + context = change.getContext(skinParam, style); + final HColor back = initialColors.getColor(ColorType.BACK); + final HColor line = initialColors.getColor(ColorType.LINE); + if (back != null) + context = context.withBackColor(back); + if (line != null) + context = context.withForeColor(line); + } final PentaAShape shape = PentaAShape.create(len, getRibbonHeight(), context); shape.drawU(ug); @@ -250,8 +258,14 @@ public class Ribbon implements PDrawing { } private void drawBeforeZeroState(UGraphic ug) { - if (initialState != null && changes.size() > 0) { - final StringBounder stringBounder = ug.getStringBounder(); + if (initialState == null) + return; + final StringBounder stringBounder = ug.getStringBounder(); + if (changes.size() == 0) { + final double a = 0; + drawPentaA(ug.apply(UTranslate.dx(-getInitialWidth(stringBounder))), getInitialWidth(stringBounder) + a, + null); + } else { final double a = getPosInPixel(changes.get(0)); drawPentaA(ug.apply(UTranslate.dx(-getInitialWidth(stringBounder))), getInitialWidth(stringBounder) + a, changes.get(0)); diff --git a/src/net/sourceforge/plantuml/xmi/XmiClassDiagramAbstract.java b/src/net/sourceforge/plantuml/xmi/XmiClassDiagramAbstract.java index da438c404..36b315b99 100644 --- a/src/net/sourceforge/plantuml/xmi/XmiClassDiagramAbstract.java +++ b/src/net/sourceforge/plantuml/xmi/XmiClassDiagramAbstract.java @@ -54,8 +54,8 @@ import javax.xml.transform.stream.StreamResult; import org.w3c.dom.Document; import org.w3c.dom.Element; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.LeafType; diff --git a/src/net/sourceforge/plantuml/xmi/XmiClassDiagramArgo.java b/src/net/sourceforge/plantuml/xmi/XmiClassDiagramArgo.java index 7e49cb4cd..9bfa6b9a1 100644 --- a/src/net/sourceforge/plantuml/xmi/XmiClassDiagramArgo.java +++ b/src/net/sourceforge/plantuml/xmi/XmiClassDiagramArgo.java @@ -39,7 +39,7 @@ import javax.xml.parsers.ParserConfigurationException; import org.w3c.dom.Element; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.cucadiagram.Link; diff --git a/src/net/sourceforge/plantuml/xmi/XmiClassDiagramStandard.java b/src/net/sourceforge/plantuml/xmi/XmiClassDiagramStandard.java index 7ba308ec0..276865148 100644 --- a/src/net/sourceforge/plantuml/xmi/XmiClassDiagramStandard.java +++ b/src/net/sourceforge/plantuml/xmi/XmiClassDiagramStandard.java @@ -39,7 +39,7 @@ import javax.xml.parsers.ParserConfigurationException; import org.w3c.dom.Element; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.ClassDiagram; public class XmiClassDiagramStandard extends XmiClassDiagramAbstract implements XmlDiagramTransformer { diff --git a/src/net/sourceforge/plantuml/xmi/XmiClassDiagramStar.java b/src/net/sourceforge/plantuml/xmi/XmiClassDiagramStar.java index 2f34decd0..d9e5891f2 100644 --- a/src/net/sourceforge/plantuml/xmi/XmiClassDiagramStar.java +++ b/src/net/sourceforge/plantuml/xmi/XmiClassDiagramStar.java @@ -39,7 +39,7 @@ import javax.xml.parsers.ParserConfigurationException; import org.w3c.dom.Element; -import net.sourceforge.plantuml.baraye.a.IEntity; +import net.sourceforge.plantuml.baraye.IEntity; import net.sourceforge.plantuml.classdiagram.ClassDiagram; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.Link; diff --git a/src/net/sourceforge/plantuml/xmi/XmiDescriptionDiagram.java b/src/net/sourceforge/plantuml/xmi/XmiDescriptionDiagram.java index bcadef6dc..0291f6f09 100644 --- a/src/net/sourceforge/plantuml/xmi/XmiDescriptionDiagram.java +++ b/src/net/sourceforge/plantuml/xmi/XmiDescriptionDiagram.java @@ -52,8 +52,8 @@ import javax.xml.transform.stream.StreamResult; import org.w3c.dom.Document; import org.w3c.dom.Element; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.GroupRoot; import net.sourceforge.plantuml.cucadiagram.Link; diff --git a/src/net/sourceforge/plantuml/xmi/XmiStateDiagram.java b/src/net/sourceforge/plantuml/xmi/XmiStateDiagram.java index 108026476..0b7439033 100644 --- a/src/net/sourceforge/plantuml/xmi/XmiStateDiagram.java +++ b/src/net/sourceforge/plantuml/xmi/XmiStateDiagram.java @@ -52,8 +52,8 @@ import javax.xml.transform.stream.StreamResult; import org.w3c.dom.Document; import org.w3c.dom.Element; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; import net.sourceforge.plantuml.cucadiagram.Display; import net.sourceforge.plantuml.cucadiagram.GroupRoot; import net.sourceforge.plantuml.cucadiagram.Link; diff --git a/src/net/sourceforge/plantuml/xmlsc/ScxmlStateDiagramStandard.java b/src/net/sourceforge/plantuml/xmlsc/ScxmlStateDiagramStandard.java index 4f58cb8f7..829d32322 100644 --- a/src/net/sourceforge/plantuml/xmlsc/ScxmlStateDiagramStandard.java +++ b/src/net/sourceforge/plantuml/xmlsc/ScxmlStateDiagramStandard.java @@ -54,11 +54,11 @@ import org.w3c.dom.Document; import org.w3c.dom.Element; import net.sourceforge.plantuml.Guillemet; -import net.sourceforge.plantuml.baraye.a.IEntity; -import net.sourceforge.plantuml.baraye.a.IGroup; -import net.sourceforge.plantuml.baraye.a.ILeaf; +import net.sourceforge.plantuml.baraye.EntityUtils; +import net.sourceforge.plantuml.baraye.IEntity; +import net.sourceforge.plantuml.baraye.IGroup; +import net.sourceforge.plantuml.baraye.ILeaf; import net.sourceforge.plantuml.cucadiagram.Display; -import net.sourceforge.plantuml.cucadiagram.EntityUtils; import net.sourceforge.plantuml.cucadiagram.LeafType; import net.sourceforge.plantuml.cucadiagram.Link; import net.sourceforge.plantuml.cucadiagram.Stereotype;