net.sourceforge.plantuml.activitydiagram3.ftile.ConnectionCross Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of plantuml-mit Show documentation
Show all versions of plantuml-mit Show documentation
PlantUML is a component that allows to quickly write diagrams from text.
// THIS FILE HAS BEEN GENERATED BY A PREPROCESSOR.
package net.sourceforge.plantuml.activitydiagram3.ftile;
import net.sourceforge.plantuml.klimt.drawing.UGraphic;
public class ConnectionCross extends AbstractConnection {
private final Connection connection;
public ConnectionCross(Connection connection) {
super(connection.getFtile1(), connection.getFtile2());
this.connection = connection;
}
public void drawU(UGraphic ug) {
if (connection instanceof ConnectionTranslatable) {
final ConnectionTranslatable conn = (ConnectionTranslatable) connection;
final Swimlane swimlane1 = getFtile1().getSwimlaneOut();
final Swimlane swimlane2 = getFtile2().getSwimlaneIn();
if (swimlane1 == null) {
return;
// throw new IllegalStateException("" + getFtile1().getClass());
}
if (swimlane2 == null) {
return;
// throw new IllegalStateException("" + getFtile2().getClass());
}
conn.drawTranslate(ug, swimlane1.getTranslate(), swimlane2.getTranslate());
}
}
}