some fixes

This commit is contained in:
Mystikfluu 2023-03-28 20:42:22 +02:00
parent a08dae9ad9
commit 734db05673
57 changed files with 7419 additions and 9556 deletions

3
.gitignore vendored
View File

@ -1 +1,2 @@
out/ out/
mappings/

8
.idea/compiler.xml generated
View File

@ -1,5 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="CompilerConfiguration">
<excludeFromCompile>
<file url="file://$PROJECT_DIR$/.gitignore" />
<file url="file://$PROJECT_DIR$/noEasyDB.iml" />
<file url="file://$PROJECT_DIR$/obfuscate.bat" />
<directory url="file://$PROJECT_DIR$/mappings" includeSubdirectories="true" />
</excludeFromCompile>
</component>
<component name="JavacSettings"> <component name="JavacSettings">
<option name="DEBUGGING_INFO" value="false" /> <option name="DEBUGGING_INFO" value="false" />
<option name="ADDITIONAL_OPTIONS_STRING" value="-Xlint:unchecked" /> <option name="ADDITIONAL_OPTIONS_STRING" value="-Xlint:unchecked" />

View File

@ -1,72 +0,0 @@
<component name="libraryTable">
<library name="soot.oss" type="repository">
<properties maven-id="org.soot-oss:soot:4.3.0" />
<CLASSES>
<root url="jar://$PROJECT_DIR$/lib/soot-4.3.0.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/commons-io-2.7.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/dexlib2-2.5.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/jsr305-3.0.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/guava-27.1-android.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/failureaccess-1.0.1.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/checker-compat-qual-2.5.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/error_prone_annotations-2.2.0.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/j2objc-annotations-1.1.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/animal-sniffer-annotations-1.17.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/asm-9.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/asm-tree-9.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/asm-util-9.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/asm-analysis-9.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/asm-commons-9.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/xmlpull-1.1.3.4d_b4_min.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/axml-2.1.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/polyglot-2006.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/heros-1.2.3.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/functionaljava-4.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/jasmin-3.0.3.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/java_cup-0.9.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/slf4j-api-1.7.32.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.annotation-api-1.3.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/jaxb-api-2.4.0-b180725.0427.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.activation-api-1.2.0.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/jaxb-runtime-2.4.0-b180830.0438.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/txw2-2.4.0-b180830.0438.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/istack-commons-runtime-3.0.7.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/stax-ex-1.8.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/FastInfoset-1.2.15.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$PROJECT_DIR$/lib/soot-4.3.0-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/commons-io-2.7-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/dexlib2-2.5.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/jsr305-3.0.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/guava-27.1-android-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/failureaccess-1.0.1-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/checker-compat-qual-2.5.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/error_prone_annotations-2.2.0-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/j2objc-annotations-1.1-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/animal-sniffer-annotations-1.17-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/asm-9.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/asm-tree-9.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/asm-util-9.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/asm-analysis-9.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/asm-commons-9.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/axml-2.1.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/polyglot-2006-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/heros-1.2.3-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/functionaljava-4.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/jasmin-3.0.3-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/java_cup-0.9.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/slf4j-api-1.7.32-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.annotation-api-1.3.2-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/jaxb-api-2.4.0-b180725.0427-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.activation-api-1.2.0-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/jaxb-runtime-2.4.0-b180830.0438-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/txw2-2.4.0-b180830.0438-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/istack-commons-runtime-3.0.7-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/stax-ex-1.8-javadoc.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/FastInfoset-1.2.15-javadoc.jar!/" />
</JAVADOC>
<SOURCES />
</library>
</component>

2
.idea/misc.xml generated
View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="ProjectRootManager" version="2" languageLevel="JDK_19" default="true" project-jdk-name="azul-19" project-jdk-type="JavaSDK"> <component name="ProjectRootManager" version="2" languageLevel="JDK_17" default="true" project-jdk-name="azul-17 (2)" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/out" /> <output url="file://$PROJECT_DIR$/out" />
</component> </component>
</project> </project>

6
.idea/vcs.xml generated Normal file
View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" />
</component>
</project>

View File

@ -7,12 +7,12 @@ public class A1 extends Application {
public A1() { public A1() {
} }
public void start(Stage stage) {
new B3();
}
public static void main(String[] args) { public static void main(String[] args) {
launch(args); launch(args);
} }
public void start(Stage stage) {
new B3();
}
} }

View File

@ -1,268 +1,235 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import javafx.event.ActionEvent; import javafx.event.ActionEvent;
import javafx.event.EventHandler; import javafx.event.EventHandler;
import javafx.scene.control.RadioButton; import javafx.scene.control.RadioButton;
public class A2 public class A2
implements EventHandler<ActionEvent> implements EventHandler<ActionEvent> {
{ private final B3 view;
private final B3 view;
public A2(B3 simpleFrame) {
public A2(B3 simpleFrame) { this.view = simpleFrame;
this.view = simpleFrame; }
}
public void handle(ActionEvent arg0) {
Object source = arg0.getSource();
if (source instanceof RadioButton && source == this.view.selectModeBTN) {
this.view.selectModeBTN.setStyle("-fx-text-fill:red");
this.view.creationModelabel.setStyle("-fx-text-fill:white");
this.view.menuVisibility.setDisable(false);
}
if (source instanceof RadioButton && source != this.view.selectModeBTN) {
this.view.menuVisibilityAllRMI.setSelected(true);
this.view.menuVisibilityTEXTRMI.setSelected(true);
(this.view.getCurrentTab()).canvas.modelVisibility();
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.menuVisibility.setDisable(true);
this.view.showAttributeCB.setSelected(false);
this.view.graphicElemLV.getItems().clear();
this.view.graphicElemLV.getItems().addAll((this.view.getCurrentTab()).canvas.sddsfsfsdf45645645());
this.view.selectModeBTN.setStyle("-fx-text-fill:white");
this.view.creationModelabel.setStyle("-fx-text-fill:red");
this.view.lastCreationSelected = (RadioButton)source;
if (this.view.getCurrentTab() == null) {
this.view.selectModeBTN.setSelected(true);
return;
}
if (this.view.generateRelationalModelCB.isSelected()) {
this.view.selectModeBTN.setStyle("-fx-text-fill:red");
this.view.creationModelabel.setStyle("-fx-text-fill:white");
this.view.selectModeBTN.setSelected(true);
return;
}
}
if (source == this.view.menuExitMI) {
this.view.close();
}
if (source == this.view.menuNewMI) {
this.view.setCurrentTab(this.view.addNewTab(null));
(this.view.getCurrentTab()).canvas.requestFocus();
this.view.tabPane.getSelectionModel().select(this.view.getCurrentTab());
}
if (source == this.view.menuRedrawMI) { public void handle(ActionEvent arg0) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); Object source = arg0.getSource();
}
if (source == this.view.menuExportMI) {
this.view.exportModel();
}
if (source == this.view.menuSaveMI) {
this.view.saveModel();
}
if (source == this.view.menuSaveAsMI) { if (source instanceof RadioButton && source == this.view.selectModeBTN) {
this.view.saveModelAs(); this.view.selectModeBTN.setStyle("-fx-text-fill:red");
} this.view.creationModelabel.setStyle("-fx-text-fill:white");
this.view.menuVisibility.setDisable(false);
if (source == this.view.menuReadMI) { }
this.view.readModel(); if (source instanceof RadioButton && source != this.view.selectModeBTN) {
}
this.view.menuVisibilityAllRMI.setSelected(true);
if (source == this.view.creation_selection_group.getSelectedToggle()) { this.view.menuVisibilityTEXTRMI.setSelected(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf43543ref(); (this.view.getCurrentTab()).canvas.modelVisibility();
} (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.menuVisibility.setDisable(true);
if (source == this.view.selectModeBTN) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); this.view.showAttributeCB.setSelected(false);
(this.view.getCurrentTab()).canvas.sdfsdfds435634terf(); this.view.graphicElemLV.getItems().clear();
this.view.statusInformation.setText("Selection mode: move mouse over element or use mouse to draw a rectangle - ESC -> deselect - DEL -> delete selected elements - pressed left mouse key -> move selected elements - right mouse over selected element -> open context menu"); this.view.graphicElemLV.getItems().addAll((this.view.getCurrentTab()).canvas.sddsfsfsdf45645645());
}
this.view.selectModeBTN.setStyle("-fx-text-fill:white");
this.view.creationModelabel.setStyle("-fx-text-fill:red");
this.view.lastCreationSelected = (RadioButton) source;
if (this.view.getCurrentTab() == null) {
if (source == this.view.textElemBTN) { this.view.selectModeBTN.setSelected(true);
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: text-element-with-border -> press left mouse button on working area -> enter text (ALT-Enter for linefeed) -> press enter key");
} return;
if (source == this.view.textWithoutBorderElemBTN) { }
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: text-element-without-border -> press left mouse button on working area -> enter text (ALT-Enter for linefeed) -> press enter key");
} if (this.view.generateRelationalModelCB.isSelected()) {
this.view.selectModeBTN.setStyle("-fx-text-fill:red");
if (source == this.view.esBTN) { this.view.creationModelabel.setStyle("-fx-text-fill:white");
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); this.view.selectModeBTN.setSelected(true);
this.view.statusInformation.setText("Creation Mode: entity-set -> press left mouse button on working area -> enter name of entity-set -> press enter key");
}
if (source == this.view.esWeakBTN) { return;
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); }
this.view.statusInformation.setText("Creation Mode: weak-entity-set -> press left mouse button on working area -> enter name of weak-entity-set -> press enter key"); }
}
if (source == this.view.esAssociativeBTN) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); if (source == this.view.menuExitMI) {
this.view.statusInformation.setText("Creation Mode: associative-entity-set -> press left mouse button on working area -> enter name of assoc.-entity-set -> press enter key"); this.view.close();
} }
if (source == this.view.rsBTN) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: relationship-type -> press left mouse button on working area -> enter name of relationship-type -> press enter key"); if (source == this.view.menuNewMI) {
} this.view.setCurrentTab(this.view.addNewTab(null));
if (source == this.view.rsIDBTN) { (this.view.getCurrentTab()).canvas.requestFocus();
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); this.view.tabPane.getSelectionModel().select(this.view.getCurrentTab());
this.view.statusInformation.setText("Creation Mode: identifying-relationship-type -> press left mouse button on working area -> enter name of entity-set -> press enter key"); }
}
if (source == this.view.rsISABTN) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); if (source == this.view.menuRedrawMI) {
this.view.statusInformation.setText("Creation Mode: isa relationship-type -> press left mouse button on working area -> enter type (p/t/d/nd) -> press enter key"); (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
} }
if (source == this.view.attrKeyBTN) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); if (source == this.view.menuExportMI) {
this.view.statusInformation.setText("Creation Mode: key-attribute"); this.view.exportModel();
} }
if (source == this.view.attrWeakKeyBTN) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); if (source == this.view.menuSaveMI) {
this.view.statusInformation.setText("Creation Mode: weak-key-attribute"); this.view.saveModel();
} }
if (source == this.view.attrOneBTN) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); if (source == this.view.menuSaveAsMI) {
this.view.saveModelAs();
this.view.statusInformation.setText("Creation Mode: one-value-attribute"); }
}
if (source == this.view.attrMultiBTN) { if (source == this.view.menuReadMI) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); this.view.readModel();
}
this.view.statusInformation.setText("Creation Mode: multi-value-attribute");
}
if (source == this.view.attrDerivedOneBTN) { if (source == this.view.creation_selection_group.getSelectedToggle()) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); (this.view.getCurrentTab()).canvas.sdfdsfdsdf43543ref();
}
this.view.statusInformation.setText("Creation Mode: derived-one-value-attribute");
}
if (source == this.view.attrDerivedMultiBTN) { if (source == this.view.selectModeBTN) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: derived-multi-value-attribute"); (this.view.getCurrentTab()).canvas.sdfsdfds435634terf();
} this.view.statusInformation.setText("Selection mode: move mouse over element or use mouse to draw a rectangle - ESC -> deselect - DEL -> delete selected elements - pressed left mouse key -> move selected elements - right mouse over selected element -> open context menu");
}
(this.view.getCurrentTab()).canvas.setConnectionModeSet(false);
if (source == this.view.attrToAttrBTN) { if (source == this.view.textElemBTN) {
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true); (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre(); this.view.statusInformation.setText("Creation Mode: text-element-with-border -> press left mouse button on working area -> enter text (ALT-Enter for linefeed) -> press enter key");
this.view.statusInformation.setText("Creation Mode: connect attribute to a composite-attribute - select element->click left mouse button->move mouse to second element->click left mouse button"); }
} if (source == this.view.textWithoutBorderElemBTN) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
if (source == this.view.attrToESBTN) { this.view.statusInformation.setText("Creation Mode: text-element-without-border -> press left mouse button on working area -> enter text (ALT-Enter for linefeed) -> press enter key");
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true); }
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre();
this.view.statusInformation.setText("Creation Mode: connect attribute with an entity-set - select element->click left mouse button->move mouse to second element->click left mouse button"); if (source == this.view.esBTN) {
} (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: entity-set -> press left mouse button on working area -> enter name of entity-set -> press enter key");
if (source == this.view.attrToRSBTN) { }
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true); if (source == this.view.esWeakBTN) {
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre(); (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: connect attribute with a relationship-type - select element->click left mouse button->move mouse to second element->click left mouse button"); this.view.statusInformation.setText("Creation Mode: weak-entity-set -> press left mouse button on working area -> enter name of weak-entity-set -> press enter key");
} }
if (source == this.view.esAssociativeBTN) {
if (source == this.view.attrToRSBTN) { (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true); this.view.statusInformation.setText("Creation Mode: associative-entity-set -> press left mouse button on working area -> enter name of assoc.-entity-set -> press enter key");
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre(); }
this.view.statusInformation.setText("Creation Mode: connect attribute with a relationship-type - select element->click left mouse button->move mouse to second element->click left mouse button"); if (source == this.view.rsBTN) {
} (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: relationship-type -> press left mouse button on working area -> enter name of relationship-type -> press enter key");
if (source == this.view.rsToESBTN) { }
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true); if (source == this.view.rsIDBTN) {
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre(); (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: connect relationship-type with (associative-)entity-set or entity-set with associative-entity-set - select element->click left mouse button->move mouse to second element->click left mouse button"); this.view.statusInformation.setText("Creation Mode: identifying-relationship-type -> press left mouse button on working area -> enter name of entity-set -> press enter key");
} }
if (source == this.view.rsISABTN) {
if (source == this.view.rsidToESBTN) { (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true); this.view.statusInformation.setText("Creation Mode: isa relationship-type -> press left mouse button on working area -> enter type (p/t/d/nd) -> press enter key");
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre(); }
this.view.statusInformation.setText("Creation Mode: connect identifying-relationship-type with entity-set - select element->click left mouse button->move mouse to second element->click left mouse button"); if (source == this.view.attrKeyBTN) {
} (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: key-attribute");
if (source == this.view.rsidToESWeakBTN) { }
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true); if (source == this.view.attrWeakKeyBTN) {
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre(); (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: connect identifying-relationship-type with weak-entity-set - select element->click left mouse button->move mouse to second element->click left mouse button"); this.view.statusInformation.setText("Creation Mode: weak-key-attribute");
} }
if (source == this.view.attrOneBTN) {
if (source == this.view.rsisaGeToESBTN) { (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre(); this.view.statusInformation.setText("Creation Mode: one-value-attribute");
this.view.statusInformation.setText("Creation Mode: connect isa-relationship-type with generalized entity-set - select element->click left mouse button->move mouse to second element->click left mouse button"); }
} if (source == this.view.attrMultiBTN) {
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
if (source == this.view.rsisaSpToESBTN) {
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true); this.view.statusInformation.setText("Creation Mode: multi-value-attribute");
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre(); }
this.view.statusInformation.setText("Creation Mode: connect isa-relationship-type with specialized entity-set - select element->click left mouse button->move mouse to second element->click left mouse button"); if (source == this.view.attrDerivedOneBTN) {
} (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
this.view.statusInformation.setText("Creation Mode: derived-one-value-attribute");
}
if (this.view.getCurrentTab() != null) { if (source == this.view.attrDerivedMultiBTN) {
(this.view.getCurrentTab()).canvas.dsfdsdfssdf45645re(); (this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
} this.view.statusInformation.setText("Creation Mode: derived-multi-value-attribute");
}
if (source == this.view.menuVisibilityTEXTRMI || source == this.view.menuVisibilityAllRMI || source == this.view.menuVisibilityES_RS_KEYRMI ||
source == this.view.menuVisibilityES_RSRMI) {
(this.view.getCurrentTab()).canvas.modelVisibility(); (this.view.getCurrentTab()).canvas.setConnectionModeSet(false);
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true); if (source == this.view.attrToAttrBTN) {
} (this.view.getCurrentTab()).canvas.setConnectionModeSet(true);
} (this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre();
} this.view.statusInformation.setText("Creation Mode: connect attribute to a composite-attribute - select element->click left mouse button->move mouse to second element->click left mouse button");
}
if (source == this.view.attrToESBTN) {
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre();
this.view.statusInformation.setText("Creation Mode: connect attribute with an entity-set - select element->click left mouse button->move mouse to second element->click left mouse button");
}
if (source == this.view.attrToRSBTN) {
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre();
this.view.statusInformation.setText("Creation Mode: connect attribute with a relationship-type - select element->click left mouse button->move mouse to second element->click left mouse button");
}
if (source == this.view.attrToRSBTN) {
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre();
this.view.statusInformation.setText("Creation Mode: connect attribute with a relationship-type - select element->click left mouse button->move mouse to second element->click left mouse button");
}
if (source == this.view.rsToESBTN) {
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre();
this.view.statusInformation.setText("Creation Mode: connect relationship-type with (associative-)entity-set or entity-set with associative-entity-set - select element->click left mouse button->move mouse to second element->click left mouse button");
}
if (source == this.view.rsidToESBTN) {
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre();
this.view.statusInformation.setText("Creation Mode: connect identifying-relationship-type with entity-set - select element->click left mouse button->move mouse to second element->click left mouse button");
}
if (source == this.view.rsidToESWeakBTN) {
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre();
this.view.statusInformation.setText("Creation Mode: connect identifying-relationship-type with weak-entity-set - select element->click left mouse button->move mouse to second element->click left mouse button");
}
if (source == this.view.rsisaGeToESBTN) {
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre();
this.view.statusInformation.setText("Creation Mode: connect isa-relationship-type with generalized entity-set - select element->click left mouse button->move mouse to second element->click left mouse button");
}
if (source == this.view.rsisaSpToESBTN) {
(this.view.getCurrentTab()).canvas.setConnectionModeSet(true);
(this.view.getCurrentTab()).canvas.sdfdsfdsdf34543erretwre();
this.view.statusInformation.setText("Creation Mode: connect isa-relationship-type with specialized entity-set - select element->click left mouse button->move mouse to second element->click left mouse button");
}
if (this.view.getCurrentTab() != null) {
(this.view.getCurrentTab()).canvas.dsfdsdfssdf45645re();
}
if (source == this.view.menuVisibilityTEXTRMI || source == this.view.menuVisibilityAllRMI || source == this.view.menuVisibilityES_RS_KEYRMI ||
source == this.view.menuVisibilityES_RSRMI) {
(this.view.getCurrentTab()).canvas.modelVisibility();
(this.view.getCurrentTab()).canvas.sdfsdfds3465er(true);
}
}
}

File diff suppressed because it is too large Load Diff

View File

@ -1,180 +1,163 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import javafx.geometry.Insets; import javafx.geometry.Insets;
import javafx.scene.Scene; import javafx.scene.Scene;
import javafx.scene.control.Label; import javafx.scene.control.Label;
import javafx.scene.control.TextField; import javafx.scene.control.TextField;
import javafx.scene.layout.GridPane; import javafx.scene.layout.GridPane;
import javafx.stage.Modality; import javafx.stage.Modality;
import javafx.stage.Stage; import javafx.stage.Stage;
import javafx.stage.StageStyle; import javafx.stage.StageStyle;
public class A4
extends Stage
{
private final A4 thisActionMessageDialog;
private final TextField minTF;
private final TextField maxTF;
private boolean doNothing;
private final String holdminimum;
private final String holdmaximum;
public A4(final A3 canvas, double xPos, double yPos, String minimum, String maximum) {
String title = "Enter Min-Max"; public class A4
extends Stage {
this.holdminimum = minimum; private final A4 thisActionMessageDialog;
this.holdmaximum = maximum; private final TextField minTF;
private final TextField maxTF;
this.doNothing = false; private final String holdminimum;
private final String holdmaximum;
this.thisActionMessageDialog = this; private boolean doNothing;
setTitle(title);
initModality(Modality.APPLICATION_MODAL);
this.minTF = new TextField(minimum);
this.minTF.textProperty().addListener((observable, oldValue, newValue) -> {
if (newValue.length() > 1 && newValue.charAt(0) == '0') {
newValue = newValue.replaceAll("^0*", "");
if (newValue.length() == 0)
newValue = "0";
this.minTF.setText(newValue);
}
if (!newValue.matches("\\d*"))
this.minTF.setText(newValue.replaceAll("[^\\d]", ""));
});
this.minTF.setPrefWidth(50.0D);
this.minTF.setOnMouseEntered(event -> T3.fdssdf4354(A4.this.minTF, C2.MouseSelectedColor));
this.minTF.setOnMouseExited(event -> A4.this.minTF.setEffect(null));
this.minTF.setOnKeyPressed(event -> {
switch (event.getCode()) {
case ENTER -> A4.this.maxTF.requestFocus();
case ESCAPE -> A4.this.setNothingAndLeave();
}
}); public A4(final A3 canvas, double xPos, double yPos, String minimum, String maximum) {
this.maxTF = new TextField(maximum);
this.maxTF.setPrefWidth(50.0D);
this.maxTF.textProperty().addListener((observable, oldValue, newValue) -> {
if (newValue.length() == 1 && newValue.charAt(0) == '0') {
newValue = "n";
this.maxTF.setText(newValue);
return;
}
if (newValue.length() > 1 && !newValue.matches("\\d*")) {
newValue = "n";
this.maxTF.setText(newValue);
return;
}
if (newValue.length() == 1 && newValue.charAt(0) == 'n') {
newValue = "n";
this.maxTF.setText(newValue);
return;
}
if (newValue.length() > 1 && newValue.charAt(0) == '0') {
newValue = newValue.replaceAll("^0*", "");
if (newValue.length() == 0)
newValue = "0";
this.maxTF.setText(newValue);
return;
}
if (!newValue.matches("\\d*"))
this.maxTF.setText(newValue.replaceAll("[^\\d]", ""));
});
this.maxTF.setOnMouseEntered(event -> T3.fdssdf4354(A4.this.maxTF, C2.MouseSelectedColor));
this.maxTF.setOnMouseExited(event -> A4.this.maxTF.setEffect(null));
this.maxTF.setOnKeyPressed(event -> {
switch (event.getCode()) {
case ENTER -> {
A4.this.setDataAndLeave();
if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
}
case ESCAPE -> A4.this.setNothingAndLeave();
}
}); String title = "Enter Min-Max";
GridPane gPane = new GridPane();
gPane.setPadding(new Insets(10.0D, 10.0D, 10.0D, 10.0D)); this.holdminimum = minimum;
this.holdmaximum = maximum;
gPane.setHgap(4.0D);
this.doNothing = false;
gPane.add(new Label("ESC->Cancel"), 0, 0, 2, 1);
gPane.add(new Label("Minimum:"), 0, 1); this.thisActionMessageDialog = this;
gPane.add(this.minTF, 1, 1); setTitle(title);
gPane.add(new Label("Maximum:"), 0, 2); initModality(Modality.APPLICATION_MODAL);
gPane.add(this.maxTF, 1, 2);
this.minTF = new TextField(minimum);
this.minTF.textProperty().addListener((observable, oldValue, newValue) -> {
if (newValue.length() > 1 && newValue.charAt(0) == '0') {
initStyle(StageStyle.UNDECORATED); newValue = newValue.replaceAll("^0*", "");
Scene scene = new Scene(gPane, 130.0D, 90.0D); if (newValue.length() == 0)
newValue = "0";
setScene(scene); this.minTF.setText(newValue);
}
setX(xPos); if (!newValue.matches("\\d*"))
setY(yPos); this.minTF.setText(newValue.replaceAll("[^\\d]", ""));
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) { });
setY(yPos - scene.getHeight() - 20.0D); this.minTF.setPrefWidth(50.0D);
} this.minTF.setOnMouseEntered(event -> T3.fdssdf4354(A4.this.minTF, C2.MouseSelectedColor));
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) { this.minTF.setOnMouseExited(event -> A4.this.minTF.setEffect(null));
setX(xPos - scene.getWidth() - 20.0D);
} this.minTF.setOnKeyPressed(event -> {
switch (event.getCode()) {
this.minTF.requestFocus(); case ENTER -> A4.this.maxTF.requestFocus();
this.minTF.selectPositionCaret(0); case ESCAPE -> A4.this.setNothingAndLeave();
this.minTF.selectEndOfNextWord(); }
sizeToScene();
showAndWait(); });
} this.maxTF = new TextField(maximum);
this.maxTF.setPrefWidth(50.0D);
this.maxTF.textProperty().addListener((observable, oldValue, newValue) -> {
if (newValue.length() == 1 && newValue.charAt(0) == '0') {
newValue = "n";
private void setDataAndLeave() { this.maxTF.setText(newValue);
if (this.minTF.getText() == null || this.minTF.getText().length() == 0) this.minTF.setText("m"); return;
if (this.maxTF.getText() == null || this.maxTF.getText().length() == 0) this.maxTF.setText("n"); }
this.thisActionMessageDialog.close(); if (newValue.length() > 1 && !newValue.matches("\\d*")) {
} newValue = "n";
this.maxTF.setText(newValue);
return;
}
if (newValue.length() == 1 && newValue.charAt(0) == 'n') {
newValue = "n";
private void setNothingAndLeave() { this.maxTF.setText(newValue);
this.minTF.setText(this.holdminimum); return;
this.maxTF.setText(this.holdmaximum); }
this.doNothing = true; if (newValue.length() > 1 && newValue.charAt(0) == '0') {
newValue = newValue.replaceAll("^0*", "");
this.thisActionMessageDialog.close(); if (newValue.length() == 0)
} newValue = "0";
this.maxTF.setText(newValue);
return;
}
if (!newValue.matches("\\d*"))
public TextField getMinTF() { this.maxTF.setText(newValue.replaceAll("[^\\d]", ""));
return this.minTF; });
} this.maxTF.setOnMouseEntered(event -> T3.fdssdf4354(A4.this.maxTF, C2.MouseSelectedColor));
this.maxTF.setOnMouseExited(event -> A4.this.maxTF.setEffect(null));
this.maxTF.setOnKeyPressed(event -> {
switch (event.getCode()) {
case ENTER -> {
public TextField getMaxTF() { A4.this.setDataAndLeave();
return this.maxTF; if (!canvas.getTabWithCanvas().getText().contains("*"))
} canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
}
case ESCAPE -> A4.this.setNothingAndLeave();
}
public boolean isDoNothing() { });
return this.doNothing; GridPane gPane = new GridPane();
} gPane.setPadding(new Insets(10.0D, 10.0D, 10.0D, 10.0D));
}
gPane.setHgap(4.0D);
gPane.add(new Label("ESC->Cancel"), 0, 0, 2, 1);
gPane.add(new Label("Minimum:"), 0, 1);
gPane.add(this.minTF, 1, 1);
gPane.add(new Label("Maximum:"), 0, 2);
gPane.add(this.maxTF, 1, 2);
initStyle(StageStyle.UNDECORATED);
Scene scene = new Scene(gPane, 130.0D, 90.0D);
setScene(scene);
setX(xPos);
setY(yPos);
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) {
setY(yPos - scene.getHeight() - 20.0D);
}
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) {
setX(xPos - scene.getWidth() - 20.0D);
}
this.minTF.requestFocus();
this.minTF.selectPositionCaret(0);
this.minTF.selectEndOfNextWord();
sizeToScene();
showAndWait();
}
private void setDataAndLeave() {
if (this.minTF.getText() == null || this.minTF.getText().length() == 0) this.minTF.setText("m");
if (this.maxTF.getText() == null || this.maxTF.getText().length() == 0) this.maxTF.setText("n");
this.thisActionMessageDialog.close();
}
private void setNothingAndLeave() {
this.minTF.setText(this.holdminimum);
this.maxTF.setText(this.holdmaximum);
this.doNothing = true;
this.thisActionMessageDialog.close();
}
public TextField getMinTF() {
return this.minTF;
}
public TextField getMaxTF() {
return this.maxTF;
}
public boolean isDoNothing() {
return this.doNothing;
}
}

View File

@ -1,117 +1,103 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import javafx.geometry.Insets; import javafx.geometry.Insets;
import javafx.scene.Scene; import javafx.scene.Scene;
import javafx.scene.control.Label; import javafx.scene.control.Label;
import javafx.scene.control.TextField; import javafx.scene.control.TextField;
import javafx.scene.layout.GridPane; import javafx.scene.layout.GridPane;
import javafx.stage.Modality; import javafx.stage.Modality;
import javafx.stage.Stage; import javafx.stage.Stage;
import javafx.stage.StageStyle; import javafx.stage.StageStyle;
public class A5 public class A5
extends Stage extends Stage {
{ private final A5 thisActionMessageDialog;
private final A5 thisActionMessageDialog; private final TextField nameTF;
private final TextField nameTF; private final String holdName;
private boolean doNothing; private boolean doNothing;
private final String holdName;
public A5(final A3 canvas, double xPos, double yPos, String name) {
String title = "Enter Name"; public A5(final A3 canvas, double xPos, double yPos, String name) {
this.holdName = name;
this.doNothing = false;
this.thisActionMessageDialog = this;
setTitle(title);
initModality(Modality.APPLICATION_MODAL);
this.nameTF = new TextField(name);
this.nameTF.setOnMouseEntered(event -> T3.fdssdf4354(A5.this.nameTF, C2.MouseSelectedColor));
this.nameTF.setOnMouseExited(event -> A5.this.nameTF.setEffect(null));
this.nameTF.setOnKeyPressed(event -> {
switch (event.getCode()) {
case ENTER -> {
A5.this.setDataAndLeave();
if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
}
case ESCAPE -> A5.this.setNothingAndLeave();
}
}); String title = "Enter Name";
GridPane fPane = new GridPane();
fPane.setPadding(new Insets(5.0D, 5.0D, 5.0D, 5.0D));
this.holdName = name;
fPane.setVgap(2.0D); this.doNothing = false;
fPane.setHgap(2.0D);
this.thisActionMessageDialog = this;
fPane.add(new Label("ESC->Cancel"), 0, 0, 2, 1); setTitle(title);
fPane.add(new Label("Name:"), 0, 1); initModality(Modality.APPLICATION_MODAL);
fPane.add(this.nameTF, 1, 1);
this.nameTF = new TextField(name);
this.nameTF.setOnMouseEntered(event -> T3.fdssdf4354(A5.this.nameTF, C2.MouseSelectedColor));
this.nameTF.setOnMouseExited(event -> A5.this.nameTF.setEffect(null));
this.nameTF.setOnKeyPressed(event -> {
Scene scene = new Scene(fPane, 220.0D, 75.0D); switch (event.getCode()) {
case ENTER -> {
setX(xPos); A5.this.setDataAndLeave();
setY(yPos); if (!canvas.getTabWithCanvas().getText().contains("*"))
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) { canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
setY(yPos - scene.getHeight() - 20.0D); }
} case ESCAPE -> A5.this.setNothingAndLeave();
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) { }
setX(xPos - scene.getWidth() - 20.0D);
} });
GridPane fPane = new GridPane();
this.nameTF.requestFocus(); fPane.setPadding(new Insets(5.0D, 5.0D, 5.0D, 5.0D));
this.nameTF.selectPositionCaret(0);
this.nameTF.selectEndOfNextWord(); fPane.setVgap(2.0D);
initStyle(StageStyle.UNDECORATED); fPane.setHgap(2.0D);
setScene(scene); fPane.add(new Label("ESC->Cancel"), 0, 0, 2, 1);
sizeToScene(); fPane.add(new Label("Name:"), 0, 1);
showAndWait(); fPane.add(this.nameTF, 1, 1);
}
Scene scene = new Scene(fPane, 220.0D, 75.0D);
setX(xPos);
private void setDataAndLeave() { setY(yPos);
if (this.nameTF.getText() == null || this.nameTF.getText().length() == 0) if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) {
return; this.thisActionMessageDialog.close(); setY(yPos - scene.getHeight() - 20.0D);
} }
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) {
setX(xPos - scene.getWidth() - 20.0D);
}
private void setNothingAndLeave() { this.nameTF.requestFocus();
this.nameTF.setText(this.holdName); this.nameTF.selectPositionCaret(0);
this.doNothing = true; this.nameTF.selectEndOfNextWord();
this.thisActionMessageDialog.close(); initStyle(StageStyle.UNDECORATED);
}
setScene(scene);
sizeToScene();
showAndWait();
}
public TextField getNameTF() {
return this.nameTF;
} private void setDataAndLeave() {
if (this.nameTF.getText() == null || this.nameTF.getText().length() == 0)
return;
this.thisActionMessageDialog.close();
}
public boolean isDoNothing() {
return this.doNothing;
} private void setNothingAndLeave() {
} this.nameTF.setText(this.holdName);
this.doNothing = true;
this.thisActionMessageDialog.close();
}
public TextField getNameTF() {
return this.nameTF;
}
public boolean isDoNothing() {
return this.doNothing;
}
}

View File

@ -1,206 +1,171 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import javafx.event.EventHandler; import javafx.event.EventHandler;
import javafx.geometry.Insets; import javafx.geometry.Insets;
import javafx.scene.Scene; import javafx.scene.Scene;
import javafx.scene.control.Label; import javafx.scene.control.Label;
import javafx.scene.control.TextField; import javafx.scene.control.TextField;
import javafx.scene.input.KeyEvent; import javafx.scene.input.KeyEvent;
import javafx.scene.layout.GridPane; import javafx.scene.layout.GridPane;
import javafx.stage.Modality; import javafx.stage.Modality;
import javafx.stage.Stage; import javafx.stage.Stage;
import javafx.stage.StageStyle; import javafx.stage.StageStyle;
public class A6
extends Stage
{
private final A6 thisActionMessageDialog;
private final TextField p_tTF;
private final TextField d_ndTF;
private boolean doNothing;
private final String holdpartial_or_total;
private final String holddisjunct_or_notdisjunct;
public A6(final A3 canvas, double xPos, double yPos, String partial_or_total, String disjunct_or_notdisjunct) {
String title = "Enter P-T-D-ND";
this.doNothing = false;
if (partial_or_total == null) partial_or_total = "p";
if (disjunct_or_notdisjunct == null) disjunct_or_notdisjunct = "nd";
this.holdpartial_or_total = partial_or_total;
this.holddisjunct_or_notdisjunct = disjunct_or_notdisjunct;
this.thisActionMessageDialog = this;
setTitle(title);
initModality(Modality.APPLICATION_MODAL);
this.p_tTF = new TextField(partial_or_total);
this.p_tTF.setPrefWidth(50.0D);
this.p_tTF.textProperty().addListener((observable, oldValue, newValue) -> {
if (newValue.length() == 1 && newValue.charAt(0) != 'p' && newValue.charAt(0) != 't') {
newValue = "p";
this.p_tTF.setText(newValue);
return;
}
if (newValue.length() > 1) {
newValue = oldValue;
this.p_tTF.setText(newValue);
return;
}
if (newValue.length() == 1 && (newValue.charAt(0) == 'p' || newValue.charAt(0) == 't')) {
this.p_tTF.setText(newValue);
}
});
this.p_tTF.setOnMouseEntered(event -> T3.fdssdf4354(A6.this.p_tTF, C2.MouseSelectedColor));
this.p_tTF.setOnMouseExited(event -> A6.this.p_tTF.setEffect(null));
this.p_tTF.setOnKeyPressed(new EventHandler<>() {
public void handle(KeyEvent event) { public class A6
switch (event.getCode()) { extends Stage {
case ENTER -> A6.this.d_ndTF.requestFocus(); private final A6 thisActionMessageDialog;
case ESCAPE -> A6.this.setNothingAndLeave(); private final TextField p_tTF;
} private final TextField d_ndTF;
private final String holdpartial_or_total;
private final String holddisjunct_or_notdisjunct;
private boolean doNothing;
} public A6(final A3 canvas, double xPos, double yPos, String partial_or_total, String disjunct_or_notdisjunct) {
});
this.d_ndTF = new TextField(disjunct_or_notdisjunct);
this.d_ndTF.setPrefWidth(50.0D);
this.d_ndTF.textProperty().addListener((observable, oldValue, newValue) -> {
if (newValue.length() == 1 && newValue.charAt(0) != 'd') {
newValue = "d";
this.d_ndTF.setText(newValue);
return;
}
if (newValue.length() == 2 && !newValue.equals("nd")) {
newValue = "nd";
this.d_ndTF.setText(newValue);
return;
}
if (newValue.length() > 2) {
newValue = oldValue;
this.d_ndTF.setText(newValue);
return;
}
if (newValue.length() == 1 && newValue.charAt(0) == 'd') {
this.d_ndTF.setText(newValue);
}
});
this.d_ndTF.setOnMouseEntered(event -> T3.fdssdf4354(A6.this.d_ndTF, C2.MouseSelectedColor));
this.d_ndTF.setOnMouseExited(event -> A6.this.d_ndTF.setEffect(null));
this.d_ndTF.setOnKeyPressed(event -> {
switch (event.getCode()) {
case ENTER -> {
A6.this.setDataAndLeave();
if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
}
case ESCAPE -> A6.this.setNothingAndLeave();
}
}); String title = "Enter P-T-D-ND";
GridPane gPane = new GridPane();
gPane.setPadding(new Insets(10.0D, 10.0D, 10.0D, 10.0D)); this.doNothing = false;
gPane.setHgap(4.0D); if (partial_or_total == null) partial_or_total = "p";
if (disjunct_or_notdisjunct == null) disjunct_or_notdisjunct = "nd";
gPane.add(new Label("ESC->Cancel"), 0, 0); this.holdpartial_or_total = partial_or_total;
gPane.add(new Label("Partial[p]/Total[t]:"), 0, 1); this.holddisjunct_or_notdisjunct = disjunct_or_notdisjunct;
gPane.add(this.p_tTF, 1, 1);
gPane.add(new Label("Disjunct[d]/Not disjunct[nd]:"), 0, 2); this.thisActionMessageDialog = this;
gPane.add(this.d_ndTF, 1, 2); setTitle(title);
initModality(Modality.APPLICATION_MODAL);
this.p_tTF = new TextField(partial_or_total);
initStyle(StageStyle.UNDECORATED); this.p_tTF.setPrefWidth(50.0D);
Scene scene = new Scene(gPane, 230.0D, 90.0D); this.p_tTF.textProperty().addListener((observable, oldValue, newValue) -> {
if (newValue.length() == 1 && newValue.charAt(0) != 'p' && newValue.charAt(0) != 't') {
setScene(scene); newValue = "p";
setX(xPos); this.p_tTF.setText(newValue);
setY(yPos);
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) { return;
setY(yPos - scene.getHeight() - 20.0D); }
} if (newValue.length() > 1) {
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) { newValue = oldValue;
setX(xPos - scene.getWidth() - 20.0D); this.p_tTF.setText(newValue);
} return;
}
this.p_tTF.requestFocus(); if (newValue.length() == 1 && (newValue.charAt(0) == 'p' || newValue.charAt(0) == 't')) {
this.p_tTF.selectPositionCaret(0); this.p_tTF.setText(newValue);
this.p_tTF.selectEndOfNextWord(); }
});
sizeToScene(); this.p_tTF.setOnMouseEntered(event -> T3.fdssdf4354(A6.this.p_tTF, C2.MouseSelectedColor));
showAndWait(); this.p_tTF.setOnMouseExited(event -> A6.this.p_tTF.setEffect(null));
} this.p_tTF.setOnKeyPressed(new EventHandler<>() {
public void handle(KeyEvent event) {
switch (event.getCode()) {
case ENTER -> A6.this.d_ndTF.requestFocus();
private void setDataAndLeave() { case ESCAPE -> A6.this.setNothingAndLeave();
if (this.p_tTF.getText() == null || this.p_tTF.getText().length() == 0) this.p_tTF.setText("p"); }
if (this.d_ndTF.getText() == null || this.d_ndTF.getText().length() == 0) this.d_ndTF.setText("nd");
this.thisActionMessageDialog.close(); }
} });
this.d_ndTF = new TextField(disjunct_or_notdisjunct);
this.d_ndTF.setPrefWidth(50.0D);
this.d_ndTF.textProperty().addListener((observable, oldValue, newValue) -> {
if (newValue.length() == 1 && newValue.charAt(0) != 'd') {
private void setNothingAndLeave() { newValue = "d";
this.p_tTF.setText(this.holdpartial_or_total);
this.d_ndTF.setText(this.holddisjunct_or_notdisjunct); this.d_ndTF.setText(newValue);
this.doNothing = true; return;
}
this.thisActionMessageDialog.close(); if (newValue.length() == 2 && !newValue.equals("nd")) {
} newValue = "nd";
this.d_ndTF.setText(newValue);
return;
}
if (newValue.length() > 2) {
public TextField getP_tTF() { newValue = oldValue;
return this.p_tTF; this.d_ndTF.setText(newValue);
} return;
}
if (newValue.length() == 1 && newValue.charAt(0) == 'd') {
this.d_ndTF.setText(newValue);
}
public TextField getD_ndTF() { });
return this.d_ndTF; this.d_ndTF.setOnMouseEntered(event -> T3.fdssdf4354(A6.this.d_ndTF, C2.MouseSelectedColor));
} this.d_ndTF.setOnMouseExited(event -> A6.this.d_ndTF.setEffect(null));
this.d_ndTF.setOnKeyPressed(event -> {
switch (event.getCode()) {
case ENTER -> {
A6.this.setDataAndLeave();
public boolean isDoNothing() { if (!canvas.getTabWithCanvas().getText().contains("*"))
return this.doNothing; canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
} }
} case ESCAPE -> A6.this.setNothingAndLeave();
}
});
GridPane gPane = new GridPane();
gPane.setPadding(new Insets(10.0D, 10.0D, 10.0D, 10.0D));
gPane.setHgap(4.0D);
gPane.add(new Label("ESC->Cancel"), 0, 0);
gPane.add(new Label("Partial[p]/Total[t]:"), 0, 1);
gPane.add(this.p_tTF, 1, 1);
gPane.add(new Label("Disjunct[d]/Not disjunct[nd]:"), 0, 2);
gPane.add(this.d_ndTF, 1, 2);
initStyle(StageStyle.UNDECORATED);
Scene scene = new Scene(gPane, 230.0D, 90.0D);
setScene(scene);
setX(xPos);
setY(yPos);
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) {
setY(yPos - scene.getHeight() - 20.0D);
}
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) {
setX(xPos - scene.getWidth() - 20.0D);
}
this.p_tTF.requestFocus();
this.p_tTF.selectPositionCaret(0);
this.p_tTF.selectEndOfNextWord();
sizeToScene();
showAndWait();
}
private void setDataAndLeave() {
if (this.p_tTF.getText() == null || this.p_tTF.getText().length() == 0) this.p_tTF.setText("p");
if (this.d_ndTF.getText() == null || this.d_ndTF.getText().length() == 0) this.d_ndTF.setText("nd");
this.thisActionMessageDialog.close();
}
private void setNothingAndLeave() {
this.p_tTF.setText(this.holdpartial_or_total);
this.d_ndTF.setText(this.holddisjunct_or_notdisjunct);
this.doNothing = true;
this.thisActionMessageDialog.close();
}
public TextField getP_tTF() {
return this.p_tTF;
}
public TextField getD_ndTF() {
return this.d_ndTF;
}
public boolean isDoNothing() {
return this.doNothing;
}
}

View File

@ -1,160 +1,122 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import javafx.geometry.Insets; import javafx.geometry.Insets;
import javafx.scene.Scene; import javafx.scene.Scene;
import javafx.scene.control.Label; import javafx.scene.control.Label;
import javafx.scene.control.TextArea; import javafx.scene.control.TextArea;
import javafx.scene.input.KeyCode; import javafx.scene.input.KeyCode;
import javafx.scene.input.KeyCodeCombination; import javafx.scene.input.KeyCodeCombination;
import javafx.scene.input.KeyCombination; import javafx.scene.input.KeyCombination;
import javafx.scene.layout.GridPane; import javafx.scene.layout.GridPane;
import javafx.stage.Modality; import javafx.stage.Modality;
import javafx.stage.Stage; import javafx.stage.Stage;
import javafx.stage.StageStyle; import javafx.stage.StageStyle;
public class A7
extends Stage
{
private final A7 thisActionMessageDialog;
private final TextArea textTA;
private boolean doNothing;
private final String holdName;
final KeyCombination keyCombinationALT_ENTER = new KeyCodeCombination(KeyCode.ENTER, KeyCombination.ALT_DOWN);
public A7(final A3 canvas, double xPos, double yPos, String name) {
String title = "Enter Name";
this.holdName = name;
this.doNothing = false;
this.thisActionMessageDialog = this;
setTitle(title);
initModality(Modality.APPLICATION_MODAL);
this.textTA = new TextArea(name);
this.textTA.setPrefWidth(350.0D);
this.textTA.setPrefHeight(100.0D);
this.textTA.setOnMouseEntered(event -> T3.fdssdf4354(A7.this.textTA, C2.MouseSelectedColor));
this.textTA.setOnMouseExited(event -> A7.this.textTA.setEffect(null));
this.textTA.setOnKeyPressed(event -> {
if (A7.this.keyCombinationALT_ENTER.match(event)) {
A7.this.textTA.appendText("\n");
event.consume();
return;
}
switch (event.getCode()) {
case ENTER -> {
event.consume();
A7.this.setDataAndLeave();
if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
}
case ESCAPE -> A7.this.setNothingAndLeave();
}
}); public class A7
GridPane fPane = new GridPane(); extends Stage {
fPane.setPadding(new Insets(10.0D, 10.0D, 10.0D, 10.0D)); final KeyCombination keyCombinationALT_ENTER = new KeyCodeCombination(KeyCode.ENTER, KeyCombination.ALT_DOWN);
private final A7 thisActionMessageDialog;
fPane.setHgap(4.0D); private final TextArea textTA;
private final String holdName;
fPane.add(new Label("ESC->Cancel, Alt-Enter->Linefeed"), 0, 0, 2, 1); private boolean doNothing;
fPane.add(this.textTA, 0, 1);
public A7(final A3 canvas, double xPos, double yPos, String name) {
initStyle(StageStyle.UNDECORATED); String title = "Enter Name";
Scene scene = new Scene(fPane, 370.0D, 150.0D);
setScene(scene); this.holdName = name;
setX(xPos); this.doNothing = false;
setY(yPos);
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) { this.thisActionMessageDialog = this;
setY(yPos - scene.getHeight() - 20.0D); setTitle(title);
} initModality(Modality.APPLICATION_MODAL);
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) {
setX(xPos - scene.getWidth() - 20.0D);
} this.textTA = new TextArea(name);
this.textTA.setPrefWidth(350.0D);
this.textTA.requestFocus(); this.textTA.setPrefHeight(100.0D);
this.textTA.setOnMouseEntered(event -> T3.fdssdf4354(A7.this.textTA, C2.MouseSelectedColor));
this.textTA.setOnMouseExited(event -> A7.this.textTA.setEffect(null));
sizeToScene(); this.textTA.setOnKeyPressed(event -> {
showAndWait(); if (A7.this.keyCombinationALT_ENTER.match(event)) {
} A7.this.textTA.appendText("\n");
event.consume();
return;
}
switch (event.getCode()) {
case ENTER -> {
private void setDataAndLeave() { event.consume();
if (this.textTA.getText() == null || this.textTA.getText().length() == 0) { A7.this.setDataAndLeave();
this.textTA.setText(""); if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
}
return; case ESCAPE -> A7.this.setNothingAndLeave();
} }
this.thisActionMessageDialog.close();
} });
GridPane fPane = new GridPane();
fPane.setPadding(new Insets(10.0D, 10.0D, 10.0D, 10.0D));
fPane.setHgap(4.0D);
private void setNothingAndLeave() {
this.textTA.setText(this.holdName); fPane.add(new Label("ESC->Cancel, Alt-Enter->Linefeed"), 0, 0, 2, 1);
this.doNothing = true; fPane.add(this.textTA, 0, 1);
this.thisActionMessageDialog.close();
}
initStyle(StageStyle.UNDECORATED);
Scene scene = new Scene(fPane, 370.0D, 150.0D);
setScene(scene);
public TextArea getTextTA() {
return this.textTA; setX(xPos);
} setY(yPos);
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) {
setY(yPos - scene.getHeight() - 20.0D);
}
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) {
public boolean isDoNothing() { setX(xPos - scene.getWidth() - 20.0D);
return this.doNothing; }
}
} this.textTA.requestFocus();
sizeToScene();
showAndWait();
}
private void setDataAndLeave() {
if (this.textTA.getText() == null || this.textTA.getText().length() == 0) {
this.textTA.setText("");
return;
}
this.thisActionMessageDialog.close();
}
private void setNothingAndLeave() {
this.textTA.setText(this.holdName);
this.doNothing = true;
this.thisActionMessageDialog.close();
}
public TextArea getTextTA() {
return this.textTA;
}
public boolean isDoNothing() {
return this.doNothing;
}
}

File diff suppressed because it is too large Load Diff

View File

@ -1,248 +1,229 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import javafx.event.ActionEvent; import javafx.event.ActionEvent;
import javafx.event.EventHandler; import javafx.event.EventHandler;
import javafx.geometry.Insets; import javafx.geometry.Insets;
import javafx.scene.Cursor; import javafx.scene.Cursor;
import javafx.scene.Scene; import javafx.scene.Scene;
import javafx.scene.control.Button; import javafx.scene.control.Button;
import javafx.scene.control.CheckBox; import javafx.scene.control.CheckBox;
import javafx.scene.control.Label; import javafx.scene.control.Label;
import javafx.scene.control.TextField; import javafx.scene.control.TextField;
import javafx.scene.input.KeyCode; import javafx.scene.input.KeyCode;
import javafx.scene.layout.*; import javafx.scene.layout.*;
import javafx.stage.Modality; import javafx.stage.Modality;
import javafx.stage.Stage; import javafx.stage.Stage;
import java.util.Objects; import java.util.Objects;
public class A9 public class A9
extends Stage extends Stage {
{ private final A9 thisActionMessageDialog;
private final A9 thisActionMessageDialog; private final TextField nameTF;
private final TextField nameTF; private final CheckBox createRelationCB;
private final CheckBox createRelationCB; private final TextField relationNameTF;
private final TextField relationNameTF; private final TextField relationPraefixTF;
private final TextField relationPraefixTF; private final CheckBox createInsertStatementsCB;
private final CheckBox createInsertStatementsCB; private final TextField numberRowsToInsertTF;
private final TextField numberRowsToInsertTF; private final Button okBTN;
private final Button okBTN; private final String holdName;
private Button cancelBTN; private Button cancelBTN;
private final String holdName;
public A9(final A3 canvas, double xPos, double yPos, String name, boolean createRelation, String relationName, String relationPraefix, boolean createInsertStatements, long numberRowsToInsert, boolean setCreationRelationChangeable) {
String title = "ES/RS Transformation"; public A9(final A3 canvas, double xPos, double yPos, String name, boolean createRelation, String relationName, String relationPraefix, boolean createInsertStatements, long numberRowsToInsert, boolean setCreationRelationChangeable) {
this.holdName = name;
this.thisActionMessageDialog = this;
setTitle(title);
initModality(Modality.APPLICATION_MODAL);
this.nameTF = new TextField(name);
this.nameTF.setDisable(true);
this.createRelationCB = new CheckBox();
this.createRelationCB.setSelected(false);
if (!setCreationRelationChangeable) this.createRelationCB.setDisable(true);
if (createRelation) this.createRelationCB.setSelected(true);
this.relationPraefixTF = new TextField(relationPraefix);
this.relationPraefixTF.setOnMouseEntered(event -> T3.fdssdf4354(A9.this.relationPraefixTF, C2.MouseSelectedColor));
this.relationPraefixTF.setOnMouseExited(event -> A9.this.relationPraefixTF.setEffect(null));
this.relationNameTF = new TextField(relationName);
this.relationNameTF.setOnMouseEntered(event -> T3.fdssdf4354(A9.this.relationNameTF, C2.MouseSelectedColor));
this.relationNameTF.setOnMouseExited(event -> A9.this.relationNameTF.setEffect(null));
this.createInsertStatementsCB = new CheckBox();
this.createInsertStatementsCB.setSelected(true);
this.createInsertStatementsCB.setDisable(true);
if (createInsertStatements) this.createInsertStatementsCB.setSelected(true);
this.createInsertStatementsCB.setOnAction(new EventHandler<>() {
public void handle(ActionEvent event) {
A9.this.numberRowsToInsertTF.setDisable(!A9.this.createInsertStatementsCB.isSelected());
}
});
this.numberRowsToInsertTF = new TextField(String.valueOf(numberRowsToInsert));
this.numberRowsToInsertTF.setDisable(true);
if (createInsertStatements) this.numberRowsToInsertTF.setDisable(false);
this.okBTN = new Button("Ok");
this.okBTN.setBackground(new Background(new BackgroundFill(C2.ButtonBackgroundColor, new CornerRadii(5.0D), Insets.EMPTY)));
this.okBTN.setOnMouseEntered(event -> {
A9.this.getScene().getRoot().setCursor(Cursor.HAND);
T3.fdssdf4354(A9.this.okBTN, C2.MouseSelectedColor);
});
this.okBTN.setOnMouseExited(event -> {
A9.this.getScene().getRoot().setCursor(Cursor.DEFAULT);
A9.this.okBTN.setEffect(null);
if (A9.this.okBTN.isFocused()) T3.fdssdf4354(A9.this.okBTN, C2.FocusOnComponentColor);
});
this.okBTN.focusedProperty().addListener((obs, oldVal, newVal) -> {
if (this.okBTN.isFocused()) {
T3.fdssdf4354(this.okBTN, C2.FocusOnComponentColor);
this.relationPraefixTF.setEffect(null);
this.cancelBTN.setEffect(null);
} else {
this.okBTN.setEffect(null);
}
});
this.okBTN.setOnAction(event -> {
A9.this.setDataAndLeave();
if (!canvas.getTabWithCanvas().getText().contains("*")) canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*"); String title = "ES/RS Transformation";
});
this.okBTN.setOnKeyPressed(event -> {
if (Objects.requireNonNull(event.getCode()) == KeyCode.ENTER) {
A9.this.setDataAndLeave();
if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
}
this.holdName = name;
}); this.thisActionMessageDialog = this;
this.cancelBTN = new Button("Cancel"); setTitle(title);
this.cancelBTN.setBackground(new Background(new BackgroundFill(C2.ButtonBackgroundColor, new CornerRadii(5.0D), Insets.EMPTY))); initModality(Modality.APPLICATION_MODAL);
this.cancelBTN.setOnMouseEntered(event -> {
A9.this.getScene().getRoot().setCursor(Cursor.HAND);
T3.fdssdf4354(A9.this.cancelBTN, C2.MouseSelectedColor);
});
this.cancelBTN.setOnMouseExited(event -> {
A9.this.getScene().getRoot().setCursor(Cursor.DEFAULT);
A9.this.cancelBTN.setEffect(null);
if (A9.this.cancelBTN.isFocused()) T3.fdssdf4354(A9.this.cancelBTN, C2.FocusOnComponentColor);
});
this.cancelBTN.focusedProperty().addListener((obs, oldVal, newVal) -> {
if (this.cancelBTN.isFocused()) {
T3.fdssdf4354(this.cancelBTN, C2.FocusOnComponentColor);
this.relationPraefixTF.setEffect(null);
this.okBTN.setEffect(null);
} else {
this.cancelBTN.setEffect(null);
}
});
this.cancelBTN.setOnAction(event -> A9.this.setNothingAndLeave());
this.cancelBTN.setOnKeyPressed(event -> {
if (Objects.requireNonNull(event.getCode()) == KeyCode.ENTER) {
A9.this.setNothingAndLeave();
}
}); this.nameTF = new TextField(name);
GridPane gridPane = new GridPane(); this.nameTF.setDisable(true);
gridPane.setPadding(new Insets(10.0D, 10.0D, 10.0D, 10.0D));
gridPane.setVgap(4.0D);
gridPane.setHgap(4.0D);
gridPane.add(new Label("Name:"), 0, 0);
gridPane.add(this.nameTF, 1, 0);
gridPane.add(new Label("Create relation:"), 0, 1);
gridPane.add(this.createRelationCB, 1, 1);
gridPane.add(new Label("Relation name:"), 0, 2);
gridPane.add(this.relationNameTF, 1, 2);
gridPane.add(new Label("Relation praefix:"), 0, 3);
gridPane.add(this.relationPraefixTF, 1, 3);
gridPane.add(new Label("Create inserts:"), 0, 4);
gridPane.add(this.createInsertStatementsCB, 1, 4);
gridPane.add(new Label("Number rows:"), 0, 5);
gridPane.add(this.numberRowsToInsertTF, 1, 5);
FlowPane fp = new FlowPane();
fp.setHgap(10.0D);
fp.getChildren().addAll(this.okBTN, this.cancelBTN);
gridPane.add(fp, 0, 6, 2, 1);
Scene scene = new Scene(gridPane, 300.0D, 205.0D);
setScene(scene);
sizeToScene();
setX(xPos);
setY(yPos);
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) {
setY(yPos - scene.getHeight() - 20.0D);
}
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) {
setX(xPos - scene.getWidth() - 20.0D);
}
this.relationNameTF.requestFocus();
sizeToScene();
showAndWait();
}
private void setDataAndLeave() {
if (this.nameTF.getText() == null || this.nameTF.getText().length() == 0)
return; this.thisActionMessageDialog.close();
}
private void setNothingAndLeave() {
this.nameTF.setText(this.holdName);
this.thisActionMessageDialog.close();
}
public CheckBox getCreateRelationCB() { this.createRelationCB = new CheckBox();
return this.createRelationCB; this.createRelationCB.setSelected(false);
}
if (!setCreationRelationChangeable) this.createRelationCB.setDisable(true);
if (createRelation) this.createRelationCB.setSelected(true);
this.relationPraefixTF = new TextField(relationPraefix);
public TextField getRelationNameTF() { this.relationPraefixTF.setOnMouseEntered(event -> T3.fdssdf4354(A9.this.relationPraefixTF, C2.MouseSelectedColor));
return this.relationNameTF; this.relationPraefixTF.setOnMouseExited(event -> A9.this.relationPraefixTF.setEffect(null));
} this.relationNameTF = new TextField(relationName);
this.relationNameTF.setOnMouseEntered(event -> T3.fdssdf4354(A9.this.relationNameTF, C2.MouseSelectedColor));
this.relationNameTF.setOnMouseExited(event -> A9.this.relationNameTF.setEffect(null));
public TextField getRelationPraefixTF() { this.createInsertStatementsCB = new CheckBox();
return this.relationPraefixTF; this.createInsertStatementsCB.setSelected(true);
} this.createInsertStatementsCB.setDisable(true);
if (createInsertStatements) this.createInsertStatementsCB.setSelected(true);
this.createInsertStatementsCB.setOnAction(new EventHandler<>() {
public void handle(ActionEvent event) {
A9.this.numberRowsToInsertTF.setDisable(!A9.this.createInsertStatementsCB.isSelected());
public CheckBox getCreateInsertStatementsCB() { }
return this.createInsertStatementsCB; });
} this.numberRowsToInsertTF = new TextField(String.valueOf(numberRowsToInsert));
this.numberRowsToInsertTF.setDisable(true);
if (createInsertStatements) this.numberRowsToInsertTF.setDisable(false);
this.okBTN = new Button("Ok");
public TextField getNumberRowsToInsertTF() { this.okBTN.setBackground(new Background(new BackgroundFill(C2.ButtonBackgroundColor, new CornerRadii(5.0D), Insets.EMPTY)));
return this.numberRowsToInsertTF; this.okBTN.setOnMouseEntered(event -> {
} A9.this.getScene().getRoot().setCursor(Cursor.HAND);
} T3.fdssdf4354(A9.this.okBTN, C2.MouseSelectedColor);
});
this.okBTN.setOnMouseExited(event -> {
A9.this.getScene().getRoot().setCursor(Cursor.DEFAULT);
A9.this.okBTN.setEffect(null);
if (A9.this.okBTN.isFocused()) T3.fdssdf4354(A9.this.okBTN, C2.FocusOnComponentColor);
});
this.okBTN.focusedProperty().addListener((obs, oldVal, newVal) -> {
if (this.okBTN.isFocused()) {
T3.fdssdf4354(this.okBTN, C2.FocusOnComponentColor);
this.relationPraefixTF.setEffect(null);
this.cancelBTN.setEffect(null);
} else {
this.okBTN.setEffect(null);
}
});
this.okBTN.setOnAction(event -> {
A9.this.setDataAndLeave();
if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
});
this.okBTN.setOnKeyPressed(event -> {
if (Objects.requireNonNull(event.getCode()) == KeyCode.ENTER) {
A9.this.setDataAndLeave();
if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
}
});
this.cancelBTN = new Button("Cancel");
this.cancelBTN.setBackground(new Background(new BackgroundFill(C2.ButtonBackgroundColor, new CornerRadii(5.0D), Insets.EMPTY)));
this.cancelBTN.setOnMouseEntered(event -> {
A9.this.getScene().getRoot().setCursor(Cursor.HAND);
T3.fdssdf4354(A9.this.cancelBTN, C2.MouseSelectedColor);
});
this.cancelBTN.setOnMouseExited(event -> {
A9.this.getScene().getRoot().setCursor(Cursor.DEFAULT);
A9.this.cancelBTN.setEffect(null);
if (A9.this.cancelBTN.isFocused()) T3.fdssdf4354(A9.this.cancelBTN, C2.FocusOnComponentColor);
});
this.cancelBTN.focusedProperty().addListener((obs, oldVal, newVal) -> {
if (this.cancelBTN.isFocused()) {
T3.fdssdf4354(this.cancelBTN, C2.FocusOnComponentColor);
this.relationPraefixTF.setEffect(null);
this.okBTN.setEffect(null);
} else {
this.cancelBTN.setEffect(null);
}
});
this.cancelBTN.setOnAction(event -> A9.this.setNothingAndLeave());
this.cancelBTN.setOnKeyPressed(event -> {
if (Objects.requireNonNull(event.getCode()) == KeyCode.ENTER) {
A9.this.setNothingAndLeave();
}
});
GridPane gridPane = new GridPane();
gridPane.setPadding(new Insets(10.0D, 10.0D, 10.0D, 10.0D));
gridPane.setVgap(4.0D);
gridPane.setHgap(4.0D);
gridPane.add(new Label("Name:"), 0, 0);
gridPane.add(this.nameTF, 1, 0);
gridPane.add(new Label("Create relation:"), 0, 1);
gridPane.add(this.createRelationCB, 1, 1);
gridPane.add(new Label("Relation name:"), 0, 2);
gridPane.add(this.relationNameTF, 1, 2);
gridPane.add(new Label("Relation praefix:"), 0, 3);
gridPane.add(this.relationPraefixTF, 1, 3);
gridPane.add(new Label("Create inserts:"), 0, 4);
gridPane.add(this.createInsertStatementsCB, 1, 4);
gridPane.add(new Label("Number rows:"), 0, 5);
gridPane.add(this.numberRowsToInsertTF, 1, 5);
FlowPane fp = new FlowPane();
fp.setHgap(10.0D);
fp.getChildren().addAll(this.okBTN, this.cancelBTN);
gridPane.add(fp, 0, 6, 2, 1);
Scene scene = new Scene(gridPane, 300.0D, 205.0D);
setScene(scene);
sizeToScene();
setX(xPos);
setY(yPos);
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) {
setY(yPos - scene.getHeight() - 20.0D);
}
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) {
setX(xPos - scene.getWidth() - 20.0D);
}
this.relationNameTF.requestFocus();
sizeToScene();
showAndWait();
}
private void setDataAndLeave() {
if (this.nameTF.getText() == null || this.nameTF.getText().length() == 0)
return;
this.thisActionMessageDialog.close();
}
private void setNothingAndLeave() {
this.nameTF.setText(this.holdName);
this.thisActionMessageDialog.close();
}
public CheckBox getCreateRelationCB() {
return this.createRelationCB;
}
public TextField getRelationNameTF() {
return this.relationNameTF;
}
public TextField getRelationPraefixTF() {
return this.relationPraefixTF;
}
public CheckBox getCreateInsertStatementsCB() {
return this.createInsertStatementsCB;
}
public TextField getNumberRowsToInsertTF() {
return this.numberRowsToInsertTF;
}
}

View File

@ -1,334 +1,301 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import javafx.geometry.Insets; import javafx.geometry.Insets;
import javafx.scene.Cursor; import javafx.scene.Cursor;
import javafx.scene.Scene; import javafx.scene.Scene;
import javafx.scene.control.Button; import javafx.scene.control.Button;
import javafx.scene.control.CheckBox; import javafx.scene.control.CheckBox;
import javafx.scene.control.Label; import javafx.scene.control.Label;
import javafx.scene.control.TextField; import javafx.scene.control.TextField;
import javafx.scene.input.KeyCode; import javafx.scene.input.KeyCode;
import javafx.scene.layout.*; import javafx.scene.layout.*;
import javafx.stage.Modality; import javafx.stage.Modality;
import javafx.stage.Stage; import javafx.stage.Stage;
import java.util.Objects; import java.util.Objects;
public class B1 public class B1
extends Stage extends Stage {
{ private final B1 thisActionMessageDialog;
private final B1 thisActionMessageDialog; private final TextField nameTF;
private final TextField nameTF; private final CheckBox createColumnCB;
private final CheckBox createColumnCB; private final TextField columnNameTF;
private final TextField columnNameTF; private final TextField relationNameTF;
private final TextField relationNameTF; private final TextField relationNamePraefixTF;
private final TextField relationNamePraefixTF; private final TextField columnPostfixTF;
private final TextField columnPostfixTF; private final TextField datatypeTF;
private final TextField datatypeTF; private final CheckBox isAutoincrementCB;
private final CheckBox isAutoincrementCB; private final CheckBox isKeyCB;
private final CheckBox isKeyCB; private final CheckBox isNullableCB;
private final CheckBox isNullableCB; private final CheckBox isUniqueCB;
private final CheckBox isUniqueCB; private final Button okBTN;
private final Button okBTN; private final String holdName;
private Button cancelBTN; private Button cancelBTN;
private final String holdName;
public B1(final A3 canvas, double xPos, double yPos, String name, boolean createColumn, String columnName, String relationName, String relationNamePraefix, String columnPostfix, String datatype, boolean isAutoincrement, boolean isKey, boolean isNullable, boolean isUnique) {
String title = "Multivalue Attribute Transformation";
this.holdName = name;
this.thisActionMessageDialog = this;
setTitle(title);
initModality(Modality.APPLICATION_MODAL);
this.nameTF = new TextField(name);
this.nameTF.setDisable(true);
this.createColumnCB = new CheckBox();
this.createColumnCB.setSelected(false);
this.createColumnCB.setDisable(true);
if (createColumn) this.createColumnCB.setSelected(true);
this.createColumnCB.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.createColumnCB, C2.MouseSelectedColor));
this.createColumnCB.setOnMouseExited(event -> B1.this.createColumnCB.setEffect(null));
this.columnPostfixTF = new TextField(columnPostfix);
this.columnPostfixTF.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.columnPostfixTF, C2.MouseSelectedColor));
this.columnPostfixTF.setOnMouseExited(event -> B1.this.columnPostfixTF.setEffect(null));
this.columnNameTF = new TextField(columnName);
this.columnNameTF.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.columnNameTF, C2.MouseSelectedColor));
this.columnNameTF.setOnMouseExited(event -> B1.this.columnNameTF.setEffect(null));
this.relationNameTF = new TextField(relationName);
this.relationNameTF.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.relationNameTF, C2.MouseSelectedColor));
this.relationNameTF.setOnMouseExited(event -> B1.this.relationNameTF.setEffect(null));
this.relationNamePraefixTF = new TextField(relationNamePraefix);
this.relationNamePraefixTF.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.relationNamePraefixTF, C2.MouseSelectedColor));
this.relationNamePraefixTF.setOnMouseExited(event -> B1.this.relationNamePraefixTF.setEffect(null));
this.datatypeTF = new TextField(datatype);
this.datatypeTF.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.datatypeTF, C2.MouseSelectedColor));
this.datatypeTF.setOnMouseExited(event -> B1.this.datatypeTF.setEffect(null));
this.isAutoincrementCB = new CheckBox();
this.isAutoincrementCB.setSelected(false);
if (isAutoincrement) this.isAutoincrementCB.setSelected(true);
this.isAutoincrementCB.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.isAutoincrementCB, C2.MouseSelectedColor));
this.isAutoincrementCB.setOnMouseExited(event -> B1.this.isAutoincrementCB.setEffect(null));
this.isKeyCB = new CheckBox();
this.isKeyCB.setSelected(false);
if (isKey) this.isKeyCB.setSelected(true);
this.isKeyCB.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.isKeyCB, C2.MouseSelectedColor));
this.isKeyCB.setOnMouseExited(event -> B1.this.isKeyCB.setEffect(null));
this.isNullableCB = new CheckBox();
this.isNullableCB.setSelected(false);
if (isNullable) this.isNullableCB.setSelected(true);
this.isNullableCB.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.isNullableCB, C2.MouseSelectedColor));
this.isNullableCB.setOnMouseExited(event -> B1.this.isNullableCB.setEffect(null));
this.isUniqueCB = new CheckBox();
this.isUniqueCB.setSelected(false);
if (isUnique) this.isUniqueCB.setSelected(true);
this.isUniqueCB.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.isUniqueCB, C2.MouseSelectedColor));
this.isUniqueCB.setOnMouseExited(event -> B1.this.isUniqueCB.setEffect(null));
this.okBTN = new Button("Ok");
this.okBTN.setBackground(new Background(new BackgroundFill(C2.ButtonBackgroundColor, new CornerRadii(5.0D), Insets.EMPTY)));
this.okBTN.setOnMouseEntered(event -> {
B1.this.getScene().getRoot().setCursor(Cursor.HAND);
T3.fdssdf4354(B1.this.okBTN, C2.MouseSelectedColor);
});
this.okBTN.setOnMouseExited(event -> {
B1.this.getScene().getRoot().setCursor(Cursor.DEFAULT);
B1.this.okBTN.setEffect(null);
if (B1.this.okBTN.isFocused()) T3.fdssdf4354(B1.this.okBTN, C2.FocusOnComponentColor);
});
this.okBTN.focusedProperty().addListener((obs, oldVal, newVal) -> {
if (this.okBTN.isFocused()) {
T3.fdssdf4354(this.okBTN, C2.FocusOnComponentColor);
this.columnPostfixTF.setEffect(null);
this.cancelBTN.setEffect(null);
} else {
this.okBTN.setEffect(null);
}
});
this.okBTN.setOnAction(event -> {
if (!canvas.getTabWithCanvas().getText().contains("*")) canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
B1.this.setDataAndLeave(); public B1(final A3 canvas, double xPos, double yPos, String name, boolean createColumn, String columnName, String relationName, String relationNamePraefix, String columnPostfix, String datatype, boolean isAutoincrement, boolean isKey, boolean isNullable, boolean isUnique) {
}); String title = "Multivalue Attribute Transformation";
this.okBTN.setOnKeyPressed(event -> {
if (Objects.requireNonNull(event.getCode()) == KeyCode.ENTER) {
B1.this.setDataAndLeave();
if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
}
this.holdName = name;
}); this.thisActionMessageDialog = this;
this.cancelBTN = new Button("Cancel"); setTitle(title);
this.cancelBTN.setBackground(new Background(new BackgroundFill(C2.ButtonBackgroundColor, new CornerRadii(5.0D), Insets.EMPTY))); initModality(Modality.APPLICATION_MODAL);
this.cancelBTN.setOnMouseEntered(event -> {
B1.this.getScene().getRoot().setCursor(Cursor.HAND);
T3.fdssdf4354(B1.this.cancelBTN, C2.MouseSelectedColor);
});
this.cancelBTN.setOnMouseExited(event -> {
B1.this.getScene().getRoot().setCursor(Cursor.DEFAULT);
B1.this.cancelBTN.setEffect(null);
if (B1.this.cancelBTN.isFocused()) T3.fdssdf4354(B1.this.cancelBTN, C2.FocusOnComponentColor);
});
this.cancelBTN.focusedProperty().addListener((obs, oldVal, newVal) -> {
if (this.cancelBTN.isFocused()) {
T3.fdssdf4354(this.cancelBTN, C2.FocusOnComponentColor);
this.columnPostfixTF.setEffect(null);
this.okBTN.setEffect(null);
} else {
this.cancelBTN.setEffect(null);
}
});
this.cancelBTN.setOnAction(event -> B1.this.setNothingAndLeave());
this.cancelBTN.setOnKeyPressed(event -> {
if (Objects.requireNonNull(event.getCode()) == KeyCode.ENTER) {
B1.this.setNothingAndLeave();
}
}); this.nameTF = new TextField(name);
if (isKey) { this.nameTF.setDisable(true);
this.isKeyCB.setDisable(true);
this.isUniqueCB.setDisable(true);
this.createColumnCB.setDisable(true);
this.isNullableCB.setDisable(true);
} else {
this.isKeyCB.setDisable(true);
}
GridPane gridPane = new GridPane();
gridPane.setPadding(new Insets(10.0D, 10.0D, 10.0D, 10.0D));
gridPane.setVgap(4.0D);
gridPane.setHgap(4.0D);
gridPane.add(new Label("Name:"), 0, 0);
gridPane.add(this.nameTF, 1, 0);
gridPane.add(new Label("Create column:"), 0, 1);
gridPane.add(this.createColumnCB, 1, 1);
gridPane.add(new Label("Column name:"), 0, 2);
gridPane.add(this.columnNameTF, 1, 2);
gridPane.add(new Label("Relation name:"), 0, 3);
gridPane.add(this.relationNameTF, 1, 3);
gridPane.add(new Label("Relation name praefix:"), 0, 4);
gridPane.add(this.relationNamePraefixTF, 1, 4);
gridPane.add(new Label("Column postfix:"), 0, 5);
gridPane.add(this.columnPostfixTF, 1, 5);
gridPane.add(new Label("Column datatype:"), 0, 6);
gridPane.add(this.datatypeTF, 1, 6);
gridPane.add(new Label("Key:"), 0, 7);
gridPane.add(this.isKeyCB, 1, 7);
gridPane.add(new Label("Autoincrement:"), 0, 8);
gridPane.add(this.isAutoincrementCB, 1, 8);
gridPane.add(new Label("Nullable:"), 0, 9);
gridPane.add(this.isNullableCB, 1, 9);
gridPane.add(new Label("Unique:"), 0, 10);
gridPane.add(this.isUniqueCB, 1, 10);
FlowPane fp = new FlowPane();
fp.setHgap(10.0D);
fp.getChildren().addAll(this.okBTN, this.cancelBTN);
gridPane.add(fp, 0, 11, 2, 1);
Scene scene = new Scene(gridPane, 300.0D, 325.0D);
setScene(scene);
setX(xPos);
setY(yPos);
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) {
setY(yPos - scene.getHeight() - 20.0D);
}
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) {
setX(xPos - scene.getWidth() - 20.0D);
}
this.columnNameTF.requestFocus();
sizeToScene();
showAndWait();
}
private void setDataAndLeave() {
if (this.nameTF.getText() == null || this.nameTF.getText().length() == 0)
return; this.thisActionMessageDialog.close();
}
private void setNothingAndLeave() {
this.nameTF.setText(this.holdName);
this.thisActionMessageDialog.close();
}
public CheckBox getCreateColumnCB() { this.createColumnCB = new CheckBox();
return this.createColumnCB; this.createColumnCB.setSelected(false);
}
this.createColumnCB.setDisable(true);
if (createColumn) this.createColumnCB.setSelected(true);
this.createColumnCB.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.createColumnCB, C2.MouseSelectedColor));
this.createColumnCB.setOnMouseExited(event -> B1.this.createColumnCB.setEffect(null));
public TextField getColumnNameTF() {
return this.columnNameTF; this.columnPostfixTF = new TextField(columnPostfix);
} this.columnPostfixTF.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.columnPostfixTF, C2.MouseSelectedColor));
this.columnPostfixTF.setOnMouseExited(event -> B1.this.columnPostfixTF.setEffect(null));
this.columnNameTF = new TextField(columnName);
this.columnNameTF.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.columnNameTF, C2.MouseSelectedColor));
public TextField getColumnPostfixTF() { this.columnNameTF.setOnMouseExited(event -> B1.this.columnNameTF.setEffect(null));
return this.columnPostfixTF;
} this.relationNameTF = new TextField(relationName);
this.relationNameTF.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.relationNameTF, C2.MouseSelectedColor));
this.relationNameTF.setOnMouseExited(event -> B1.this.relationNameTF.setEffect(null));
this.relationNamePraefixTF = new TextField(relationNamePraefix);
public TextField getDatatypeTF() { this.relationNamePraefixTF.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.relationNamePraefixTF, C2.MouseSelectedColor));
return this.datatypeTF; this.relationNamePraefixTF.setOnMouseExited(event -> B1.this.relationNamePraefixTF.setEffect(null));
}
this.datatypeTF = new TextField(datatype);
this.datatypeTF.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.datatypeTF, C2.MouseSelectedColor));
this.datatypeTF.setOnMouseExited(event -> B1.this.datatypeTF.setEffect(null));
public CheckBox getIsAutoincrementCB() { this.isAutoincrementCB = new CheckBox();
return this.isAutoincrementCB; this.isAutoincrementCB.setSelected(false);
} if (isAutoincrement) this.isAutoincrementCB.setSelected(true);
this.isAutoincrementCB.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.isAutoincrementCB, C2.MouseSelectedColor));
this.isAutoincrementCB.setOnMouseExited(event -> B1.this.isAutoincrementCB.setEffect(null));
this.isKeyCB = new CheckBox();
public CheckBox getIsKeyCB() { this.isKeyCB.setSelected(false);
return this.isKeyCB; if (isKey) this.isKeyCB.setSelected(true);
} this.isKeyCB.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.isKeyCB, C2.MouseSelectedColor));
this.isKeyCB.setOnMouseExited(event -> B1.this.isKeyCB.setEffect(null));
this.isNullableCB = new CheckBox();
this.isNullableCB.setSelected(false);
public CheckBox getIsNullableCB() { if (isNullable) this.isNullableCB.setSelected(true);
return this.isNullableCB; this.isNullableCB.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.isNullableCB, C2.MouseSelectedColor));
} this.isNullableCB.setOnMouseExited(event -> B1.this.isNullableCB.setEffect(null));
this.isUniqueCB = new CheckBox();
this.isUniqueCB.setSelected(false);
if (isUnique) this.isUniqueCB.setSelected(true);
public CheckBox getIsUniqueCB() { this.isUniqueCB.setOnMouseEntered(event -> T3.fdssdf4354(B1.this.isUniqueCB, C2.MouseSelectedColor));
return this.isUniqueCB; this.isUniqueCB.setOnMouseExited(event -> B1.this.isUniqueCB.setEffect(null));
}
this.okBTN = new Button("Ok");
this.okBTN.setBackground(new Background(new BackgroundFill(C2.ButtonBackgroundColor, new CornerRadii(5.0D), Insets.EMPTY)));
this.okBTN.setOnMouseEntered(event -> {
B1.this.getScene().getRoot().setCursor(Cursor.HAND);
public TextField getRelationNameTF() { T3.fdssdf4354(B1.this.okBTN, C2.MouseSelectedColor);
return this.relationNameTF; });
} this.okBTN.setOnMouseExited(event -> {
B1.this.getScene().getRoot().setCursor(Cursor.DEFAULT);
B1.this.okBTN.setEffect(null);
if (B1.this.okBTN.isFocused()) T3.fdssdf4354(B1.this.okBTN, C2.FocusOnComponentColor);
});
public TextField getRelationNamePraefixTF() { this.okBTN.focusedProperty().addListener((obs, oldVal, newVal) -> {
return this.relationNamePraefixTF; if (this.okBTN.isFocused()) {
} T3.fdssdf4354(this.okBTN, C2.FocusOnComponentColor);
}
this.columnPostfixTF.setEffect(null);
this.cancelBTN.setEffect(null);
} else {
this.okBTN.setEffect(null);
}
});
this.okBTN.setOnAction(event -> {
if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
B1.this.setDataAndLeave();
});
this.okBTN.setOnKeyPressed(event -> {
if (Objects.requireNonNull(event.getCode()) == KeyCode.ENTER) {
B1.this.setDataAndLeave();
if (!canvas.getTabWithCanvas().getText().contains("*"))
canvas.getTabWithCanvas().setText(canvas.getTabWithCanvas().getText() + "*");
}
});
this.cancelBTN = new Button("Cancel");
this.cancelBTN.setBackground(new Background(new BackgroundFill(C2.ButtonBackgroundColor, new CornerRadii(5.0D), Insets.EMPTY)));
this.cancelBTN.setOnMouseEntered(event -> {
B1.this.getScene().getRoot().setCursor(Cursor.HAND);
T3.fdssdf4354(B1.this.cancelBTN, C2.MouseSelectedColor);
});
this.cancelBTN.setOnMouseExited(event -> {
B1.this.getScene().getRoot().setCursor(Cursor.DEFAULT);
B1.this.cancelBTN.setEffect(null);
if (B1.this.cancelBTN.isFocused()) T3.fdssdf4354(B1.this.cancelBTN, C2.FocusOnComponentColor);
});
this.cancelBTN.focusedProperty().addListener((obs, oldVal, newVal) -> {
if (this.cancelBTN.isFocused()) {
T3.fdssdf4354(this.cancelBTN, C2.FocusOnComponentColor);
this.columnPostfixTF.setEffect(null);
this.okBTN.setEffect(null);
} else {
this.cancelBTN.setEffect(null);
}
});
this.cancelBTN.setOnAction(event -> B1.this.setNothingAndLeave());
this.cancelBTN.setOnKeyPressed(event -> {
if (Objects.requireNonNull(event.getCode()) == KeyCode.ENTER) {
B1.this.setNothingAndLeave();
}
});
if (isKey) {
this.isKeyCB.setDisable(true);
this.isUniqueCB.setDisable(true);
this.createColumnCB.setDisable(true);
this.isNullableCB.setDisable(true);
} else {
this.isKeyCB.setDisable(true);
}
GridPane gridPane = new GridPane();
gridPane.setPadding(new Insets(10.0D, 10.0D, 10.0D, 10.0D));
gridPane.setVgap(4.0D);
gridPane.setHgap(4.0D);
gridPane.add(new Label("Name:"), 0, 0);
gridPane.add(this.nameTF, 1, 0);
gridPane.add(new Label("Create column:"), 0, 1);
gridPane.add(this.createColumnCB, 1, 1);
gridPane.add(new Label("Column name:"), 0, 2);
gridPane.add(this.columnNameTF, 1, 2);
gridPane.add(new Label("Relation name:"), 0, 3);
gridPane.add(this.relationNameTF, 1, 3);
gridPane.add(new Label("Relation name praefix:"), 0, 4);
gridPane.add(this.relationNamePraefixTF, 1, 4);
gridPane.add(new Label("Column postfix:"), 0, 5);
gridPane.add(this.columnPostfixTF, 1, 5);
gridPane.add(new Label("Column datatype:"), 0, 6);
gridPane.add(this.datatypeTF, 1, 6);
gridPane.add(new Label("Key:"), 0, 7);
gridPane.add(this.isKeyCB, 1, 7);
gridPane.add(new Label("Autoincrement:"), 0, 8);
gridPane.add(this.isAutoincrementCB, 1, 8);
gridPane.add(new Label("Nullable:"), 0, 9);
gridPane.add(this.isNullableCB, 1, 9);
gridPane.add(new Label("Unique:"), 0, 10);
gridPane.add(this.isUniqueCB, 1, 10);
FlowPane fp = new FlowPane();
fp.setHgap(10.0D);
fp.getChildren().addAll(this.okBTN, this.cancelBTN);
gridPane.add(fp, 0, 11, 2, 1);
Scene scene = new Scene(gridPane, 300.0D, 325.0D);
setScene(scene);
setX(xPos);
setY(yPos);
if (yPos + scene.getHeight() > canvas.getView().getHeight() - 5.0D) {
setY(yPos - scene.getHeight() - 20.0D);
}
if (xPos + scene.getWidth() > canvas.getView().getWidth() - 5.0D) {
setX(xPos - scene.getWidth() - 20.0D);
}
this.columnNameTF.requestFocus();
sizeToScene();
showAndWait();
}
private void setDataAndLeave() {
if (this.nameTF.getText() == null || this.nameTF.getText().length() == 0)
return;
this.thisActionMessageDialog.close();
}
private void setNothingAndLeave() {
this.nameTF.setText(this.holdName);
this.thisActionMessageDialog.close();
}
public CheckBox getCreateColumnCB() {
return this.createColumnCB;
}
public TextField getColumnNameTF() {
return this.columnNameTF;
}
public TextField getColumnPostfixTF() {
return this.columnPostfixTF;
}
public TextField getDatatypeTF() {
return this.datatypeTF;
}
public CheckBox getIsAutoincrementCB() {
return this.isAutoincrementCB;
}
public CheckBox getIsKeyCB() {
return this.isKeyCB;
}
public CheckBox getIsNullableCB() {
return this.isNullableCB;
}
public CheckBox getIsUniqueCB() {
return this.isUniqueCB;
}
public TextField getRelationNameTF() {
return this.relationNameTF;
}
public TextField getRelationNamePraefixTF() {
return this.relationNamePraefixTF;
}
}

File diff suppressed because it is too large Load Diff

View File

@ -1,157 +1,141 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import javafx.event.Event; import javafx.event.Event;
import javafx.geometry.Insets; import javafx.geometry.Insets;
import javafx.scene.Cursor; import javafx.scene.Cursor;
import javafx.scene.control.Alert; import javafx.scene.control.Alert;
import javafx.scene.control.Button; import javafx.scene.control.Button;
import javafx.scene.control.ButtonType; import javafx.scene.control.ButtonType;
import javafx.scene.control.Label; import javafx.scene.control.Label;
import javafx.scene.image.Image; import javafx.scene.image.Image;
import javafx.scene.layout.Background; import javafx.scene.layout.Background;
import javafx.scene.layout.BackgroundFill; import javafx.scene.layout.BackgroundFill;
import javafx.scene.layout.CornerRadii; import javafx.scene.layout.CornerRadii;
import javafx.scene.layout.StackPane; import javafx.scene.layout.StackPane;
import javafx.scene.paint.Color; import javafx.scene.paint.Color;
import javafx.stage.Stage; import javafx.stage.Stage;
import javafx.stage.StageStyle; import javafx.stage.StageStyle;
import javafx.stage.Window; import javafx.stage.Window;
import java.util.Optional;
public class C1
{
private Optional<ButtonType> result;
public C1(Window window, Alert.AlertType alertType, String title, String header, String contentText, Boolean showAndWait, Image image, String okBtnText, String cancelBtnText, Color btnBackgroundColor, Color btnSelectedColor, Color btnFocusColor) { import java.util.Optional;
Alert alert = setAlert(window, alertType, title, header, contentText, image);
Button button = (Button)alert.getDialogPane().lookupButton(ButtonType.OK); public class C1 {
if (button != null) { private Optional<ButtonType> result;
setButtonLookAndFeel(button, okBtnText, btnBackgroundColor, btnSelectedColor, btnFocusColor);
}
button = (Button)alert.getDialogPane().lookupButton(ButtonType.CANCEL);
if (button != null) setButtonLookAndFeel(button, cancelBtnText, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button)alert.getDialogPane().lookupButton(ButtonType.APPLY);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button)alert.getDialogPane().lookupButton(ButtonType.CLOSE);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button)alert.getDialogPane().lookupButton(ButtonType.FINISH);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button)alert.getDialogPane().lookupButton(ButtonType.NEXT);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button)alert.getDialogPane().lookupButton(ButtonType.NO);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button)alert.getDialogPane().lookupButton(ButtonType.PREVIOUS);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button)alert.getDialogPane().lookupButton(ButtonType.YES);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
if (showAndWait) {
this.result = alert.showAndWait();
} else {
alert.show();
}
}
private void setButtonLookAndFeel(final Button button, String buttonText, Color btnBackgroundColor, final Color btnSelectedColor, final Color btnFocusColor) { public C1(Window window, Alert.AlertType alertType, String title, String header, String contentText, Boolean showAndWait, Image image, String okBtnText, String cancelBtnText, Color btnBackgroundColor, Color btnSelectedColor, Color btnFocusColor) {
button.setBackground(new Background(new BackgroundFill(btnBackgroundColor, new CornerRadii(5.0D), Insets.EMPTY))); Alert alert = setAlert(window, alertType, title, header, contentText, image);
button.setOnMouseEntered(event -> {
button.getScene().getRoot().setCursor(Cursor.HAND);
T3.fdssdf4354(button, btnSelectedColor);
});
button.setOnMouseExited(event -> {
button.getScene().getRoot().setCursor(Cursor.DEFAULT);
button.setEffect(null);
if (button.isFocused()) {
T3.fdssdf4354(button, btnFocusColor);
} else {
button.setEffect(null); Button button = (Button) alert.getDialogPane().lookupButton(ButtonType.OK);
} if (button != null) {
}); setButtonLookAndFeel(button, okBtnText, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button.focusedProperty().addListener((obs, oldVal, newVal) -> { }
if (button.isFocused()) {
T3.fdssdf4354(button, btnSelectedColor); button = (Button) alert.getDialogPane().lookupButton(ButtonType.CANCEL);
} else { if (button != null)
button.setEffect(null); setButtonLookAndFeel(button, cancelBtnText, btnBackgroundColor, btnSelectedColor, btnFocusColor);
}
}); button = (Button) alert.getDialogPane().lookupButton(ButtonType.APPLY);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
if (buttonText != null) button.setText(buttonText); button = (Button) alert.getDialogPane().lookupButton(ButtonType.CLOSE);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
}
button = (Button) alert.getDialogPane().lookupButton(ButtonType.FINISH);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button) alert.getDialogPane().lookupButton(ButtonType.NEXT);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button) alert.getDialogPane().lookupButton(ButtonType.NO);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button) alert.getDialogPane().lookupButton(ButtonType.PREVIOUS);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
button = (Button) alert.getDialogPane().lookupButton(ButtonType.YES);
if (button != null) setButtonLookAndFeel(button, null, btnBackgroundColor, btnSelectedColor, btnFocusColor);
private Alert setAlert(Window window, Alert.AlertType alertType, String title, String header, String contentText, Image image) {
Alert alert = new Alert(alertType); if (showAndWait) {
alert.setTitle(title); this.result = alert.showAndWait();
alert.setHeaderText(header); } else {
alert.setContentText(contentText); alert.show();
alert.initOwner(window); }
alert.initStyle(StageStyle.DECORATED); }
private void setButtonLookAndFeel(final Button button, String buttonText, Color btnBackgroundColor, final Color btnSelectedColor, final Color btnFocusColor) {
StackPane iv = switch (alertType) { button.setBackground(new Background(new BackgroundFill(btnBackgroundColor, new CornerRadii(5.0D), Insets.EMPTY)));
case ERROR -> button.setOnMouseEntered(event -> {
C2.alerterror; button.getScene().getRoot().setCursor(Cursor.HAND);
case INFORMATION -> T3.fdssdf4354(button, btnSelectedColor);
C2.alertinformation; });
default -> button.setOnMouseExited(event -> {
C2.alertconfirmation; button.getScene().getRoot().setCursor(Cursor.DEFAULT);
}; button.setEffect(null);
alert.setGraphic(iv); if (button.isFocused()) {
T3.fdssdf4354(button, btnFocusColor);
alert.getDialogPane().getChildren().stream().filter(node -> node instanceof Label).forEach(node -> ((Label)node).setMinHeight(Double.NEGATIVE_INFINITY)); } else {
alert.getDialogPane().getChildren().stream().filter(node -> node instanceof Label).forEach(node -> ((Label)node).setMinWidth(Double.NEGATIVE_INFINITY));
alert.getDialogPane().getChildren().stream().filter(node -> node instanceof Label).forEach(node -> ((Label)node).setMaxWidth(Double.NEGATIVE_INFINITY)); button.setEffect(null);
}
alert.getDialogPane().setBackground(new Background(new BackgroundFill(Color.GAINSBORO, CornerRadii.EMPTY, Insets.EMPTY))); });
button.focusedProperty().addListener((obs, oldVal, newVal) -> {
Stage stage = (Stage)alert.getDialogPane().getScene().getWindow(); if (button.isFocused()) {
T3.fdssdf4354(button, btnSelectedColor);
} else {
if (image != null) { button.setEffect(null);
stage.getIcons().add(image); }
} });
stage.setOnCloseRequest(Event::consume); if (buttonText != null) button.setText(buttonText);
}
stage.centerOnScreen();
stage.setAlwaysOnTop(true); private Alert setAlert(Window window, Alert.AlertType alertType, String title, String header, String contentText, Image image) {
Alert alert = new Alert(alertType);
return alert; alert.setTitle(title);
} alert.setHeaderText(header);
alert.setContentText(contentText);
alert.initOwner(window);
alert.initStyle(StageStyle.DECORATED);
public Optional<ButtonType> getResult() {
return this.result; StackPane iv = switch (alertType) {
} case ERROR -> C2.alerterror;
} case INFORMATION -> C2.alertinformation;
default -> C2.alertconfirmation;
};
alert.setGraphic(iv);
alert.getDialogPane().getChildren().stream().filter(node -> node instanceof Label).forEach(node -> ((Label) node).setMinHeight(Double.NEGATIVE_INFINITY));
alert.getDialogPane().getChildren().stream().filter(node -> node instanceof Label).forEach(node -> ((Label) node).setMinWidth(Double.NEGATIVE_INFINITY));
alert.getDialogPane().getChildren().stream().filter(node -> node instanceof Label).forEach(node -> ((Label) node).setMaxWidth(Double.NEGATIVE_INFINITY));
alert.getDialogPane().setBackground(new Background(new BackgroundFill(Color.GAINSBORO, CornerRadii.EMPTY, Insets.EMPTY)));
Stage stage = (Stage) alert.getDialogPane().getScene().getWindow();
if (image != null) {
stage.getIcons().add(image);
}
stage.setOnCloseRequest(Event::consume);
stage.centerOnScreen();
stage.setAlwaysOnTop(true);
return alert;
}
public Optional<ButtonType> getResult() {
return this.result;
}
}

View File

@ -1,170 +1,166 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import java.io.BufferedReader;
import java.io.InputStream;
import java.util.HashMap;
import java.util.Objects;
import javafx.geometry.Insets; import javafx.geometry.Insets;
import javafx.scene.image.Image; import javafx.scene.image.Image;
import javafx.scene.layout.Background; import javafx.scene.layout.Background;
import javafx.scene.layout.BackgroundFill; import javafx.scene.layout.BackgroundFill;
import javafx.scene.layout.CornerRadii; import javafx.scene.layout.CornerRadii;
import javafx.scene.layout.StackPane; import javafx.scene.layout.StackPane;
import javafx.scene.paint.Color; import javafx.scene.paint.Color;
import javafx.scene.text.Font; import javafx.scene.text.Font;
import javafx.scene.text.FontWeight; import javafx.scene.text.FontWeight;
import javafx.scene.text.Text; import javafx.scene.text.Text;
public class C2
{
public static final Color MouseSelectedColor = Color.RED;
public static final Color FocusOnComponentColor = Color.BLUE;
public static final Color ButtonBackgroundColor = Color.rgb(179,179,179);
public static final Color ERMDockablePointColor = Color.rgb(236, 234, 241);
public static final Color ERMTextBorderColor = Color.GREY;
public static Font ERMFont = Font.font(null, FontWeight.BOLD, 12.0D);
public static Color ERMBackgroundColor = Color.rgb(27, 27, 30);
public static Color ERMForegroundColor = Color.rgb(48, 48, 52);
public static Color ERMTextColor = Color.rgb(236, 234, 241); import java.io.BufferedReader;
import java.io.InputStream;
import java.util.HashMap;
import java.util.Objects;
public static Background AppBackground = new Background(new BackgroundFill(C2.ERMBackgroundColor, CornerRadii.EMPTY, Insets.EMPTY)); public class C2 {
public static Background AppForeground = new Background(new BackgroundFill(C2.ERMForegroundColor, CornerRadii.EMPTY, Insets.EMPTY)); public static final Color MouseSelectedColor = Color.RED;
public static final Color FocusOnComponentColor = Color.BLUE;
public static final Color ButtonBackgroundColor = Color.rgb(179, 179, 179);
public static final Color ERMDockablePointColor = Color.rgb(236, 234, 241);
public static final Color ERMTextBorderColor = Color.GREY;
public static Font ERMFont = Font.font(null, FontWeight.BOLD, 12.0D);
public static Color ERMBackgroundColor = Color.rgb(27, 27, 30);
public static Color ERMForegroundColor = Color.rgb(48, 48, 52);
public static Color ERMTextColor = Color.rgb(236, 234, 241);
public static Background AppBackground = new Background(new BackgroundFill(C2.ERMBackgroundColor, CornerRadii.EMPTY, Insets.EMPTY));
public static Background AppForeground = new Background(new BackgroundFill(C2.ERMForegroundColor, CornerRadii.EMPTY, Insets.EMPTY));
public static StackPane alerterror = new StackPane(); public static StackPane alerterror = new StackPane();
public static StackPane alertconfirmation = new StackPane(); public static StackPane alertconfirmation = new StackPane();
public static StackPane alertinformation = new StackPane(); public static StackPane alertinformation = new StackPane();
public static Color ERMSelectedColor = Color.RED; public static Color ERMSelectedColor = Color.RED;
public static Color ERMESColor = Color.rgb(0,255,0);
public static Color ERMRSColor = Color.AQUA; public static Color ERMESColor = Color.rgb(0, 255, 0);
public static Color ERMRSConnColor = Color.AQUA;
public static Color ERMRSISAColor = Color.BLUEVIOLET;
public static Color ERMISAConnGENERAL = Color.BLUEVIOLET;
public static Color ERMISAConnSPEC = Color.AQUA;
public static Color ERMATTRColor = Color.GREENYELLOW; public static Color ERMRSColor = Color.AQUA;
public static Color ERMRSConnColor = Color.AQUA;
public static Color ERMLINEColor = Color.CHARTREUSE; public static Color ERMRSISAColor = Color.BLUEVIOLET;
public static Color ERMISAConnGENERAL = Color.BLUEVIOLET;
public static Color TEMPLINEColor = Color.PALEGREEN; public static Color ERMISAConnSPEC = Color.AQUA;
public static Image applicationImageIconAsICO;
public static int imageWidth = 55;
public static int imageHeight = 32;
public static Image treeCloseImage;
public static Image treeOpenImage;
public static Image attr_conn_attrImage;
public static Image attr_conn_esImage;
public static Image attr_conn_rsImage;
public static Image attr_derived_multi_valueImage;
public static Image attr_derived_one_valueImage;
public static Image attr_key_valueImage;
public static Image attr_multi_valueImage;
public static Image attr_one_valueImage;
public static Image attr_weak_key_valueImage;
public static Image es_associativeImage;
public static Image es_weakImage;
public static Image esImage;
public static Image rs_conn_esImage;
public static Image rs_id_conn_es_weakImage;
public static Image rs_id_conn_esImage;
public static Image rs_idImage;
public static Image rs_isa_conn_general_esImage;
public static Image rs_isa_conn_special_esImage;
public static Image rs_isaImage;
public static Image rsImage;
public static Image textImage;
public static Image textWithoutBorderImage;
public static HashMap<String, InputStream> randomDataFiles = new HashMap<>();
public static HashMap<String, BufferedReader> randomDataFilesExtern = new HashMap<>();
public C2() {
alerterror.getStyleClass().add("alert.error.dialog-pane"); public static Color ERMATTRColor = Color.GREENYELLOW;
alertinformation.getStyleClass().add("alert.error.dialog-pane");
alertconfirmation.getStyleClass().add("alert.error.dialog-pane"); public static Color ERMLINEColor = Color.CHARTREUSE;
public static Color TEMPLINEColor = Color.PALEGREEN;
String appImages = "/applicationimages/"; public static Image applicationImageIconAsICO;
String appData = "/data/";
randomDataFiles.put("Random Color", getClass().getResourceAsStream(appData+"colors.txt")); public static int imageWidth = 55;
randomDataFiles.put("Random Company", getClass().getResourceAsStream(appData+"companies.txt")); public static int imageHeight = 32;
randomDataFiles.put("Random Country", getClass().getResourceAsStream(appData+"countries.txt"));
randomDataFiles.put("Random Departmentname", getClass().getResourceAsStream(appData+"departmentnames.txt"));
randomDataFiles.put("Random Firstname", getClass().getResourceAsStream(appData+"firstnames.txt"));
randomDataFiles.put("Random Jobname", getClass().getResourceAsStream(appData+"jobnames.txt"));
randomDataFiles.put("Random Language", getClass().getResourceAsStream(appData+"languages.txt"));
randomDataFiles.put("Random Lastname", getClass().getResourceAsStream(appData+"lastnames.txt"));
randomDataFiles.put("Random Mediacategory", getClass().getResourceAsStream(appData+"mediacategories.txt"));
randomDataFiles.put("Random Mediapublisher", getClass().getResourceAsStream(appData+"mediapublishers.txt"));
randomDataFiles.put("Random Mediatitle", getClass().getResourceAsStream(appData+"mediatitles.txt"));
randomDataFiles.put("Random Mediatype", getClass().getResourceAsStream(appData+"mediatypes.txt"));
randomDataFiles.put("Random Place", getClass().getResourceAsStream(appData+"places.txt"));
randomDataFiles.put("Random Profession", getClass().getResourceAsStream(appData+"professions.txt"));
randomDataFiles.put("Random Rentalequipment", getClass().getResourceAsStream(appData+"rentalequipment.txt"));
randomDataFiles.put("Random Street", getClass().getResourceAsStream(appData+"streets.txt"));
applicationImageIconAsICO = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"erdlogo.png")));
attr_conn_attrImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"attr_conn_attr.png")));
attr_conn_esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"attr_conn_es.png")));
attr_conn_rsImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"attr_conn_rs.png")));
attr_derived_multi_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"attr_derived_multi_value.png")));
attr_derived_one_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"attr_derived_one_value.png")));
attr_key_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"attr_key_value.png")));
attr_multi_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"attr_multi_value.png")));
attr_one_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"attr_one_value.png")));
attr_weak_key_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"attr_weak_key_value.png")));
es_associativeImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"es_associative.png")));
es_weakImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"es_weak.png")));
esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"es.png")));
rs_conn_esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"rs_conn_es.png")));
rs_id_conn_es_weakImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"rs_id_conn_es_weak.png")));
rs_id_conn_esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"rs_id_conn_es.png")));
rs_idImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"rs_id.png")));
rs_isa_conn_general_esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"rs_isa_conn_general_es.png")));
rs_isa_conn_special_esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"rs_isa_conn_special_es.png")));
rs_isaImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"rs_isa.png")));
rsImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"rs.png")));
textImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"text.png")));
textWithoutBorderImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"text_without_border.png")));
treeOpenImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"tree_open.png")));
treeCloseImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages+"tree_close.png")));
}
public static double computeTextWidth(String text, double wrappingWidth) { public static Image treeCloseImage;
Text helper = new Text();
helper.setFont(ERMFont); public static Image treeOpenImage;
helper.setText(text);
public static Image attr_conn_attrImage;
helper.setWrappingWidth(0.0D); public static Image attr_conn_esImage;
helper.setLineSpacing(0.0D); public static Image attr_conn_rsImage;
double w = Math.min(helper.prefWidth(-1.0D), wrappingWidth); public static Image attr_derived_multi_valueImage;
helper.setWrappingWidth(Math.ceil(w)); public static Image attr_derived_one_valueImage;
return Math.ceil(helper.getLayoutBounds().getWidth()); public static Image attr_key_valueImage;
} public static Image attr_multi_valueImage;
public static Image attr_one_valueImage;
public static double computeTextHeight() { public static Image attr_weak_key_valueImage;
return ERMFont.getSize(); public static Image es_associativeImage;
} public static Image es_weakImage;
} public static Image esImage;
public static Image rs_conn_esImage;
public static Image rs_id_conn_es_weakImage;
public static Image rs_id_conn_esImage;
public static Image rs_idImage;
public static Image rs_isa_conn_general_esImage;
public static Image rs_isa_conn_special_esImage;
public static Image rs_isaImage;
public static Image rsImage;
public static Image textImage;
public static Image textWithoutBorderImage;
public static HashMap<String, InputStream> randomDataFiles = new HashMap<>();
public static HashMap<String, BufferedReader> randomDataFilesExtern = new HashMap<>();
public C2() {
alerterror.getStyleClass().add("alert.error.dialog-pane");
alertinformation.getStyleClass().add("alert.error.dialog-pane");
alertconfirmation.getStyleClass().add("alert.error.dialog-pane");
String appImages = "/applicationimages/";
String appData = "/data/";
randomDataFiles.put("Random Color", getClass().getResourceAsStream(appData + "colors.txt"));
randomDataFiles.put("Random Company", getClass().getResourceAsStream(appData + "companies.txt"));
randomDataFiles.put("Random Country", getClass().getResourceAsStream(appData + "countries.txt"));
randomDataFiles.put("Random Departmentname", getClass().getResourceAsStream(appData + "departmentnames.txt"));
randomDataFiles.put("Random Firstname", getClass().getResourceAsStream(appData + "firstnames.txt"));
randomDataFiles.put("Random Jobname", getClass().getResourceAsStream(appData + "jobnames.txt"));
randomDataFiles.put("Random Language", getClass().getResourceAsStream(appData + "languages.txt"));
randomDataFiles.put("Random Lastname", getClass().getResourceAsStream(appData + "lastnames.txt"));
randomDataFiles.put("Random Mediacategory", getClass().getResourceAsStream(appData + "mediacategories.txt"));
randomDataFiles.put("Random Mediapublisher", getClass().getResourceAsStream(appData + "mediapublishers.txt"));
randomDataFiles.put("Random Mediatitle", getClass().getResourceAsStream(appData + "mediatitles.txt"));
randomDataFiles.put("Random Mediatype", getClass().getResourceAsStream(appData + "mediatypes.txt"));
randomDataFiles.put("Random Place", getClass().getResourceAsStream(appData + "places.txt"));
randomDataFiles.put("Random Profession", getClass().getResourceAsStream(appData + "professions.txt"));
randomDataFiles.put("Random Rentalequipment", getClass().getResourceAsStream(appData + "rentalequipment.txt"));
randomDataFiles.put("Random Street", getClass().getResourceAsStream(appData + "streets.txt"));
applicationImageIconAsICO = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "erdlogo.png")));
attr_conn_attrImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "attr_conn_attr.png")));
attr_conn_esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "attr_conn_es.png")));
attr_conn_rsImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "attr_conn_rs.png")));
attr_derived_multi_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "attr_derived_multi_value.png")));
attr_derived_one_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "attr_derived_one_value.png")));
attr_key_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "attr_key_value.png")));
attr_multi_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "attr_multi_value.png")));
attr_one_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "attr_one_value.png")));
attr_weak_key_valueImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "attr_weak_key_value.png")));
es_associativeImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "es_associative.png")));
es_weakImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "es_weak.png")));
esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "es.png")));
rs_conn_esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "rs_conn_es.png")));
rs_id_conn_es_weakImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "rs_id_conn_es_weak.png")));
rs_id_conn_esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "rs_id_conn_es.png")));
rs_idImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "rs_id.png")));
rs_isa_conn_general_esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "rs_isa_conn_general_es.png")));
rs_isa_conn_special_esImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "rs_isa_conn_special_es.png")));
rs_isaImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "rs_isa.png")));
rsImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "rs.png")));
textImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "text.png")));
textWithoutBorderImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "text_without_border.png")));
treeOpenImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "tree_open.png")));
treeCloseImage = new Image(Objects.requireNonNull(getClass().getResourceAsStream(appImages + "tree_close.png")));
}
public static double computeTextWidth(String text, double wrappingWidth) {
Text helper = new Text();
helper.setFont(ERMFont);
helper.setText(text);
helper.setWrappingWidth(0.0D);
helper.setLineSpacing(0.0D);
double w = Math.min(helper.prefWidth(-1.0D), wrappingWidth);
helper.setWrappingWidth(Math.ceil(w));
return Math.ceil(helper.getLayoutBounds().getWidth());
}
public static double computeTextHeight() {
return ERMFont.getSize();
}
}

View File

@ -1,151 +1,120 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
public class C3
implements Comparable<C3> public class C3
{ implements Comparable<C3> {
private final String columnName; private final String columnName;
private String datatype; protected String dataGenerationType;
private boolean isKey; protected String par1;
private boolean isNullable; protected String par2;
private boolean isUnique; private String datatype;
private boolean isAutoincrement; private boolean isKey;
private long autoincrementStartAt; private boolean isNullable;
private T2 referencesTo; private boolean isUnique;
private long referstoGraphicalElement; private boolean isAutoincrement;
protected String dataGenerationType; private long autoincrementStartAt;
protected String par1; private T2 referencesTo;
protected String par2; private long referstoGraphicalElement;
public C3(String columnName, String datatype, boolean isKey, boolean isNullable, boolean isUnique, boolean isAutoincrement, long autoincrementStartAt, T2 referencesTo, long referstoGraphicalElement, String dataGenerationType, String par1, String par2) { public C3(String columnName, String datatype, boolean isKey, boolean isNullable, boolean isUnique, boolean isAutoincrement, long autoincrementStartAt, T2 referencesTo, long referstoGraphicalElement, String dataGenerationType, String par1, String par2) {
this.columnName = columnName; this.columnName = columnName;
this.datatype = datatype; this.datatype = datatype;
this.isKey = isKey; this.isKey = isKey;
this.isNullable = isNullable; this.isNullable = isNullable;
this.isUnique = isUnique; this.isUnique = isUnique;
this.isAutoincrement = isAutoincrement; this.isAutoincrement = isAutoincrement;
this.autoincrementStartAt = autoincrementStartAt; this.autoincrementStartAt = autoincrementStartAt;
this.referencesTo = referencesTo; this.referencesTo = referencesTo;
this.referstoGraphicalElement = referstoGraphicalElement; this.referstoGraphicalElement = referstoGraphicalElement;
this.dataGenerationType = dataGenerationType; this.dataGenerationType = dataGenerationType;
this.par1 = par1; this.par1 = par1;
this.par2 = par2; this.par2 = par2;
} }
public C3(String columnName) {
this.columnName = columnName;
}
public String getColumnName() {
return this.columnName;
}
public String getDatatype() { public C3(String columnName) {
return this.datatype; this.columnName = columnName;
} }
public boolean isKey() { public String getColumnName() {
return this.isKey; return this.columnName;
} }
public boolean isNullable() { public String getDatatype() {
return this.isNullable; return this.datatype;
} }
public boolean isUnique() { public boolean isKey() {
return this.isUnique; return this.isKey;
} }
public boolean isAutoincrement() { public boolean isNullable() {
return this.isAutoincrement; return this.isNullable;
} }
public long getAutoincrementStartAt() { public boolean isUnique() {
return this.autoincrementStartAt; return this.isUnique;
} }
public T2 getReferencesTo() { public boolean isAutoincrement() {
return this.referencesTo; return this.isAutoincrement;
} }
public int hashCode() { public long getAutoincrementStartAt() {
int result = 1; return this.autoincrementStartAt;
result = 31 * result + ((this.columnName == null) ? 0 : this.columnName.hashCode()); }
return result;
}
public T2 getReferencesTo() {
return this.referencesTo;
}
public boolean equals(Object obj) {
if (this == obj) public int hashCode() {
return true; int result = 1;
if (obj == null) result = 31 * result + ((this.columnName == null) ? 0 : this.columnName.hashCode());
return false; return result;
if (getClass() != obj.getClass()) }
return false;
C3 other = (C3)obj;
if (this.columnName == null) { public boolean equals(Object obj) {
return other.columnName == null; if (this == obj)
} else return this.columnName.equals(other.columnName); return true;
} if (obj == null)
return false;
if (getClass() != obj.getClass())
return false;
C3 other = (C3) obj;
public String toString() { if (this.columnName == null) {
return "RM_Column [columnName=" + this.columnName + ", datatype=" + this.datatype + ", isKey=" + this.isKey + ", isNullable=" + return other.columnName == null;
this.isNullable + ", isUnique=" + this.isUnique + ", isAutoincrement=" + this.isAutoincrement + ", referencesTo=" + } else return this.columnName.equals(other.columnName);
this.referencesTo + ", referstoGraphicalElement=" + this.referstoGraphicalElement + ", dataGenerationType=" + }
this.dataGenerationType + ", par1=" + this.par1 + ", par2=" + this.par2 + "]";
}
public String toString() {
return "RM_Column [columnName=" + this.columnName + ", datatype=" + this.datatype + ", isKey=" + this.isKey + ", isNullable=" +
this.isNullable + ", isUnique=" + this.isUnique + ", isAutoincrement=" + this.isAutoincrement + ", referencesTo=" +
this.referencesTo + ", referstoGraphicalElement=" + this.referstoGraphicalElement + ", dataGenerationType=" +
public int compareTo(C3 o) { this.dataGenerationType + ", par1=" + this.par1 + ", par2=" + this.par2 + "]";
if (this.isKey && !o.isKey) return -1; }
if (!this.isKey && o.isKey) return 1;
return 0;
} public int compareTo(C3 o) {
if (this.isKey && !o.isKey) return -1;
if (!this.isKey && o.isKey) return 1;
return 0;
}
public long getReferstoGraphicalElement() {
return this.referstoGraphicalElement; public long getReferstoGraphicalElement() {
} return this.referstoGraphicalElement;
} }
}

File diff suppressed because it is too large Load Diff

View File

@ -7,390 +7,253 @@ import java.io.Serial;
public abstract class Graphic_ATTR_Elem public abstract class Graphic_ATTR_Elem
extends Graphic_Figure_Elem extends Graphic_Figure_Elem
implements U2 implements U2 {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L; protected boolean createColumn;
protected boolean createColumn; protected String columnPostfix;
protected String columnPostfix; protected String columnName;
protected String columnName; protected String mvRelationname;
protected String mvRelationname; protected String mvRelationnamePraefix;
protected String mvRelationnamePraefix; protected String datatype;
protected String datatype; protected boolean isKey;
protected boolean isKey; protected boolean isAutoincrement;
protected boolean isAutoincrement; protected long autoincrementStartAt;
protected long autoincrementStartAt; protected boolean isNullable;
protected boolean isNullable; protected boolean isUnique;
protected boolean isUnique; protected String dataGenerationType;
protected String dataGenerationType; protected String par1;
protected String par1; protected String par2;
protected String par2; protected String par1_label;
protected String par1_label; protected String par2_label;
protected String par2_label;
public Graphic_ATTR_Elem(GraphicsContext gc, double x, double y, String name, long elementID) {
super(gc, name, elementID);
this.xPos = x;
this.yPos = y;
this.createColumn = true;
this.columnName = T3.replaceSpecialChars(this.name.toLowerCase());
if (this instanceof Graphic_ATTR_Multi_Elem) {
this.mvRelationname = this.columnName + "_mvt";
this.mvRelationnamePraefix = this.mvRelationname.charAt(0) + "_";
this.createColumn = false;
}
this.columnPostfix = "";
this.datatype = "varchar(100)";
this.isAutoincrement = false;
this.isKey = this instanceof Graphic_ATTR_Key_Elem || this instanceof Graphic_ATTR_Weak_Key_Elem; public Graphic_ATTR_Elem(GraphicsContext gc, double x, double y, String name, long elementID) {
if (this.isKey) this.isNullable = false; super(gc, name, elementID);
this.isUnique = false;
this.dataGenerationType = "No";
}
this.xPos = x;
this.yPos = y;
this.createColumn = true;
this.columnName = T3.replaceSpecialChars(this.name.toLowerCase());
if (this instanceof Graphic_ATTR_Multi_Elem) {
this.mvRelationname = this.columnName + "_mvt";
this.mvRelationnamePraefix = this.mvRelationname.charAt(0) + "_";
this.createColumn = false;
}
this.columnPostfix = "";
this.datatype = "varchar(100)";
this.isAutoincrement = false;
this.isKey = this instanceof Graphic_ATTR_Key_Elem || this instanceof Graphic_ATTR_Weak_Key_Elem;
if (this.isKey) this.isNullable = false;
this.isUnique = false;
this.dataGenerationType = "No";
}
protected void changeName(String name) {
super.changeName(name);
protected void changeName(String name) {
super.changeName(name);
this.createColumn = true;
this.createColumn = true; this.columnName = T3.replaceSpecialChars(name.toLowerCase());
this.columnName = T3.replaceSpecialChars(name.toLowerCase()); if (this instanceof Graphic_ATTR_Multi_Elem) {
if (this instanceof Graphic_ATTR_Multi_Elem) { this.createColumn = false;
this.createColumn = false; this.mvRelationname = this.columnName + "_mvt";
this.mvRelationname = this.columnName + "_mvt"; this.mvRelationnamePraefix = this.mvRelationname.charAt(0) + "_";
this.mvRelationnamePraefix = this.mvRelationname.charAt(0) + "_"; }
} this.columnPostfix = "";
this.columnPostfix = ""; this.datatype = "varchar(100)";
this.datatype = "varchar(100)"; this.isAutoincrement = false;
this.isAutoincrement = false; this.isKey = this instanceof Graphic_ATTR_Key_Elem || this instanceof Graphic_ATTR_Weak_Key_Elem;
this.isKey = this instanceof Graphic_ATTR_Key_Elem || this instanceof Graphic_ATTR_Weak_Key_Elem; if (this.isKey) this.isNullable = false;
if (this.isKey) this.isNullable = false; this.isUnique = false;
this.isUnique = false; }
}
public void dsfsdfsfd() {
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 2.0D, this.yPos - this.textHeight / 2.0D - 2.0D, this.textWidth + 4.0D, this.textHeight + 4.0D);
}
public char sdfsdfdsfdf() {
return 'a';
}
protected Color sefdsfdsf45() {
return C2.ERMATTRColor;
}
protected Color getColorSelected() {
return C2.ERMSelectedColor;
}
public void dsfsdfsfd() {
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 2.0D, this.yPos - this.textHeight / 2.0D - 2.0D, this.textWidth + 4.0D, this.textHeight + 4.0D);
}
public boolean getCreateColumn() {
return this.createColumn;
}
public char sdfsdfdsfdf() {
return 'a';
}
public void setCreateColumn(boolean createColumn) {
this.createColumn = createColumn;
}
protected Color sefdsfdsf45() {
return C2.ERMATTRColor;
}
public String getColumnPostfix() {
return this.columnPostfix;
}
protected Color getColorSelected() {
return C2.ERMSelectedColor;
}
public void setColumnPostfix(String columnPraefix) {
this.columnPostfix = columnPraefix;
}
public String getColumnName() {
return this.columnName;
}
public void setColumnName(String columnName) {
public boolean getCreateColumn() { this.columnName = columnName;
return this.createColumn; }
}
public String getDatatype() {
return this.datatype;
}
public void setDatatype(String datatype) {
this.datatype = datatype;
}
public void setCreateColumn(boolean createColumn) {
this.createColumn = createColumn;
}
public boolean isKey() {
return this.isKey;
}
public void setIsKey(boolean isKey) {
this.isKey = isKey;
}
public boolean isAutoincrement() {
return this.isAutoincrement;
}
public String getColumnPostfix() {
return this.columnPostfix;
}
public void setIsAutoincrement(boolean isAutoincrement) {
this.isAutoincrement = isAutoincrement;
}
public long getAutoincrementStartAt() {
return this.autoincrementStartAt;
}
public void setAutoincrementStartAt(long autoincrementStartAt) {
public void setColumnPostfix(String columnPraefix) { this.autoincrementStartAt = autoincrementStartAt;
this.columnPostfix = columnPraefix; }
}
public boolean isUnique() {
return this.isUnique;
}
public void setIsUnique(boolean isUnique) {
this.isUnique = isUnique;
}
public boolean isNullable() {
public String getColumnName() { return this.isNullable;
return this.columnName; }
}
public void setIsNullable(boolean isNullable) {
this.isNullable = isNullable;
}
public String getMVRelationName() {
return this.mvRelationname;
}
public void setColumnName(String columnName) {
this.columnName = columnName;
}
public void setMVRelationName(String mvRelationname) {
this.mvRelationname = mvRelationname;
}
public String getMVRelationNamePraefix() {
return this.mvRelationnamePraefix;
}
public void setMVRelationNamePraefix(String mvRelationnamePraefix) {
this.mvRelationnamePraefix = mvRelationnamePraefix;
}
public String getDatatype() {
return this.datatype;
}
public String sdfsdfsd32234243() {
return this.name + "@" + this.datatype;
}
public String getDataGenerationType() {
return this.dataGenerationType;
}
public void setDataGenerationType(String dataGenerationType) {
public void setDatatype(String datatype) { this.dataGenerationType = dataGenerationType;
this.datatype = datatype; }
}
public String getPar1() {
return this.par1;
}
public void setPar1(String par1) {
this.par1 = par1;
}
public String getPar2() {
public boolean isKey() { return this.par2;
return this.isKey; }
}
public void setPar2(String par2) {
this.par2 = par2;
}
public String getPar1_label() {
return this.par1_label;
}
public void setIsKey(boolean isKey) {
this.isKey = isKey;
}
public void setPar1_label(String par1_label) {
this.par1_label = par1_label;
}
public String getPar2_label() {
return this.par2_label;
}
public void setPar2_label(String par2_label) {
this.par2_label = par2_label;
public boolean isAutoincrement() { }
return this.isAutoincrement;
}
public void setIsAutoincrement(boolean isAutoincrement) {
this.isAutoincrement = isAutoincrement;
}
public long getAutoincrementStartAt() {
return this.autoincrementStartAt;
}
public void setAutoincrementStartAt(long autoincrementStartAt) {
this.autoincrementStartAt = autoincrementStartAt;
}
public boolean isUnique() {
return this.isUnique;
}
public void setIsUnique(boolean isUnique) {
this.isUnique = isUnique;
}
public boolean isNullable() {
return this.isNullable;
}
public void setIsNullable(boolean isNullable) {
this.isNullable = isNullable;
}
public String getMVRelationName() {
return this.mvRelationname;
}
public void setMVRelationName(String mvRelationname) {
this.mvRelationname = mvRelationname;
}
public String getMVRelationNamePraefix() {
return this.mvRelationnamePraefix;
}
public void setMVRelationNamePraefix(String mvRelationnamePraefix) {
this.mvRelationnamePraefix = mvRelationnamePraefix;
}
public String sdfsdfsd32234243() {
return this.name + "@" + this.datatype;
}
public String getDataGenerationType() {
return this.dataGenerationType;
}
public void setDataGenerationType(String dataGenerationType) {
this.dataGenerationType = dataGenerationType;
}
public String getPar1() {
return this.par1;
}
public void setPar1(String par1) {
this.par1 = par1;
}
public String getPar2() {
return this.par2;
}
public void setPar2(String par2) {
this.par2 = par2;
}
public String getPar1_label() {
return this.par1_label;
}
public void setPar1_label(String par1_label) {
this.par1_label = par1_label;
}
public String getPar2_label() {
return this.par2_label;
}
public void setPar2_label(String par2_label) {
this.par2_label = par2_label;
}
} }

View File

@ -7,48 +7,35 @@ import java.io.Serial;
public class Graphic_ATTR_Key_Elem public class Graphic_ATTR_Key_Elem
extends Graphic_ATTR_Elem extends Graphic_ATTR_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_ATTR_Key_Elem(GraphicsContext gc, double x, double y, String name, long elementID) {
public Graphic_ATTR_Key_Elem(GraphicsContext gc, double x, double y, String name, long elementID) { super(gc, x, y, name, elementID);
super(gc, x, y, name, elementID); }
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeOval(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.setFill(C2.ERMTextColor);
this.gc.setStroke(Color.BLACK);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.strokeLine(this.xPos - this.textWidth / 2.0D + 10.0D,
this.yPos + this.textHeight / 2.0D - 13.0D, this.xPos + this.textWidth / 2.0D - 10.0D, this.yPos + this.textHeight / 2.0D - 13.0D);
this.gc.closePath();
}
public String safsafdsa456456456() {
return "A-K";
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeOval(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.setFill(C2.ERMTextColor);
this.gc.setStroke(Color.BLACK);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.strokeLine(this.xPos - this.textWidth / 2.0D + 10.0D,
this.yPos + this.textHeight / 2.0D - 13.0D, this.xPos + this.textWidth / 2.0D - 10.0D, this.yPos + this.textHeight / 2.0D - 13.0D);
this.gc.closePath();
}
public String safsafdsa456456456() {
return "A-K";
}
} }

View File

@ -7,51 +7,41 @@ import java.io.Serial;
public class Graphic_ATTR_Multi_Elem public class Graphic_ATTR_Multi_Elem
extends Graphic_ATTR_Elem extends Graphic_ATTR_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L; private final boolean derived;
private final boolean derived;
public Graphic_ATTR_Multi_Elem(GraphicsContext gc, double x, double y, String name, boolean derived, long elementID) {
public Graphic_ATTR_Multi_Elem(GraphicsContext gc, double x, double y, String name, boolean derived, long elementID) { super(gc, x, y, name, elementID);
super(gc, x, y, name, elementID); this.derived = derived;
this.derived = derived; }
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
if (this.derived) {
this.gc.setLineWidth(1.0D);
this.gc.setLineDashes(3.0D);
}
this.gc.strokeOval(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.strokeOval(this.xPos - this.textWidth / 2.0D + 3.0D, this.yPos - this.textHeight / 2.0D + 3.0D, this.textWidth - 6.0D, this.textHeight - 6.0D);
this.gc.setLineDashes();
this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.closePath();
}
public String safsafdsa456456456() {
return "A-M";
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
if (this.derived) {
this.gc.setLineWidth(1.0D);
this.gc.setLineDashes(3.0D);
}
this.gc.strokeOval(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.strokeOval(this.xPos - this.textWidth / 2.0D + 3.0D, this.yPos - this.textHeight / 2.0D + 3.0D, this.textWidth - 6.0D, this.textHeight - 6.0D);
this.gc.setLineDashes();
this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.closePath();
}
public String safsafdsa456456456() {
return "A-M";
}
} }

View File

@ -7,49 +7,40 @@ import java.io.Serial;
public class Graphic_ATTR_One_Elem public class Graphic_ATTR_One_Elem
extends Graphic_ATTR_Elem extends Graphic_ATTR_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L; private final boolean derived;
private final boolean derived;
public Graphic_ATTR_One_Elem(GraphicsContext gc, double x, double y, String name, boolean derived, long elementID) {
super(gc, x, y, name, elementID);
this.derived = derived;
}
public Graphic_ATTR_One_Elem(GraphicsContext gc, double x, double y, String name, boolean derived, long elementID) {
super(gc, x, y, name, elementID);
this.derived = derived;
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible) {
return;
} }
this.gc.beginPath();
this.gc.setStroke(c);
if (this.derived) {
this.gc.setLineWidth(1.0D);
this.gc.setLineDashes(3.0D);
}
this.gc.strokeOval(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.setLineDashes();
this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.closePath();
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible) {
return;
}
this.gc.beginPath();
this.gc.setStroke(c);
if (this.derived) {
this.gc.setLineWidth(1.0D);
this.gc.setLineDashes(3.0D);
}
this.gc.strokeOval(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.setLineDashes();
this.gc.setFill(C2.ERMTextColor);
public String safsafdsa456456456() { this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
return "A"; this.gc.closePath();
} }
public String safsafdsa456456456() {
return "A";
}
} }

View File

@ -7,49 +7,39 @@ import java.io.Serial;
public class Graphic_ATTR_Weak_Key_Elem public class Graphic_ATTR_Weak_Key_Elem
extends Graphic_ATTR_Elem extends Graphic_ATTR_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_ATTR_Weak_Key_Elem(GraphicsContext gc, double x, double y, String name, long elementID) {
public Graphic_ATTR_Weak_Key_Elem(GraphicsContext gc, double x, double y, String name, long elementID) { super(gc, x, y, name, elementID);
super(gc, x, y, name, elementID); }
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeOval(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.setFill(C2.ERMTextColor);
this.gc.setStroke(Color.BLACK);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.setLineWidth(1.0D);
this.gc.setLineDashes(3.0D);
this.gc.strokeLine(this.xPos - this.textWidth / 2.0D + 10.0D,
this.yPos + this.textHeight / 2.0D - 13.0D, this.xPos + this.textWidth / 2.0D - 10.0D, this.yPos + this.textHeight / 2.0D - 13.0D);
this.gc.setLineDashes();
this.gc.closePath();
}
public String safsafdsa456456456() {
return "A-WK";
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeOval(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.setFill(C2.ERMTextColor);
this.gc.setStroke(Color.BLACK);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.setLineWidth(1.0D);
this.gc.setLineDashes(3.0D);
this.gc.strokeLine(this.xPos - this.textWidth / 2.0D + 10.0D,
this.yPos + this.textHeight / 2.0D - 13.0D, this.xPos + this.textWidth / 2.0D - 10.0D, this.yPos + this.textHeight / 2.0D - 13.0D);
this.gc.setLineDashes();
this.gc.closePath();
}
public String safsafdsa456456456() {
return "A-WK";
}
} }

View File

@ -7,79 +7,56 @@ import java.io.Serial;
public class Graphic_ES_Assoc_Elem public class Graphic_ES_Assoc_Elem
extends Graphic_ES_Main_Elem extends Graphic_ES_Main_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_ES_Assoc_Elem(GraphicsContext gc, double x, double y, String name, long elementID) {
public Graphic_ES_Assoc_Elem(GraphicsContext gc, double x, double y, String name, long elementID) { super(gc, name, elementID);
super(gc, name, elementID);
this.xPos = x;
this.xPos = x; this.yPos = y;
this.yPos = y; }
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeRect(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.strokePolygon(new double[]{this.xPos - this.textWidth / 2.0D,
this.xPos,
this.xPos + this.textWidth / 2.0D,
this.xPos
}, new double[]{this.yPos,
this.yPos - this.textHeight / 2.0D,
this.yPos,
this.yPos + this.textHeight / 2.0D
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeRect(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.strokePolygon(new double[] { this.xPos - this.textWidth / 2.0D,
this.xPos,
this.xPos + this.textWidth / 2.0D,
this.xPos
}, new double[] { this.yPos,
this.yPos - this.textHeight / 2.0D,
this.yPos,
this.yPos + this.textHeight / 2.0D
}, 4); }, 4);
this.gc.setFill(C2.ERMTextColor); this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D); this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.closePath(); this.gc.closePath();
} }
public String safsafdsa456456456() {
return "ES-A";
}
public void dsfsdfsfd() {
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D);
public String safsafdsa456456456() { }
return "ES-A";
}
public char sdfsdfdsfdf() {
return '@';
public void dsfsdfsfd() { }
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D);
}
public char sdfsdfdsfdf() {
return '@';
}
} }

View File

@ -7,60 +7,46 @@ import java.io.Serial;
public class Graphic_ES_Elem public class Graphic_ES_Elem
extends Graphic_ES_Main_Elem extends Graphic_ES_Main_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_ES_Elem(GraphicsContext gc, double x, double y, String name, long elementID) {
public Graphic_ES_Elem(GraphicsContext gc, double x, double y, String name, long elementID) { super(gc, name, elementID);
super(gc, name, elementID); this.xPos = x;
this.xPos = x; this.yPos = y;
this.yPos = y; }
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeRect(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.closePath();
}
public String safsafdsa456456456() {
protected void dsfdsfds6787686(Color c) { return "ES";
if (!this.isVisible) }
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeRect(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.closePath();
}
public void dsfsdfsfd() {
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D);
}
public char sdfsdfdsfdf() {
return 'e';
}
public String safsafdsa456456456() {
return "ES";
}
public void dsfsdfsfd() {
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D);
}
public char sdfsdfdsfdf() {
return 'e';
}
} }

View File

@ -6,114 +6,90 @@ import java.io.Serial;
public abstract class Graphic_ES_Main_Elem public abstract class Graphic_ES_Main_Elem
extends Graphic_Figure_Elem extends Graphic_Figure_Elem
implements U3 implements U3 {
{ @Serial
protected boolean createRelation; private static final long serialVersionUID = 1L;
protected String relationPraefix; protected boolean createRelation;
protected String relationName; protected String relationPraefix;
protected boolean createInserts; protected String relationName;
protected long numberRowsToInsert = 1L; protected boolean createInserts;
protected long numberRowsToInsert = 1L;
public Graphic_ES_Main_Elem(GraphicsContext gc, String name, long elementID) {
super(gc, name, elementID);
this.createRelation = true;
this.relationName = this.name.toLowerCase();
this.relationName = T3.replaceSpecialChars(this.relationName);
this.relationPraefix = this.relationName.charAt(0) + "_";
this.createInserts = true;
}
protected void changeName(String name) {
super.changeName(name);
@Serial
private static final long serialVersionUID = 1L;
this.createRelation = true;
this.relationName = T3.replaceSpecialChars(name.toLowerCase());
this.relationPraefix = this.relationName.charAt(0) + "_";
}
public boolean getCreateRelation() {
return this.createRelation;
}
public void setCreateRelation(boolean createRelation) {
public Graphic_ES_Main_Elem(GraphicsContext gc, String name, long elementID) { this.createRelation = createRelation;
super(gc, name, elementID); }
this.createRelation = true;
this.relationName = this.name.toLowerCase();
this.relationName = T3.replaceSpecialChars(this.relationName);
this.relationPraefix = this.relationName.charAt(0) + "_";
this.createInserts = true;
}
public String getRelationPraefix() {
return this.relationPraefix;
}
public void setRelationPraefix(String relationPraefix) {
this.relationPraefix = relationPraefix;
protected void changeName(String name) { }
super.changeName(name);
this.createRelation = true;
this.relationName = T3.replaceSpecialChars(name.toLowerCase());
this.relationPraefix = this.relationName.charAt(0) + "_";
}
public String getRelationName() {
return this.relationName;
public boolean getCreateRelation() { }
return this.createRelation;
}
public void setCreateRelation(boolean createRelation) {
this.createRelation = createRelation;
}
public void setRelationName(String relationName) {
public String getRelationPraefix() { this.relationName = relationName;
return this.relationPraefix; }
}
public void setRelationPraefix(String relationPraefix) {
this.relationPraefix = relationPraefix;
}
public boolean getCreateInserts() {
public String getRelationName() { return this.createInserts;
return this.relationName; }
}
public void setRelationName(String relationName) {
this.relationName = relationName;
}
public boolean getCreateInserts() {
return this.createInserts;
}
public void setCreateInserts(boolean createInserts) {
public void setCreateInserts(boolean createInserts) { this.createInserts = createInserts;
this.createInserts = createInserts; }
}
public long getNumberRowsToInsert() {
public long getNumberRowsToInsert() { return this.numberRowsToInsert;
return this.numberRowsToInsert; }
}
public void setNumberRowsToInsert(long numberRowsToInsert) {
this.numberRowsToInsert = numberRowsToInsert;
}
public void setNumberRowsToInsert(long numberRowsToInsert) {
this.numberRowsToInsert = numberRowsToInsert;
}
public String sdfsdfsd32234243() { public String sdfsdfsd32234243() {
return super.sdfsdfsd32234243(); return super.sdfsdfsd32234243();
} }
} }

View File

@ -7,66 +7,51 @@ import java.io.Serial;
public class Graphic_ES_Weak_Elem public class Graphic_ES_Weak_Elem
extends Graphic_ES_Main_Elem extends Graphic_ES_Main_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_ES_Weak_Elem(GraphicsContext gc, double x, double y, String name, long elementID) {
public Graphic_ES_Weak_Elem(GraphicsContext gc, double x, double y, String name, long elementID) { super(gc, name, elementID);
super(gc, name, elementID);
this.xPos = x;
this.xPos = x; this.yPos = y;
this.yPos = y; }
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeRect(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.strokeRect(this.xPos - this.textWidth / 2.0D + 3.0D, this.yPos - this.textHeight / 2.0D + 3.0D, this.textWidth - 6.0D, this.textHeight - 6.0D);
this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.closePath();
}
public String safsafdsa456456456() {
return "ES-W";
protected void dsfdsfds6787686(Color c) { }
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeRect(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
this.gc.strokeRect(this.xPos - this.textWidth / 2.0D + 3.0D, this.yPos - this.textHeight / 2.0D + 3.0D, this.textWidth - 6.0D, this.textHeight - 6.0D);
this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
this.gc.closePath();
}
public void dsfsdfsfd() {
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D);
}
public char sdfsdfdsfdf() {
return 'e';
public String safsafdsa456456456() { }
return "ES-W";
}
protected Color sefdsfdsf45() {
public void dsfsdfsfd() { return C2.ERMESColor;
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D); }
}
public char sdfsdfdsfdf() {
return 'e';
}
protected Color sefdsfdsf45() {
return C2.ERMESColor;
}
} }

View File

@ -8,200 +8,163 @@ import java.io.Serial;
public abstract class Graphic_Figure_Elem public abstract class Graphic_Figure_Elem
extends Graphic_Main_Elem extends Graphic_Main_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L; protected double textWidth;
protected double textWidth; protected double textHeight;
protected double textHeight;
public Graphic_Figure_Elem(GraphicsContext gc, String name, long elementID) {
public abstract String safsafdsa456456456(); super(gc, elementID);
this.name = name;
public double dsfsfsd456457657() { if (name == null) this.name = safsafdsa456456456();
return this.textWidth; } public double getHeight() { calculateTextWidthHeight();
return this.textHeight; }
} protected void dockablePointsAtElem() {
drawDockablePoints(getColorDockable()); public abstract String safsafdsa456456456();
}
public double dsfsfsd456457657() {
return this.textWidth;
}
public double getHeight() {
return this.textHeight;
}
protected void dockablePointsAtElem() {
drawDockablePoints(getColorDockable());
}
protected void changeName(String name) {
this.name = name;
if (name == null) this.name = safsafdsa456456456();
dsfsdfsfd();
calculateTextWidthHeight();
safdsadasds32432456456();
}
public boolean dsfsfds45645456(double mouseX, double mouseY) {
return mouseX >= this.xPos - dsfsfsd456457657() / 2.0D && mouseX <= this.xPos + dsfsfsd456457657() / 2.0D &&
public Graphic_Figure_Elem(GraphicsContext gc, String name, long elementID) { mouseY >= this.yPos - getHeight() / 2.0D && mouseY <= this.yPos + getHeight() / 2.0D;
super(gc, elementID); }
this.name = name;
if (name == null) this.name = safsafdsa456456456();
calculateTextWidthHeight();
}
public void calculateTextWidthHeight() {
this.textWidth = C2.computeTextWidth(this.name, 2000.0D);
this.textWidth += 20.0D;
this.gc.setFont(C2.ERMFont);
Font f = this.gc.getFont();
this.textHeight = f.getSize();
this.textHeight += 30.0D;
}
public String toString() {
return "Graphic_Figure_Elem [textWidth=" + this.textWidth + ", textHeight=" + this.textHeight + ", toString()=" +
super.toString() + "]";
}
protected void drawDockablePoints(Color c) {
if (!this.isConnectable)
protected void changeName(String name) { return;
this.name = name; this.gc.setFill(c);
if (name == null) this.name = safsafdsa456456456();
dsfsdfsfd();
calculateTextWidthHeight();
safdsadasds32432456456();
}
this.gc.fillOval(this.xPos - this.textWidth / 2.0D, this.yPos - 3.0D, 6.0D, 6.0D);
this.gc.fillOval(this.xPos - 3.0D, this.yPos - this.textHeight / 2.0D, 6.0D, 6.0D);
public boolean dsfsfds45645456(double mouseX, double mouseY) {
return mouseX >= this.xPos - dsfsfsd456457657() / 2.0D && mouseX <= this.xPos + dsfsfsd456457657() / 2.0D &&
mouseY >= this.yPos - getHeight() / 2.0D && mouseY <= this.yPos + getHeight() / 2.0D;
}
this.gc.fillOval(this.xPos + this.textWidth / 2.0D - 6.0D, this.yPos - 3.0D, 6.0D, 6.0D);
this.gc.fillOval(this.xPos - 3.0D, this.yPos + this.textHeight / 2.0D - 6.0D, 6.0D, 6.0D);
public void calculateTextWidthHeight() { }
this.textWidth = C2.computeTextWidth(this.name, 2000.0D);
this.textWidth += 20.0D;
this.gc.setFont(C2.ERMFont);
Font f = this.gc.getFont();
this.textHeight = f.getSize();
this.textHeight += 30.0D;
}
protected void drawDockablePoint(Color c, int point) {
this.gc.setFill(c);
switch (point) {
case 1 -> this.gc.fillOval(this.xPos - this.textWidth / 2.0D, this.yPos - 3.0D, 6.0D, 6.0D);
case 2 -> this.gc.fillOval(this.xPos - 3.0D, this.yPos - this.textHeight / 2.0D, 6.0D, 6.0D);
case 3 -> this.gc.fillOval(this.xPos + this.textWidth / 2.0D - 6.0D, this.yPos - 3.0D, 6.0D, 6.0D);
case 4 -> this.gc.fillOval(this.xPos - 3.0D, this.yPos + this.textHeight / 2.0D - 6.0D, 6.0D, 6.0D);
}
}
public double[] getDockablePoint(double mouseX, double mouseY) {
double[] selected = null;
public String toString() {
return "Graphic_Figure_Elem [textWidth=" + this.textWidth + ", textHeight=" + this.textHeight + ", toString()=" +
super.toString() + "]";
}
if (mouseX >= this.xPos - this.textWidth / 2.0D - 5.0D && mouseX <= this.xPos - this.textWidth / 2.0D + 5.0D && mouseY >= this.yPos - 5.0D && mouseY <= this.yPos + 5.0D) {
selected = new double[3];
selected[0] = this.xPos - this.textWidth / 2.0D;
selected[1] = this.yPos;
selected[2] = 1.0D;
}
if (mouseX >= this.xPos - 5.0D && mouseX <= this.xPos + 5.0D && mouseY >= this.yPos - this.textHeight / 2.0D - 5.0D && mouseY <= this.yPos - this.textHeight / 2.0D + 5.0D) {
selected = new double[3];
selected[0] = this.xPos;
selected[1] = this.yPos - this.textHeight / 2.0D;
selected[2] = 2.0D;
}
if (mouseX >= this.xPos + this.textWidth / 2.0D - 5.0D && mouseX <= this.xPos + this.textWidth / 2.0D + 5.0D && mouseY >= this.yPos - 5.0D && mouseY <= this.yPos + 5.0D) {
selected = new double[3];
selected[0] = this.xPos + this.textWidth / 2.0D;
selected[1] = this.yPos;
selected[2] = 3.0D;
}
if (mouseX >= this.xPos - 5.0D && mouseX <= this.xPos + 5.0D && mouseY >= this.yPos + this.textHeight / 2.0D - 5.0D && mouseY <= this.yPos + this.textHeight / 2.0D + 5.0D) {
selected = new double[3];
selected[0] = this.xPos;
selected[1] = this.yPos + this.textHeight / 2.0D;
selected[2] = 4.0D;
}
return selected;
}
public double[] getXYForGivenPoint(byte dockedAt) {
double[] xyAtPoint = new double[2];
switch (dockedAt) {
case 0 -> {
xyAtPoint[0] = this.xPos;
xyAtPoint[1] = this.yPos;
}
case 1 -> {
xyAtPoint[0] = this.xPos - this.textWidth / 2.0D;
xyAtPoint[1] = this.yPos;
}
case 2 -> {
xyAtPoint[0] = this.xPos;
xyAtPoint[1] = this.yPos - this.textHeight / 2.0D;
}
case 3 -> {
xyAtPoint[0] = this.xPos + this.textWidth / 2.0D;
xyAtPoint[1] = this.yPos;
}
case 4 -> {
xyAtPoint[0] = this.xPos;
xyAtPoint[1] = this.yPos + this.textHeight / 2.0D;
}
}
return xyAtPoint;
protected void drawDockablePoints(Color c) { }
if (!this.isConnectable)
return;
this.gc.setFill(c);
this.gc.fillOval(this.xPos - this.textWidth / 2.0D, this.yPos - 3.0D, 6.0D, 6.0D);
this.gc.fillOval(this.xPos - 3.0D, this.yPos - this.textHeight / 2.0D, 6.0D, 6.0D);
this.gc.fillOval(this.xPos + this.textWidth / 2.0D - 6.0D, this.yPos - 3.0D, 6.0D, 6.0D);
this.gc.fillOval(this.xPos - 3.0D, this.yPos + this.textHeight / 2.0D - 6.0D, 6.0D, 6.0D);
}
protected void drawDockablePoint(Color c, int point) {
this.gc.setFill(c);
switch (point) {
case 1 -> this.gc.fillOval(this.xPos - this.textWidth / 2.0D, this.yPos - 3.0D, 6.0D, 6.0D);
case 2 -> this.gc.fillOval(this.xPos - 3.0D, this.yPos - this.textHeight / 2.0D, 6.0D, 6.0D);
case 3 -> this.gc.fillOval(this.xPos + this.textWidth / 2.0D - 6.0D, this.yPos - 3.0D, 6.0D, 6.0D);
case 4 -> this.gc.fillOval(this.xPos - 3.0D, this.yPos + this.textHeight / 2.0D - 6.0D, 6.0D, 6.0D);
}
}
protected Color sefdsfdsf45() {
return C2.ERMESColor;
}
public double[] getDockablePoint(double mouseX, double mouseY) {
double[] selected = null;
if (mouseX >= this.xPos - this.textWidth / 2.0D - 5.0D && mouseX <= this.xPos - this.textWidth / 2.0D + 5.0D && mouseY >= this.yPos - 5.0D && mouseY <= this.yPos + 5.0D) {
selected = new double[3];
selected[0] = this.xPos - this.textWidth / 2.0D;
selected[1] = this.yPos;
selected[2] = 1.0D;
}
if (mouseX >= this.xPos - 5.0D && mouseX <= this.xPos + 5.0D && mouseY >= this.yPos - this.textHeight / 2.0D - 5.0D && mouseY <= this.yPos - this.textHeight / 2.0D + 5.0D) {
selected = new double[3];
selected[0] = this.xPos;
selected[1] = this.yPos - this.textHeight / 2.0D;
selected[2] = 2.0D;
}
if (mouseX >= this.xPos + this.textWidth / 2.0D - 5.0D && mouseX <= this.xPos + this.textWidth / 2.0D + 5.0D && mouseY >= this.yPos - 5.0D && mouseY <= this.yPos + 5.0D) {
selected = new double[3];
selected[0] = this.xPos + this.textWidth / 2.0D;
selected[1] = this.yPos;
selected[2] = 3.0D;
}
if (mouseX >= this.xPos - 5.0D && mouseX <= this.xPos + 5.0D && mouseY >= this.yPos + this.textHeight / 2.0D - 5.0D && mouseY <= this.yPos + this.textHeight / 2.0D + 5.0D) {
selected = new double[3];
selected[0] = this.xPos;
selected[1] = this.yPos + this.textHeight / 2.0D;
selected[2] = 4.0D;
}
return selected;
}
public double[] getXYForGivenPoint(byte dockedAt) {
double[] xyAtPoint = new double[2];
switch (dockedAt) {
case 0 -> {
xyAtPoint[0] = this.xPos;
xyAtPoint[1] = this.yPos;
}
case 1 -> {
xyAtPoint[0] = this.xPos - this.textWidth / 2.0D;
xyAtPoint[1] = this.yPos;
}
case 2 -> {
xyAtPoint[0] = this.xPos;
xyAtPoint[1] = this.yPos - this.textHeight / 2.0D;
}
case 3 -> {
xyAtPoint[0] = this.xPos + this.textWidth / 2.0D;
xyAtPoint[1] = this.yPos;
}
case 4 -> {
xyAtPoint[0] = this.xPos;
xyAtPoint[1] = this.yPos + this.textHeight / 2.0D;
}
}
return xyAtPoint;
}
protected Color sefdsfdsf45() {
return C2.ERMESColor;
}
} }

View File

@ -7,21 +7,18 @@ import java.io.Serial;
public class Graphic_LINE_Attr_Attr_Elem public class Graphic_LINE_Attr_Attr_Elem
extends Graphic_LINE_Elem extends Graphic_LINE_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_LINE_Attr_Attr_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) {
public Graphic_LINE_Attr_Attr_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) { super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID);
super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID); }
}
protected Color sefdsfdsf45() {
return C2.ERMLINEColor;
protected Color sefdsfdsf45() { }
return C2.ERMLINEColor;
}
} }

View File

@ -7,21 +7,18 @@ import java.io.Serial;
public class Graphic_LINE_Attr_ES_Elem public class Graphic_LINE_Attr_ES_Elem
extends Graphic_LINE_Elem extends Graphic_LINE_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_LINE_Attr_ES_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) {
public Graphic_LINE_Attr_ES_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) { super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID);
super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID); }
}
protected Color sefdsfdsf45() {
return C2.ERMLINEColor;
protected Color sefdsfdsf45() { }
return C2.ERMLINEColor;
}
} }

View File

@ -7,21 +7,18 @@ import java.io.Serial;
public class Graphic_LINE_Attr_RS_Elem public class Graphic_LINE_Attr_RS_Elem
extends Graphic_LINE_Elem extends Graphic_LINE_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_LINE_Attr_RS_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) {
public Graphic_LINE_Attr_RS_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) { super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID);
super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID); }
}
protected Color sefdsfdsf45() {
return C2.ERMLINEColor;
protected Color sefdsfdsf45() { }
return C2.ERMLINEColor;
}
} }

View File

@ -9,420 +9,345 @@ import javafx.scene.transform.Translate;
import java.io.Serial; import java.io.Serial;
public abstract class Graphic_LINE_Elem public abstract class Graphic_LINE_Elem
extends Graphic_Main_Elem extends Graphic_Main_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L; private final byte lineConnectedWithPointAtStart;
private final byte lineConnectedWithPointAtEnd;
protected String minimum = "0";
protected String maximum = "n";
private double xEnd; private double xEnd;
private double yEnd;
private double yEnd; private Graphic_Figure_Elem connectedWithStart;
protected String minimum = "0"; private Graphic_Figure_Elem connectedWithEnd;
protected String maximum = "n";
public Graphic_LINE_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) {
super(gc, elementID);
this.xPos = x;
private Graphic_Figure_Elem connectedWithStart; this.yPos = y;
this.lineConnectedWithPointAtStart = lineConnectedWithPointAtStart;
this.connectedWithStart = elemStart;
this.xEnd = xEnd;
this.yEnd = yEnd;
this.lineConnectedWithPointAtEnd = lineConnectedWithPointAtEnd;
this.connectedWithEnd = elemEnd;
this.name = "";
if (this instanceof Graphic_LINE_RSID_ESWEAK_Elem) {
this.minimum = "1";
this.maximum = "1";
}
}
protected void changeMinMax(String minimum, String maximum) {
this.minimum = minimum;
private final byte lineConnectedWithPointAtStart; this.maximum = maximum;
if (minimum == null) this.minimum = getDefaultMinimum();
if (maximum == null) this.minimum = getDefaultMaximum();
dsfsdfsfd();
safdsadasds32432456456();
}
private void drawArrow(Color c, double x1, double y1, double x2, double y2) {
this.gc.setStroke(c);
double dx = x2 - x1, dy = y2 - y1;
private Graphic_Figure_Elem connectedWithEnd; double angle = Math.atan2(dy, dx);
double len = Math.sqrt(dx * dx + dy * dy);
Affine oldTransform = this.gc.getTransform();
private final byte lineConnectedWithPointAtEnd;
Translate translate = Transform.translate(x1, y1);
Transform transform = translate.createConcatenation(Transform.rotate(Math.toDegrees(angle), 0.0D, 0.0D));
this.gc.setTransform(new Affine(transform));
this.gc.setFill(C2.ERMBackgroundColor);
public Graphic_LINE_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) {
super(gc, elementID);
this.xPos = x;
this.yPos = y;
this.lineConnectedWithPointAtStart = lineConnectedWithPointAtStart;
this.connectedWithStart = elemStart;
this.xEnd = xEnd;
this.yEnd = yEnd;
this.lineConnectedWithPointAtEnd = lineConnectedWithPointAtEnd;
this.connectedWithEnd = elemEnd;
this.name = "";
if (this instanceof Graphic_LINE_RSID_ESWEAK_Elem) {
this.minimum = "1";
this.maximum = "1";
}
}
this.gc.strokePolygon(new double[]{len, len - 8.0D, len - 8.0D
}, new double[]{0.0D, -8.0D, 8.0D
protected void changeMinMax(String minimum, String maximum) {
this.minimum = minimum;
this.maximum = maximum;
if (minimum == null) this.minimum = getDefaultMinimum();
if (maximum == null) this.minimum = getDefaultMaximum();
dsfsdfsfd();
safdsadasds32432456456();
}
private void drawArrow(Color c, double x1, double y1, double x2, double y2) {
this.gc.setStroke(c);
double dx = x2 - x1, dy = y2 - y1;
double angle = Math.atan2(dy, dx);
double len = Math.sqrt(dx * dx + dy * dy);
Affine oldTransform = this.gc.getTransform();
Translate translate = Transform.translate(x1, y1);
Transform transform = translate.createConcatenation(Transform.rotate(Math.toDegrees(angle), 0.0D, 0.0D));
this.gc.setTransform(new Affine(transform));
this.gc.setFill(C2.ERMBackgroundColor);
this.gc.strokePolygon(new double[] { len, len - 8.0D, len - 8.0D
}, new double[] { 0.0D, -8.0D, 8.0D
}, 3); }, 3);
this.gc.setTransform(oldTransform);
}
this.gc.setTransform(oldTransform);
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
if (this.name == null) this.name = "";
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeLine(this.xPos, this.yPos, this.xEnd, this.yEnd);
if (this instanceof Graphic_LINE_RSISAG_ES_Elem) {
if (this.connectedWithStart instanceof Graphic_ES_Elem) {
drawArrow(c, this.xEnd, this.yEnd, this.xPos, this.yPos);
}
if (this.connectedWithEnd instanceof Graphic_ES_Elem) {
drawArrow(c, this.xPos, this.yPos, this.xEnd, this.yEnd);
}
return;
}
if (this instanceof Graphic_LINE_RSISAS_ES_Elem)
return; if (this instanceof Graphic_LINE_Attr_Attr_Elem)
return; if (this instanceof Graphic_LINE_Attr_ES_Elem)
return; if (this instanceof Graphic_LINE_Attr_RS_Elem) {
return;
} }
double helpXStart = this.xPos;
double helpXEnd = this.xEnd;
double helpYStart = this.yPos;
double helpYEnd = this.yEnd;
this.gc.setFill(C2.ERMTextColor);
if (this.xEnd < this.xPos) { helpXStart = this.xEnd; helpXEnd = this.xPos; }
if (this.yEnd < this.yPos) { helpYStart = this.yEnd; helpYEnd = this.yPos; }
this.gc.fillText("(" + this.minimum + "," + this.maximum + ")", helpXStart + (helpXEnd - helpXStart) / 2.0D, helpYStart + (helpYEnd - helpYStart) / 2.0D - 5.0D);
this.gc.closePath();
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
if (this.name == null) this.name = "";
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokeLine(this.xPos, this.yPos, this.xEnd, this.yEnd);
if (this instanceof Graphic_LINE_RSISAG_ES_Elem) {
public void dsfsdfsfd() {
this.gc.beginPath();
this.gc.setStroke(C2.ERMBackgroundColor);
this.gc.setLineWidth(3.0D);
this.gc.strokeLine(this.xPos, this.yPos, this.xEnd, this.yEnd);
this.gc.setLineWidth(1.0D);
if (this.connectedWithStart instanceof Graphic_ES_Elem) {
if (this instanceof Graphic_LINE_RSISAG_ES_Elem) { drawArrow(c, this.xEnd, this.yEnd, this.xPos, this.yPos);
double d1 = 0.0D, d2 = 0.0D, helpWidth = 0.0D, helpHeight = 0.0D;
Graphic_ES_Elem helpElem = null;
byte helpConnectedWithPoint = 0;
if (this.connectedWithStart instanceof Graphic_ES_Elem) {
helpElem = (Graphic_ES_Elem)this.connectedWithStart;
helpConnectedWithPoint = this.lineConnectedWithPointAtStart;
}
if (this.connectedWithEnd instanceof Graphic_ES_Elem) {
helpElem = (Graphic_ES_Elem)this.connectedWithEnd;
helpConnectedWithPoint = this.lineConnectedWithPointAtEnd;
}
assert helpElem != null;
double[] dockedPoints = helpElem.getXYForGivenPoint(helpConnectedWithPoint);
switch (helpConnectedWithPoint) {
case 1, 2 -> {
d1 = dockedPoints[0] - 16.0D;
d2 = dockedPoints[1] - 16.0D;
helpWidth = 29.0D;
helpHeight = 29.0D;
} }
case 3 -> { if (this.connectedWithEnd instanceof Graphic_ES_Elem) {
d1 = dockedPoints[0]; drawArrow(c, this.xPos, this.yPos, this.xEnd, this.yEnd);
d2 = dockedPoints[1] - 8.0D - 5.0D;
helpWidth = 28.0D;
helpHeight = 28.0D;
}
case 4 -> {
d1 = dockedPoints[0] - 8.0D - 5.0D;
d2 = dockedPoints[1] + 1.0D;
helpWidth = 28.0D;
helpHeight = 28.0D;
} }
return;
} }
if (this instanceof Graphic_LINE_RSISAS_ES_Elem)
this.gc.clearRect(d1, d2, helpWidth, helpHeight); return;
return; if (this instanceof Graphic_LINE_Attr_Attr_Elem)
} return;
if (this instanceof Graphic_LINE_RSISAS_ES_Elem) if (this instanceof Graphic_LINE_Attr_ES_Elem)
return; if (this instanceof Graphic_LINE_Attr_Attr_Elem) return;
return; if (this instanceof Graphic_LINE_Attr_ES_Elem) if (this instanceof Graphic_LINE_Attr_RS_Elem) {
return; if (this instanceof Graphic_LINE_Attr_RS_Elem) { return;
return; }
double helpXStart = this.xPos;
double helpXEnd = this.xEnd;
double helpYStart = this.yPos;
double helpYEnd = this.yEnd;
this.gc.setFill(C2.ERMTextColor);
if (this.xEnd < this.xPos) {
helpXStart = this.xEnd;
helpXEnd = this.xPos;
}
if (this.yEnd < this.yPos) {
helpYStart = this.yEnd;
helpYEnd = this.yPos;
}
this.gc.fillText("(" + this.minimum + "," + this.maximum + ")", helpXStart + (helpXEnd - helpXStart) / 2.0D, helpYStart + (helpYEnd - helpYStart) / 2.0D - 5.0D);
this.gc.closePath();
} }
double helpXStart = this.xPos;
double helpXEnd = this.xEnd;
double helpYStart = this.yPos;
double helpYEnd = this.yEnd;
if (this.xEnd < this.xPos) { helpXStart = this.xEnd; helpXEnd = this.xPos; }
if (this.yEnd < this.yPos) { helpYStart = this.yEnd; helpYEnd = this.yPos; }
this.gc.clearRect(helpXStart + (helpXEnd - helpXStart) / 2.0D - 6.0D,
helpYStart + (helpYEnd - helpYStart) / 2.0D - 5.0D - 10.0D,
C2.computeTextWidth("(" + this.minimum + "," + this.maximum + ")", 2000.0D) + 12.0D,
C2.computeTextHeight() + 12.0D);
this.gc.closePath();
}
public void dsfsdfsfd() {
this.gc.beginPath();
this.gc.setStroke(C2.ERMBackgroundColor);
this.gc.setLineWidth(3.0D);
this.gc.strokeLine(this.xPos, this.yPos, this.xEnd, this.yEnd);
this.gc.setLineWidth(1.0D);
if (this instanceof Graphic_LINE_RSISAG_ES_Elem) {
double d1 = 0.0D, d2 = 0.0D, helpWidth = 0.0D, helpHeight = 0.0D;
Graphic_ES_Elem helpElem = null;
byte helpConnectedWithPoint = 0;
if (this.connectedWithStart instanceof Graphic_ES_Elem) {
helpElem = (Graphic_ES_Elem) this.connectedWithStart;
helpConnectedWithPoint = this.lineConnectedWithPointAtStart;
}
if (this.connectedWithEnd instanceof Graphic_ES_Elem) {
helpElem = (Graphic_ES_Elem) this.connectedWithEnd;
helpConnectedWithPoint = this.lineConnectedWithPointAtEnd;
}
assert helpElem != null;
double[] dockedPoints = helpElem.getXYForGivenPoint(helpConnectedWithPoint);
switch (helpConnectedWithPoint) {
case 1, 2 -> {
d1 = dockedPoints[0] - 16.0D;
d2 = dockedPoints[1] - 16.0D;
helpWidth = 29.0D;
helpHeight = 29.0D;
}
case 3 -> {
d1 = dockedPoints[0];
d2 = dockedPoints[1] - 8.0D - 5.0D;
helpWidth = 28.0D;
helpHeight = 28.0D;
}
case 4 -> {
d1 = dockedPoints[0] - 8.0D - 5.0D;
d2 = dockedPoints[1] + 1.0D;
helpWidth = 28.0D;
helpHeight = 28.0D;
}
}
this.gc.clearRect(d1, d2, helpWidth, helpHeight);
public double dsfsfsd456457657() { return;
return this.xEnd; }
} if (this instanceof Graphic_LINE_RSISAS_ES_Elem)
return;
if (this instanceof Graphic_LINE_Attr_Attr_Elem)
return;
if (this instanceof Graphic_LINE_Attr_ES_Elem)
return;
if (this instanceof Graphic_LINE_Attr_RS_Elem) {
return;
}
double helpXStart = this.xPos;
double helpXEnd = this.xEnd;
double helpYStart = this.yPos;
double helpYEnd = this.yEnd;
if (this.xEnd < this.xPos) {
helpXStart = this.xEnd;
helpXEnd = this.xPos;
}
if (this.yEnd < this.yPos) {
helpYStart = this.yEnd;
helpYEnd = this.yPos;
}
this.gc.clearRect(helpXStart + (helpXEnd - helpXStart) / 2.0D - 6.0D,
helpYStart + (helpYEnd - helpYStart) / 2.0D - 5.0D - 10.0D,
C2.computeTextWidth("(" + this.minimum + "," + this.maximum + ")", 2000.0D) + 12.0D,
C2.computeTextHeight() + 12.0D);
this.gc.closePath();
}
public double getHeight() {
return this.yEnd;
}
public double dsfsfsd456457657() {
return this.xEnd;
}
public double getHeight() {
return this.yEnd;
}
public boolean dsfsfds45645456(double mouseX, double mouseY) {
Graphic_Figure_Elem aHelp = getConnectedWithStart();
double[] dockablePointsAHelp = aHelp.getXYForGivenPoint(getLineConnectedWithPointAtStart());
Graphic_Figure_Elem bHelp = getConnectedWithEnd();
double[] dockablePointsBHelp = bHelp.getXYForGivenPoint(getLineConnectedWithPointAtEnd());
double distStartToMouse = distP1_P2(dockablePointsAHelp[0], dockablePointsAHelp[1], mouseX, mouseY);
double distMouseToEnd = distP1_P2(mouseX, mouseY, dockablePointsBHelp[0], dockablePointsBHelp[1]);
double distStartToEnd = distP1_P2(dockablePointsAHelp[0], dockablePointsAHelp[1], dockablePointsBHelp[0], dockablePointsBHelp[1]);
return Math.abs(distStartToMouse + distMouseToEnd - distStartToEnd) <= 0.3D;
}
public Graphic_Figure_Elem getConnectedWithStart() {
return this.connectedWithStart;
}
public boolean dsfsfds45645456(double mouseX, double mouseY) {
Graphic_Figure_Elem aHelp = getConnectedWithStart();
double[] dockablePointsAHelp = aHelp.getXYForGivenPoint(getLineConnectedWithPointAtStart());
Graphic_Figure_Elem bHelp = getConnectedWithEnd();
double[] dockablePointsBHelp = bHelp.getXYForGivenPoint(getLineConnectedWithPointAtEnd());
public void setConnectedWithStart(Graphic_Figure_Elem connectedWithStart) {
double distStartToMouse = distP1_P2(dockablePointsAHelp[0], dockablePointsAHelp[1], mouseX, mouseY); this.connectedWithStart = connectedWithStart;
double distMouseToEnd = distP1_P2(mouseX, mouseY, dockablePointsBHelp[0], dockablePointsBHelp[1]); }
double distStartToEnd = distP1_P2(dockablePointsAHelp[0], dockablePointsAHelp[1], dockablePointsBHelp[0], dockablePointsBHelp[1]);
return Math.abs(distStartToMouse + distMouseToEnd - distStartToEnd) <= 0.3D; public Graphic_Figure_Elem getConnectedWithEnd() {
} return this.connectedWithEnd;
}
public void setConnectedWithEnd(Graphic_Figure_Elem connectedWithEnd) {
this.connectedWithEnd = connectedWithEnd;
}
public Graphic_Figure_Elem getConnectedWithStart() {
return this.connectedWithStart;
}
public double getxEnd() {
return this.xEnd;
}
public void setxEnd(double xEnd) {
public void setConnectedWithStart(Graphic_Figure_Elem connectedWithStart) { this.xEnd = xEnd;
this.connectedWithStart = connectedWithStart; }
}
public double getyEnd() {
return this.yEnd;
}
public Graphic_Figure_Elem getConnectedWithEnd() {
return this.connectedWithEnd;
}
public void setyEnd(double yEnd) {
this.yEnd = yEnd;
}
public char sdfsdfdsfdf() {
public void setConnectedWithEnd(Graphic_Figure_Elem connectedWithEnd) { return 'l';
this.connectedWithEnd = connectedWithEnd; }
}
public double distP1_P2(double xP1, double yP1, double xP2, double yP2) {
double dist;
dist = Math.sqrt((xP1 - xP2) * (xP1 - xP2) + (yP1 - yP2) * (yP1 - yP2));
return dist;
}
public double getxEnd() {
return this.xEnd;
}
public String getMinimum() {
return this.minimum;
}
public void setMinimum(String minimum) {
public void setxEnd(double xEnd) { this.minimum = minimum;
this.xEnd = xEnd; }
}
public String getMaximum() {
return this.maximum;
}
public double getyEnd() {
return this.yEnd;
}
public void setMaximum(String maximum) {
this.maximum = maximum;
}
private String getDefaultMinimum() {
return "0";
}
private String getDefaultMaximum() {
public void setyEnd(double yEnd) { return "n";
this.yEnd = yEnd; }
}
public String toString() {
public char sdfsdfdsfdf() { return "Graphic_LINE_Elem [xEnd=" + this.xEnd + ", yEnd=" + this.yEnd + ", minimum=" + this.minimum + ", maximum=" + this.maximum +
return 'l'; ", connectedWithStart=" + this.connectedWithStart + ", connectedWithEnd=" + this.connectedWithEnd +
} ", toString()=" + super.toString() + "]";
}
public byte getLineConnectedWithPointAtStart() {
return this.lineConnectedWithPointAtStart;
}
public double distP1_P2(double xP1, double yP1, double xP2, double yP2) {
double dist;
dist = Math.sqrt((xP1 - xP2) * (xP1 - xP2) + (yP1 - yP2) * (yP1 - yP2));
return dist;
}
public String getMinimum() {
return this.minimum;
}
public void setMinimum(String minimum) {
this.minimum = minimum;
}
public String getMaximum() {
return this.maximum;
}
public void setMaximum(String maximum) {
this.maximum = maximum;
}
private String getDefaultMinimum() {
return "0";
}
private String getDefaultMaximum() {
return "n";
}
public String toString() {
return "Graphic_LINE_Elem [xEnd=" + this.xEnd + ", yEnd=" + this.yEnd + ", minimum=" + this.minimum + ", maximum=" + this.maximum +
", connectedWithStart=" + this.connectedWithStart + ", connectedWithEnd=" + this.connectedWithEnd +
", toString()=" + super.toString() + "]";
}
public byte getLineConnectedWithPointAtStart() {
return this.lineConnectedWithPointAtStart;
}
public byte getLineConnectedWithPointAtEnd() { public byte getLineConnectedWithPointAtEnd() {
return this.lineConnectedWithPointAtEnd; return this.lineConnectedWithPointAtEnd;
} }
public String sdfsdfsd32234243() { public String sdfsdfsd32234243() {
if (this instanceof Graphic_LINE_RSISAG_ES_Elem) { if (this instanceof Graphic_LINE_RSISAG_ES_Elem) {
return this.connectedWithStart.sdfsdfsd32234243() + "[G]" + this.connectedWithEnd.sdfsdfsd32234243(); return this.connectedWithStart.sdfsdfsd32234243() + "[G]" + this.connectedWithEnd.sdfsdfsd32234243();
}
if (this instanceof Graphic_LINE_RSISAS_ES_Elem) {
return this.connectedWithStart.sdfsdfsd32234243() + "[Sp]" + this.connectedWithEnd.sdfsdfsd32234243();
}
if (this instanceof Graphic_LINE_Attr_ES_Elem ||
this instanceof Graphic_LINE_Attr_Attr_Elem || this instanceof Graphic_LINE_Attr_RS_Elem) {
String usedStartName = this.connectedWithStart.sdfsdfsd32234243();
if (this.connectedWithStart instanceof Graphic_ATTR_Elem) {
usedStartName = usedStartName.substring(0, usedStartName.indexOf('@'));
}
String usedEndName = this.connectedWithEnd.sdfsdfsd32234243();
if (this.connectedWithEnd instanceof Graphic_ATTR_Elem) {
usedEndName = usedEndName.substring(0, usedEndName.indexOf('@'));
}
return usedStartName + "[-]" + usedEndName;
}
return this.connectedWithStart.sdfsdfsd32234243() + "(" + this.minimum + "," + this.maximum + ")" + this.connectedWithEnd.sdfsdfsd32234243();
} }
if (this instanceof Graphic_LINE_RSISAS_ES_Elem) {
return this.connectedWithStart.sdfsdfsd32234243() + "[Sp]" + this.connectedWithEnd.sdfsdfsd32234243();
}
if (this instanceof Graphic_LINE_Attr_ES_Elem ||
this instanceof Graphic_LINE_Attr_Attr_Elem || this instanceof Graphic_LINE_Attr_RS_Elem) {
String usedStartName = this.connectedWithStart.sdfsdfsd32234243();
if (this.connectedWithStart instanceof Graphic_ATTR_Elem) {
usedStartName = usedStartName.substring(0, usedStartName.indexOf('@'));
}
String usedEndName = this.connectedWithEnd.sdfsdfsd32234243();
if (this.connectedWithEnd instanceof Graphic_ATTR_Elem) {
usedEndName = usedEndName.substring(0, usedEndName.indexOf('@'));
}
return usedStartName + "[-]" + usedEndName;
}
return this.connectedWithStart.sdfsdfsd32234243() + "(" + this.minimum + "," + this.maximum + ")" + this.connectedWithEnd.sdfsdfsd32234243();
}
} }

View File

@ -7,21 +7,18 @@ import java.io.Serial;
public class Graphic_LINE_RSID_ESWEAK_Elem public class Graphic_LINE_RSID_ESWEAK_Elem
extends Graphic_LINE_Elem extends Graphic_LINE_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_LINE_RSID_ESWEAK_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) {
public Graphic_LINE_RSID_ESWEAK_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) { super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID);
super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID); }
}
protected Color sefdsfdsf45() {
return C2.ERMRSConnColor;
protected Color sefdsfdsf45() { }
return C2.ERMRSConnColor;
}
} }

View File

@ -6,48 +6,19 @@ import javafx.scene.paint.Color;
import java.io.Serial; import java.io.Serial;
public class Graphic_LINE_RSID_ES_Elem public class Graphic_LINE_RSID_ES_Elem
extends Graphic_LINE_Elem extends Graphic_LINE_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_LINE_RSID_ES_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) {
public Graphic_LINE_RSID_ES_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) { super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID);
super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID); }
}
protected Color sefdsfdsf45() {
return C2.ERMRSConnColor;
protected Color sefdsfdsf45() { }
return C2.ERMRSConnColor;
}
} }

View File

@ -7,21 +7,18 @@ import java.io.Serial;
public class Graphic_LINE_RSISAG_ES_Elem public class Graphic_LINE_RSISAG_ES_Elem
extends Graphic_LINE_Elem extends Graphic_LINE_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_LINE_RSISAG_ES_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) {
public Graphic_LINE_RSISAG_ES_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) { super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID);
super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID); }
}
protected Color sefdsfdsf45() {
return C2.ERMISAConnGENERAL;
protected Color sefdsfdsf45() { }
return C2.ERMISAConnGENERAL;
}
} }

View File

@ -7,21 +7,18 @@ import java.io.Serial;
public class Graphic_LINE_RSISAS_ES_Elem public class Graphic_LINE_RSISAS_ES_Elem
extends Graphic_LINE_Elem extends Graphic_LINE_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_LINE_RSISAS_ES_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) {
public Graphic_LINE_RSISAS_ES_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) { super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID);
super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID); }
}
protected Color sefdsfdsf45() {
return C2.ERMISAConnSPEC;
protected Color sefdsfdsf45() { }
return C2.ERMISAConnSPEC;
}
} }

View File

@ -7,21 +7,18 @@ import java.io.Serial;
public class Graphic_LINE_RS_ES_Elem public class Graphic_LINE_RS_ES_Elem
extends Graphic_LINE_Elem extends Graphic_LINE_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_LINE_RS_ES_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) {
public Graphic_LINE_RS_ES_Elem(GraphicsContext gc, double x, double y, double xEnd, double yEnd, byte lineConnectedWithPointAtStart, byte lineConnectedWithPointAtEnd, Graphic_Figure_Elem elemStart, Graphic_Figure_Elem elemEnd, long elementID) { super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID);
super(gc, x, y, xEnd, yEnd, lineConnectedWithPointAtStart, lineConnectedWithPointAtEnd, elemStart, elemEnd, elementID); }
}
protected Color sefdsfdsf45() {
return C2.ERMRSConnColor;
protected Color sefdsfdsf45() { }
return C2.ERMRSConnColor;
}
} }

View File

@ -1,214 +1,158 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import java.io.Serial;
import java.io.Serializable;
import javafx.scene.canvas.GraphicsContext; import javafx.scene.canvas.GraphicsContext;
import javafx.scene.paint.Color; import javafx.scene.paint.Color;
import java.io.Serial;
import java.io.Serializable;
public abstract class Graphic_Main_Elem public abstract class Graphic_Main_Elem
implements Serializable, Comparable<Graphic_Main_Elem> implements Serializable, Comparable<Graphic_Main_Elem> {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L; protected long graphicMainElemID;
protected long graphicMainElemID; protected double xPos;
protected double xPos; protected double yPos;
protected double yPos; protected String name;
protected String name; protected transient GraphicsContext gc;
protected transient GraphicsContext gc; protected transient boolean isVisible;
protected transient boolean isVisible; protected transient boolean isConnectable;
protected transient boolean isConnectable; transient U4 undoRedoAction;
transient U4 undoRedoAction;
public Graphic_Main_Elem(GraphicsContext gc, long elementID) {
public Graphic_Main_Elem(GraphicsContext gc, long elementID) { this.graphicMainElemID = elementID;
this.graphicMainElemID = elementID; this.gc = gc;
this.gc = gc; this.isVisible = true;
this.isVisible = true; }
}
public GraphicsContext getGc() {
return this.gc;
public GraphicsContext getGc() { }
return this.gc;
}
public void setGc(GraphicsContext gc) {
public void setGc(GraphicsContext gc) { this.gc = gc;
this.gc = gc; }
}
public void setxPos(double xPos) {
this.xPos = xPos;
}
public void setyPos(double yPos) {
this.yPos = yPos;
}
public void safdsadasds32432456456() {
dsfdsfds6787686(sefdsfdsf45()); }
public void safdsadasds32432456456() {
dsfdsfds6787686(sefdsfdsf45());
}
protected Color getColorSelected() { protected Color getColorSelected() {
return C2.ERMSelectedColor; return C2.ERMSelectedColor;
} }
protected Color getColorDockable() {
return C2.ERMDockablePointColor;
}
public void dfsdfssdf456456() {
dsfsdfsfd();
dsfdsfds6787686(sefdsfdsf45());
}
public double getxPos() {
return this.xPos;
}
public void setxPos(double xPos) {
this.xPos = xPos;
}
public double getyPos() {
return this.yPos;
}
public void setyPos(double yPos) {
this.yPos = yPos;
}
public void dgfdsfdssfd43534456() {
selectElem();
}
public void sdffdsfsdf4354357656(double newX, double newY) {
dsfsdfsfd();
this.xPos = newX;
this.yPos = newY;
dsfdsfds6787686(getColorSelected());
}
public void selectElem() {
protected Color getColorDockable() { dsfdsfds6787686(getColorSelected());
return C2.ERMDockablePointColor; }
}
public int hashCode() {
int result = 1;
result = 31 * result + (int) (this.graphicMainElemID ^ this.graphicMainElemID >>> 32L);
return result;
}
public boolean equals(Object obj) {
public void dfsdfssdf456456() { if (this == obj)
dsfsdfsfd(); dsfdsfds6787686(sefdsfdsf45()); return true;
} if (obj == null)
return false;
if (getClass() != obj.getClass())
return false;
Graphic_Main_Elem other = (Graphic_Main_Elem) obj;
return this.graphicMainElemID == other.graphicMainElemID;
}
public String toString() {
return "Graphic_Main_Elem [graphicMainElemID=" + this.graphicMainElemID + ", xPos=" + this.xPos + ", yPos=" + this.yPos +
", name=" + this.name + "]";
}
public long sdfsdfsdfd() {
return this.graphicMainElemID;
}
public void dsdasadsasd32423432(long graphicMainElemID) {
this.graphicMainElemID = graphicMainElemID;
}
public String sdfsdfsd32234243() {
public double getxPos() { return this.name;
return this.xPos; }
}
public U4 adsadadsa4354353() {
public double getyPos() { return this.undoRedoAction;
return this.yPos; }
}
public void sfdsfsfsddf123234435(U4 undoRedoAction) {
public void dgfdsfdssfd43534456() { this.undoRedoAction = undoRedoAction;
selectElem(); }
}
public int compareTo(Graphic_Main_Elem arg0) {
return Long.compare(this.graphicMainElemID, arg0.graphicMainElemID);
}
public abstract double dsfsfsd456457657();
public abstract double getHeight();
protected abstract Color sefdsfdsf45();
public void sdffdsfsdf4354357656(double newX, double newY) {
dsfsdfsfd();
this.xPos = newX;
this.yPos = newY;
dsfdsfds6787686(getColorSelected());
}
public abstract void dsfsdfsfd();
protected abstract void dsfdsfds6787686(Color paramColor);
public abstract boolean dsfsfds45645456(double paramDouble1, double paramDouble2);
public void selectElem() {
dsfdsfds6787686(getColorSelected());
}
public abstract char sdfsdfdsfdf();
public int hashCode() {
int result = 1;
result = 31 * result + (int)(this.graphicMainElemID ^ this.graphicMainElemID >>> 32L);
return result;
}
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (getClass() != obj.getClass())
return false;
Graphic_Main_Elem other = (Graphic_Main_Elem)obj;
return this.graphicMainElemID == other.graphicMainElemID;
}
public String toString() {
return "Graphic_Main_Elem [graphicMainElemID=" + this.graphicMainElemID + ", xPos=" + this.xPos + ", yPos=" + this.yPos +
", name=" + this.name + "]";
}
public long sdfsdfsdfd() {
return this.graphicMainElemID;
}
public void dsdasadsasd32423432(long graphicMainElemID) {
this.graphicMainElemID = graphicMainElemID;
}
public String sdfsdfsd32234243() {
return this.name;
}
public U4 adsadadsa4354353() {
return this.undoRedoAction;
}
public void sfdsfsfsddf123234435(U4 undoRedoAction) {
this.undoRedoAction = undoRedoAction;
}
public int compareTo(Graphic_Main_Elem arg0) {
return Long.compare(this.graphicMainElemID, arg0.graphicMainElemID);
}
public abstract double dsfsfsd456457657();
public abstract double getHeight();
protected abstract Color sefdsfdsf45();
public abstract void dsfsdfsfd();
protected abstract void dsfdsfds6787686(Color paramColor);
public abstract boolean dsfsfds45645456(double paramDouble1, double paramDouble2);
public abstract char sdfsdfdsfdf();
} }

View File

@ -6,82 +6,67 @@ import javafx.scene.paint.Color;
import java.io.Serial; import java.io.Serial;
public class Graphic_RS_Elem public class Graphic_RS_Elem
extends Graphic_RS_Main_Elem extends Graphic_RS_Main_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_RS_Elem(GraphicsContext gc, double x, double y, String name, long elementID) {
public Graphic_RS_Elem(GraphicsContext gc, double x, double y, String name, long elementID) { super(gc, name, elementID);
super(gc, name, elementID);
this.xPos = x;
this.xPos = x; this.yPos = y;
this.yPos = y; this.createRelation = true;
this.createRelation = true; }
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokePolygon(new double[]{this.xPos - this.textWidth / 2.0D,
protected void dsfdsfds6787686(Color c) { this.xPos,
if (!this.isVisible) this.xPos + this.textWidth / 2.0D,
return; this.xPos
this.gc.beginPath(); }, new double[]{this.yPos,
this.gc.setStroke(c); this.yPos - this.textHeight / 2.0D,
this.gc.strokePolygon(new double[] { this.xPos - this.textWidth / 2.0D, this.yPos,
this.xPos, this.yPos + this.textHeight / 2.0D
this.xPos + this.textWidth / 2.0D,
this.xPos
}, new double[] { this.yPos,
this.yPos - this.textHeight / 2.0D,
this.yPos,
this.yPos + this.textHeight / 2.0D
}, 4); }, 4);
this.gc.setFill(C2.ERMTextColor); this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 18.0D); this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 18.0D);
this.gc.closePath(); this.gc.closePath();
} }
public String safsafdsa456456456() {
return "RS";
}
public void dsfsdfsfd() {
public String safsafdsa456456456() { this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 2.0D, this.yPos - this.textHeight / 2.0D - 2.0D, this.textWidth + 4.0D, this.textHeight + 4.0D);
return "RS"; }
}
public double dsfsfsd456457657() {
public void dsfsdfsfd() { return this.textWidth;
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 2.0D, this.yPos - this.textHeight / 2.0D - 2.0D, this.textWidth + 4.0D, this.textHeight + 4.0D); }
}
public double getHeight() {
public double dsfsfsd456457657() { return this.textHeight;
return this.textWidth; }
}
public char sdfsdfdsfdf() {
public double getHeight() { return 'r';
return this.textHeight; }
}
protected Color sefdsfdsf45() {
public char sdfsdfdsfdf() { return C2.ERMRSColor;
return 'r'; }
}
protected Color sefdsfdsf45() {
return C2.ERMRSColor;
}
} }

View File

@ -7,152 +7,123 @@ import java.io.Serial;
public class Graphic_RS_ISA_Elem public class Graphic_RS_ISA_Elem
extends Graphic_RS_Main_Elem extends Graphic_RS_Main_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L; private String partial_or_total;
private String partial_or_total; private String disjunct_or_notdisjunct;
private String disjunct_or_notdisjunct;
public Graphic_RS_ISA_Elem(GraphicsContext gc, double x, double y, String name, long elementID) {
public Graphic_RS_ISA_Elem(GraphicsContext gc, double x, double y, String name, long elementID) { super(gc, null, elementID);
super(gc, null, elementID);
this.xPos = x;
this.xPos = x; this.yPos = y;
this.yPos = y; this.createRelation = false;
this.createRelation = false; this.createInserts = true;
this.createInserts = true; this.numberRowsToInsert = 1L;
this.numberRowsToInsert = 1L; }
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
protected void dsfdsfds6787686(Color c) { this.gc.strokePolygon(new double[]{this.xPos - this.textWidth / 2.0D,
if (!this.isVisible) this.xPos,
return; this.xPos + this.textWidth / 2.0D,
this.gc.beginPath(); this.xPos
this.gc.setStroke(c); }, new double[]{this.yPos,
this.gc.strokePolygon(new double[] { this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D,
this.xPos, this.yPos,
this.xPos + this.textWidth / 2.0D, this.yPos + this.textHeight / 2.0D
this.xPos
}, new double[] { this.yPos,
this.yPos - this.textHeight / 2.0D,
this.yPos,
this.yPos + this.textHeight / 2.0D
}, 4); }, 4);
this.gc.setFill(C2.ERMTextColor); this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 17.0D); this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 17.0D);
this.gc.fillText("(" + this.partial_or_total + "," + this.disjunct_or_notdisjunct + ")", this.xPos + this.textWidth / 2.0D + 5.0D, this.yPos - 5.0D);
this.gc.closePath();
}
this.gc.fillText("(" + this.partial_or_total + "," + this.disjunct_or_notdisjunct + ")", this.xPos + this.textWidth / 2.0D + 5.0D, this.yPos - 5.0D);
this.gc.closePath();
}
public String safsafdsa456456456() {
public String safsafdsa456456456() { return "ISA";
return "ISA"; }
}
public void dsfsdfsfd() {
public void dsfsdfsfd() { this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D);
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D);
this.gc.clearRect(this.xPos + this.textWidth / 2.0D + 5.0D - 3.0D,
this.gc.clearRect(this.xPos + this.textWidth / 2.0D + 5.0D - 3.0D, this.yPos - 15.0D,
this.yPos - 15.0D, C2.computeTextWidth("(" + this.partial_or_total + "," + this.disjunct_or_notdisjunct + ")", 2000.0D) + 10.0D,
C2.computeTextWidth("(" + this.partial_or_total + "," + this.disjunct_or_notdisjunct + ")", 2000.0D) + 10.0D, C2.computeTextHeight() + 12.0D);
C2.computeTextHeight() + 12.0D); }
}
public double dsfsfsd456457657() {
public double dsfsfsd456457657() { return this.textWidth;
return this.textWidth; }
}
public double getHeight() {
public double getHeight() { return this.textHeight;
return this.textHeight; }
}
public char sdfsdfdsfdf() {
public char sdfsdfdsfdf() { return 'r';
return 'r'; }
}
protected Color sefdsfdsf45() {
protected Color sefdsfdsf45() { return C2.ERMRSISAColor;
return C2.ERMRSISAColor; }
}
public String getPartial_or_total() {
return this.partial_or_total;
public String getPartial_or_total() { }
return this.partial_or_total;
}
public void setPartial_or_total(String partial_or_total) {
this.partial_or_total = partial_or_total;
public void setPartial_or_total(String partial_or_total) { }
this.partial_or_total = partial_or_total;
}
public String getDisjunct_or_notdisjunct() {
return this.disjunct_or_notdisjunct;
public String getDisjunct_or_notdisjunct() { }
return this.disjunct_or_notdisjunct;
}
public void setDisjunct_or_notdisjunct(String disjunct_or_notdisjunct) {
this.disjunct_or_notdisjunct = disjunct_or_notdisjunct;
public void setDisjunct_or_notdisjunct(String disjunct_or_notdisjunct) { }
this.disjunct_or_notdisjunct = disjunct_or_notdisjunct;
}
protected void changeP_T_D_ND(String partial_or_total, String disjunct_or_notdisjunct) {
this.partial_or_total = partial_or_total;
this.disjunct_or_notdisjunct = disjunct_or_notdisjunct;
if (partial_or_total == null) this.partial_or_total = getDefaultPartial_or_total();
if (disjunct_or_notdisjunct == null) this.disjunct_or_notdisjunct = getDefaultDisjunct_or_notdisjunct();
dsfsdfsfd();
safdsadasds32432456456();
}
private String getDefaultPartial_or_total() {
return "p";
}
private String getDefaultDisjunct_or_notdisjunct() {
return "nd";
}
public String sdfsdfsd32234243() {
return safsafdsa456456456() + "(" + this.partial_or_total + "," + this.disjunct_or_notdisjunct + ")";
}
protected void changeP_T_D_ND(String partial_or_total, String disjunct_or_notdisjunct) {
this.partial_or_total = partial_or_total;
this.disjunct_or_notdisjunct = disjunct_or_notdisjunct;
if (partial_or_total == null) this.partial_or_total = getDefaultPartial_or_total();
if (disjunct_or_notdisjunct == null) this.disjunct_or_notdisjunct = getDefaultDisjunct_or_notdisjunct();
dsfsdfsfd();
safdsadasds32432456456();
}
private String getDefaultPartial_or_total() {
return "p";
}
private String getDefaultDisjunct_or_notdisjunct() {
return "nd";
}
public String sdfsdfsd32234243() {
return safsafdsa456456456() + "(" + this.partial_or_total + "," + this.disjunct_or_notdisjunct + ")";
}
} }

View File

@ -7,95 +7,78 @@ import java.io.Serial;
public class Graphic_RS_Identifying_Elem public class Graphic_RS_Identifying_Elem
extends Graphic_RS_Main_Elem extends Graphic_RS_Main_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L;
public Graphic_RS_Identifying_Elem(GraphicsContext gc, double x, double y, String name, long elementID) {
public Graphic_RS_Identifying_Elem(GraphicsContext gc, double x, double y, String name, long elementID) { super(gc, name, elementID);
super(gc, name, elementID);
this.xPos = x;
this.xPos = x; this.yPos = y;
this.yPos = y; this.createRelation = false;
this.createRelation = false; this.createInserts = true;
this.createInserts = true; this.numberRowsToInsert = 1L;
this.numberRowsToInsert = 1L; }
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible)
return;
this.gc.beginPath();
this.gc.setStroke(c);
this.gc.strokePolygon(new double[]{this.xPos - this.textWidth / 2.0D,
protected void dsfdsfds6787686(Color c) { this.xPos,
if (!this.isVisible) this.xPos + this.textWidth / 2.0D,
return; this.xPos
this.gc.beginPath(); }, new double[]{this.yPos,
this.gc.setStroke(c); this.yPos - this.textHeight / 2.0D,
this.gc.strokePolygon(new double[] { this.xPos - this.textWidth / 2.0D, this.yPos,
this.xPos, this.yPos + this.textHeight / 2.0D
this.xPos + this.textWidth / 2.0D,
this.xPos
}, new double[] { this.yPos,
this.yPos - this.textHeight / 2.0D,
this.yPos,
this.yPos + this.textHeight / 2.0D
}, 4); }, 4);
this.gc.strokePolygon(new double[] { this.xPos - this.textWidth / 2.0D + 3.0D, this.gc.strokePolygon(new double[]{this.xPos - this.textWidth / 2.0D + 3.0D,
this.xPos, this.xPos,
this.xPos + this.textWidth / 2.0D - 3.0D, this.xPos + this.textWidth / 2.0D - 3.0D,
this.xPos this.xPos
}, new double[] { this.yPos, }, new double[]{this.yPos,
this.yPos - this.textHeight / 2.0D + 3.0D, this.yPos - this.textHeight / 2.0D + 3.0D,
this.yPos, this.yPos,
this.yPos + this.textHeight / 2.0D - 3.0D this.yPos + this.textHeight / 2.0D - 3.0D
}, 4); }, 4);
this.gc.setFill(C2.ERMTextColor); this.gc.setFill(C2.ERMTextColor);
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 17.0D); this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 17.0D);
this.gc.closePath(); this.gc.closePath();
} }
public String safsafdsa456456456() {
return "RS-ID";
}
public void dsfsdfsfd() {
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D);
}
public double dsfsfsd456457657() {
public String safsafdsa456456456() { return this.textWidth;
return "RS-ID"; }
}
public double getHeight() {
public void dsfsdfsfd() { return this.textHeight;
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D); }
}
public char sdfsdfdsfdf() {
public double dsfsfsd456457657() { return 'r';
return this.textWidth; }
}
protected Color sefdsfdsf45() {
public double getHeight() { return C2.ERMRSColor;
return this.textHeight; }
}
public char sdfsdfdsfdf() {
return 'r';
}
protected Color sefdsfdsf45() {
return C2.ERMRSColor;
}
} }

View File

@ -6,108 +6,87 @@ import java.io.Serial;
public abstract class Graphic_RS_Main_Elem public abstract class Graphic_RS_Main_Elem
extends Graphic_Figure_Elem extends Graphic_Figure_Elem
implements U3 implements U3 {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L; protected boolean createRelation;
protected boolean createRelation; protected String relationPraefix;
protected String relationPraefix; protected String relationName;
protected String relationName; protected boolean createInserts;
protected boolean createInserts; protected long numberRowsToInsert = 1L;
protected long numberRowsToInsert = 1L;
public Graphic_RS_Main_Elem(GraphicsContext gc, String name, long elementID) {
super(gc, name, elementID);
this.relationName = this.name.toLowerCase();
this.relationName = T3.replaceSpecialChars(this.relationName);
this.relationPraefix = this.relationName.charAt(0) + "_";
this.createInserts = true;
}
protected void changeName(String name) {
super.changeName(name);
this.relationName = T3.replaceSpecialChars(name.toLowerCase());
this.relationPraefix = this.relationName.charAt(0) + "_";
}
public boolean getCreateRelation() {
return this.createRelation;
}
public void setCreateRelation(boolean createRelation) {
public Graphic_RS_Main_Elem(GraphicsContext gc, String name, long elementID) { this.createRelation = createRelation;
super(gc, name, elementID); }
this.relationName = this.name.toLowerCase();
this.relationName = T3.replaceSpecialChars(this.relationName);
this.relationPraefix = this.relationName.charAt(0) + "_";
this.createInserts = true;
}
public String getRelationPraefix() {
return this.relationPraefix;
}
public void setRelationPraefix(String relationPraefix) {
this.relationPraefix = relationPraefix;
protected void changeName(String name) { }
super.changeName(name);
this.relationName = T3.replaceSpecialChars(name.toLowerCase());
this.relationPraefix = this.relationName.charAt(0) + "_";
}
public String getRelationName() {
public boolean getCreateRelation() { return this.relationName;
return this.createRelation; }
}
public void setCreateRelation(boolean createRelation) {
this.createRelation = createRelation;
}
public void setRelationName(String relationName) {
public String getRelationPraefix() { this.relationName = relationName;
return this.relationPraefix; }
}
public void setRelationPraefix(String relationPraefix) {
this.relationPraefix = relationPraefix;
}
public boolean getCreateInserts() {
public String getRelationName() { return this.createInserts;
return this.relationName; }
}
public void setRelationName(String relationName) {
this.relationName = relationName;
}
public void setCreateInserts(boolean createInserts) {
public boolean getCreateInserts() { this.createInserts = createInserts;
return this.createInserts; }
}
public long getNumberRowsToInsert() {
public void setCreateInserts(boolean createInserts) { return this.numberRowsToInsert;
this.createInserts = createInserts; }
}
public void setNumberRowsToInsert(long numberRowsToInsert) {
public long getNumberRowsToInsert() { this.numberRowsToInsert = numberRowsToInsert;
return this.numberRowsToInsert; }
}
public String sdfsdfsd32234243() {
public void setNumberRowsToInsert(long numberRowsToInsert) { return super.sdfsdfsd32234243();
this.numberRowsToInsert = numberRowsToInsert; }
}
public String sdfsdfsd32234243() {
return super.sdfsdfsd32234243();
}
} }

View File

@ -8,130 +8,110 @@ import java.io.Serial;
public class Graphic_Text_Elem public class Graphic_Text_Elem
extends Graphic_Main_Elem extends Graphic_Main_Elem {
{ @Serial
@Serial private static final long serialVersionUID = 1L;
private static final long serialVersionUID = 1L; protected double textWidth;
protected double textWidth; protected double textHeight;
protected double textHeight; protected boolean hasBorder;
protected boolean hasBorder; private int numberLines;
private int numberLines;
public Graphic_Text_Elem(GraphicsContext gc, double x, double y, String name, boolean hasBorder, long elementID) {
public double dsfsfsd456457657() { super(gc, elementID);
return this.textWidth; } public double getHeight() { this.name = name;
return this.textHeight; if (name == null) this.name = getDefaultName();
} this.hasBorder = hasBorder;
this.xPos = x;
this.yPos = y;
String[] lines = this.name.split("\n");
this.numberLines = lines.length;
calculateTextWidthHeight();
}
public double dsfsfsd456457657() {
return this.textWidth;
}
public double getHeight() {
return this.textHeight;
}
protected void changeName(String name) {
this.name = name;
if (name == null) this.name = getDefaultName();
dsfsdfsfd();
String[] lines = this.name.split("\n");
this.numberLines = lines.length;
calculateTextWidthHeight();
safdsadasds32432456456();
}
public boolean dsfsfds45645456(double mouseX, double mouseY) {
public Graphic_Text_Elem(GraphicsContext gc, double x, double y, String name, boolean hasBorder, long elementID) { return mouseX >= this.xPos - dsfsfsd456457657() / 2.0D && mouseX <= this.xPos + dsfsfsd456457657() / 2.0D &&
super(gc, elementID); mouseY >= this.yPos - getHeight() / 2.0D && mouseY <= this.yPos + getHeight() / 2.0D;
this.name = name; }
if (name == null) this.name = getDefaultName();
this.hasBorder = hasBorder;
this.xPos = x;
this.yPos = y;
String[] lines = this.name.split("\n");
this.numberLines = lines.length;
calculateTextWidthHeight();
}
public void calculateTextWidthHeight() {
this.textWidth = C2.computeTextWidth(this.name, 2000.0D);
this.textWidth += 20.0D;
this.gc.setFont(C2.ERMFont);
Font f = this.gc.getFont();
this.textHeight = f.getSize();
this.textHeight = this.numberLines * this.textHeight + 30.0D;
}
public String toString() {
return "Graphic_Figure_Elem [textWidth=" + this.textWidth + ", textHeight=" + this.textHeight + ", toString()=" +
super.toString() + "]";
protected void changeName(String name) { }
this.name = name;
if (name == null) this.name = getDefaultName();
dsfsdfsfd();
String[] lines = this.name.split("\n");
this.numberLines = lines.length;
calculateTextWidthHeight();
safdsadasds32432456456();
}
public boolean dsfsfds45645456(double mouseX, double mouseY) {
return mouseX >= this.xPos - dsfsfsd456457657() / 2.0D && mouseX <= this.xPos + dsfsfsd456457657() / 2.0D &&
mouseY >= this.yPos - getHeight() / 2.0D && mouseY <= this.yPos + getHeight() / 2.0D;
}
public void calculateTextWidthHeight() {
this.textWidth = C2.computeTextWidth(this.name, 2000.0D);
this.textWidth += 20.0D;
this.gc.setFont(C2.ERMFont);
Font f = this.gc.getFont();
this.textHeight = f.getSize();
this.textHeight = this.numberLines * this.textHeight + 30.0D;
}
public String toString() {
return "Graphic_Figure_Elem [textWidth=" + this.textWidth + ", textHeight=" + this.textHeight + ", toString()=" +
super.toString() + "]";
}
protected Color sefdsfdsf45() { protected Color sefdsfdsf45() {
return C2.ERMTextBorderColor; return C2.ERMTextBorderColor;
}
public void dsfsdfsfd() {
this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D);
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible) {
return;
} }
this.gc.beginPath();
if (this.hasBorder || c.equals(C2.ERMSelectedColor)) {
this.gc.setStroke(c);
this.gc.strokeRect(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
}
this.gc.setFill(C2.ERMTextColor);
if (this.numberLines == 1) { this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D); }
else { this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos - this.textHeight / 2.0D + this.textHeight / this.numberLines); }
this.gc.closePath();
}
public void dsfsdfsfd() {
public char sdfsdfdsfdf() { this.gc.clearRect(this.xPos - this.textWidth / 2.0D - 1.0D, this.yPos - this.textHeight / 2.0D - 1.0D, this.textWidth + 2.0D, this.textHeight + 2.0D);
return 't'; }
}
protected void dsfdsfds6787686(Color c) {
if (!this.isVisible) {
return;
}
this.gc.beginPath();
if (this.hasBorder || c.equals(C2.ERMSelectedColor)) {
public String getDefaultName() { this.gc.setStroke(c);
return "Text"; this.gc.strokeRect(this.xPos - this.textWidth / 2.0D, this.yPos - this.textHeight / 2.0D, this.textWidth, this.textHeight);
} }
this.gc.setFill(C2.ERMTextColor);
if (this.numberLines == 1) {
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos + this.textHeight / 2.0D - 15.0D);
} else {
this.gc.fillText(this.name, this.xPos - this.textWidth / 2.0D + 10.0D, this.yPos - this.textHeight / 2.0D + this.textHeight / this.numberLines);
}
this.gc.closePath();
}
public char sdfsdfdsfdf() {
return 't';
}
public String getDefaultName() {
return "Text";
}
} }

View File

@ -5,203 +5,147 @@ import java.util.Collections;
import java.util.HashMap; import java.util.HashMap;
public class T1 public class T1
implements Comparable<T1> implements Comparable<T1> {
{ private final String tablenamePraefix;
private String tablename; private final long referstoGraphicalElement;
private final String tablenamePraefix; private final ArrayList<C3> skjdfhgdskjf674534;
private final long referstoGraphicalElement; private final ArrayList<T1> dependsOnTable;
private final ArrayList<C3> skjdfhgdskjf674534; private final HashMap<T1, ArrayList<C3>> columnsOfDependentOnTable;
private final ArrayList<T1> dependsOnTable; private final boolean createInserts;
private final HashMap<T1, ArrayList<C3>> columnsOfDependentOnTable; private String tablename;
private final boolean createInserts; private long jdshfalkajsd677676;
private long jdshfalkajsd677676;
public T1(String tablename, String tablenamePraefix, long referstoGraphicalElement, boolean createInserts, long numberValues) {
public T1(String tablename, String tablenamePraefix, long referstoGraphicalElement, boolean createInserts, long numberValues) { this.tablename = tablename;
this.tablename = tablename; this.tablenamePraefix = tablenamePraefix;
this.tablenamePraefix = tablenamePraefix; this.referstoGraphicalElement = referstoGraphicalElement;
this.referstoGraphicalElement = referstoGraphicalElement; this.createInserts = createInserts;
this.createInserts = createInserts; this.jdshfalkajsd677676 = numberValues;
this.jdshfalkajsd677676 = numberValues; this.skjdfhgdskjf674534 = new ArrayList<>();
this.skjdfhgdskjf674534 = new ArrayList<>(); this.dependsOnTable = new ArrayList<>();
this.dependsOnTable = new ArrayList<>(); this.columnsOfDependentOnTable = new HashMap<>();
this.columnsOfDependentOnTable = new HashMap<>(); }
}
public void addColumn(C3 column) {
this.skjdfhgdskjf674534.add(column);
Collections.sort(this.skjdfhgdskjf674534);
}
public void addTableDepdendentOn(T1 table) {
this.dependsOnTable.add(table);
public void addColumn(C3 column) { }
this.skjdfhgdskjf674534.add(column);
Collections.sort(this.skjdfhgdskjf674534);
}
public void addTableDepdendentOn(T1 table) {
this.dependsOnTable.add(table);
}
public String getTablename() { public String getTablename() {
return this.tablename; return this.tablename;
} }
public void setTablename(String tablename) {
public void setTablename(String tablename) { this.tablename = tablename;
this.tablename = tablename; }
}
public ArrayList<C3> getSkjdfhgdskjf674534() {
public ArrayList<C3> getSkjdfhgdskjf674534() { return this.skjdfhgdskjf674534;
return this.skjdfhgdskjf674534; }
}
public int hashCode() {
int result = 1;
result = 31 * result + ((this.tablename == null) ? 0 : this.tablename.hashCode());
return result;
}
public boolean equals(Object obj) {
public int hashCode() { if (this == obj)
int result = 1; return true;
result = 31 * result + ((this.tablename == null) ? 0 : this.tablename.hashCode()); if (obj == null)
return result; return false;
} if (getClass() != obj.getClass())
return false;
T1 other = (T1) obj;
if (this.tablename == null) {
return other.tablename == null;
} else return this.tablename.equals(other.tablename);
}
public String toString() {
return "RM_Table [tablename=" + this.tablename + ", tablenamePraefix=" + this.tablenamePraefix +
", referstoGraphicalElement=" + this.referstoGraphicalElement + ", columns=" + this.skjdfhgdskjf674534 + "]";
}
public String getTablenamePraefix() {
public boolean equals(Object obj) { return this.tablenamePraefix;
if (this == obj) }
return true;
if (obj == null)
return false;
if (getClass() != obj.getClass())
return false;
T1 other = (T1)obj;
if (this.tablename == null) {
return other.tablename == null;
} else return this.tablename.equals(other.tablename);
}
public String toString() {
return "RM_Table [tablename=" + this.tablename + ", tablenamePraefix=" + this.tablenamePraefix +
", referstoGraphicalElement=" + this.referstoGraphicalElement + ", columns=" + this.skjdfhgdskjf674534 + "]";
}
public String getTablenamePraefix() {
return this.tablenamePraefix;
}
public int compareTo(T1 arg0) { public int compareTo(T1 arg0) {
return getTablename().compareTo(arg0.getTablename()); return getTablename().compareTo(arg0.getTablename());
} }
public long getReferstoGraphicalElement() {
return this.referstoGraphicalElement;
public long getReferstoGraphicalElement() { }
return this.referstoGraphicalElement;
}
public ArrayList<C3> getKeyColumns() { public ArrayList<C3> getKeyColumns() {
ArrayList<C3> keyColumns = new ArrayList<>(); ArrayList<C3> keyColumns = new ArrayList<>();
for (C3 column : this.skjdfhgdskjf674534) { for (C3 column : this.skjdfhgdskjf674534) {
if (column.isKey()) { if (column.isKey()) {
keyColumns.add(column); keyColumns.add(column);
} }
} }
return keyColumns; return keyColumns;
} }
public boolean hasAutoincrement() { public boolean hasAutoincrement() {
for (C3 column : this.skjdfhgdskjf674534) { for (C3 column : this.skjdfhgdskjf674534) {
if (column.isAutoincrement()) { if (column.isAutoincrement()) {
return true; return true;
} }
} }
return false; return false;
} }
public boolean columnExist(String colName) {
return this.skjdfhgdskjf674534.contains(new C3(colName));
}
public boolean isCreateInserts() {
return this.createInserts;
}
public long getJdshfalkajsd677676() {
public boolean columnExist(String colName) { return this.jdshfalkajsd677676;
return this.skjdfhgdskjf674534.contains(new C3(colName)); }
}
public void setJdshfalkajsd677676(long numberValues) {
this.jdshfalkajsd677676 = numberValues;
public boolean isCreateInserts() { }
return this.createInserts;
}
public ArrayList<T1> getDependsOnTable() {
return this.dependsOnTable;
public long getJdshfalkajsd677676() { }
return this.jdshfalkajsd677676;
}
public HashMap<T1, ArrayList<C3>> getColumnsOfDependentOnTable() {
return this.columnsOfDependentOnTable;
public void setJdshfalkajsd677676(long numberValues) { }
this.jdshfalkajsd677676 = numberValues;
}
public ArrayList<T1> getDependsOnTable() {
return this.dependsOnTable;
}
public HashMap<T1, ArrayList<C3>> getColumnsOfDependentOnTable() {
return this.columnsOfDependentOnTable;
}
} }

View File

@ -4,9 +4,9 @@ package at.fos.ermodel.gui;
public record T2(String tablename, String columnname) { public record T2(String tablename, String columnname) {
public String toString() { public String toString() {
return "RM_ForeignKeyType [tablename=" + this.tablename + ", columnname=" + this.columnname + "]"; return "RM_ForeignKeyType [tablename=" + this.tablename + ", columnname=" + this.columnname + "]";
} }
} }

View File

@ -14,263 +14,213 @@ import java.util.HashMap;
import java.util.Random; import java.util.Random;
public class T3 public class T3 {
{ public static HashMap<String, ArrayList<String>> randomData = new HashMap<>();
public static HashMap<String, ArrayList<String>> randomData = new HashMap<>();
public static String[] dsfsdfsdf4353534 = new String[] { public static String[] dsfsdfsdf4353534 = new String[]{
"No", "No",
"Extern", "Extern",
"Random Integer", "Random Integer",
"Random Decimal", "Random Decimal",
"Random Text", "Random Text",
"Random Date", "Random Date",
"Random Boolean", "Random Boolean",
"Random Color", "Random Color",
"Random Company", "Random Company",
"Random Country", "Random Country",
"Random Departmentname", "Random Departmentname",
"Random Firstname", "Random Firstname",
"Random Jobname", "Random Jobname",
"Random Language", "Random Language",
"Random Lastname", "Random Lastname",
"Random Mediacategory", "Random Mediacategory",
"Random Mediapublisher", "Random Mediapublisher",
"Random Mediatitle", "Random Mediatitle",
"Random Mediatype", "Random Mediatype",
"Random Place", "Random Place",
"Random Profession", "Random Profession",
"Random Rentalequipment", "Random Rentalequipment",
"Random Street" }; "Random Street"};
public static Object copyObject(Object objSource) { public static Object copyObject(Object objSource) {
Object objDest = null; Object objDest = null;
try { try {
ByteArrayOutputStream bos = new ByteArrayOutputStream(); ByteArrayOutputStream bos = new ByteArrayOutputStream();
ObjectOutputStream oos = new ObjectOutputStream(bos); ObjectOutputStream oos = new ObjectOutputStream(bos);
oos.writeObject(objSource); oos.writeObject(objSource);
oos.flush(); oos.flush();
oos.close(); oos.close();
bos.close(); bos.close();
byte[] byteData = bos.toByteArray(); byte[] byteData = bos.toByteArray();
ByteArrayInputStream bais = new ByteArrayInputStream(byteData); ByteArrayInputStream bais = new ByteArrayInputStream(byteData);
try { try {
objDest = (new ObjectInputStream(bais)).readObject(); objDest = (new ObjectInputStream(bais)).readObject();
} catch (ClassNotFoundException e) { } catch (ClassNotFoundException e) {
e.printStackTrace(); e.printStackTrace();
} }
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); e.printStackTrace();
} }
return objDest; return objDest;
} }
public static void asdasda345435ertretr(Node node, double yScale, double xScale, double contrast, double hue, double brightness, double saturation) {
ImageView iv = (ImageView) node;
iv.setScaleY(yScale);
iv.setScaleX(xScale);
ColorAdjust colorAdjust = new ColorAdjust();
colorAdjust.setContrast(contrast);
colorAdjust.setHue(hue);
colorAdjust.setBrightness(brightness);
colorAdjust.setSaturation(saturation);
iv.setEffect(colorAdjust);
}
public static void buttonMouseExited(Node node) {
ImageView iv = (ImageView) node;
iv.setScaleX(1.0D);
public static void asdasda345435ertretr(Node node, double yScale, double xScale, double contrast, double hue, double brightness, double saturation) { iv.setScaleY(1.0D);
ImageView iv = (ImageView)node; iv.setEffect(null);
}
iv.setScaleY(yScale);
iv.setScaleX(xScale);
ColorAdjust colorAdjust = new ColorAdjust();
colorAdjust.setContrast(contrast);
colorAdjust.setHue(hue);
colorAdjust.setBrightness(brightness);
colorAdjust.setSaturation(saturation);
iv.setEffect(colorAdjust);
}
public static void buttonMouseExited(Node node) {
ImageView iv = (ImageView)node;
iv.setScaleX(1.0D);
iv.setScaleY(1.0D);
iv.setEffect(null);
}
public static void fdssdf4354(Node node, Color color) { public static void fdssdf4354(Node node, Color color) {
DropShadow borderGlow = new DropShadow(); DropShadow borderGlow = new DropShadow();
borderGlow.setOffsetY(0.0D); borderGlow.setOffsetY(0.0D);
borderGlow.setOffsetX(0.0D); borderGlow.setOffsetX(0.0D);
borderGlow.setColor(color); borderGlow.setColor(color);
borderGlow.setWidth(10.0D); borderGlow.setWidth(10.0D);
borderGlow.setHeight(10.0D); borderGlow.setHeight(10.0D);
node.setEffect(borderGlow); node.setEffect(borderGlow);
}
public static String replaceSpecialChars(String text) {
text = text.replaceAll("ä", "ae");
text = text.replaceAll("ö", "oe");
text = text.replaceAll("ü", "ue");
text = text.replaceAll("ß", "ss");
text = text.replaceAll("[^\\w\\_]", "");
return text;
}
public static String getRandomInteger(int valuesVon, int valuesBis) {
int randomValue = valuesVon + (new Random()).nextInt(valuesBis - valuesVon) + 1;
return String.valueOf(randomValue);
}
public static String getRandomBoolean() {
boolean randomValue = (new Random()).nextBoolean();
String booleanAsString;
booleanAsString = "0";
if (randomValue) booleanAsString = "1";
return booleanAsString;
}
public static String getRandomDecimal(int digitsBeforeComma, int digitsAfterComma) {
StringBuilder digitsAfterCommaAsString = new StringBuilder();
StringBuilder digitsBeforeCommaAsString = new StringBuilder();
int i;
for (i = 0; i < digitsAfterComma; i++) {
digitsAfterCommaAsString.append("9");
} }
int digitsAfterCommaRange = Integer.parseInt((digitsAfterCommaAsString.length() == 0) ? "0" : digitsAfterCommaAsString.toString());
for (i = 0; i < digitsBeforeComma; i++) {
digitsBeforeCommaAsString.append("9"); public static String replaceSpecialChars(String text) {
text = text.replaceAll("ä", "ae");
text = text.replaceAll("ö", "oe");
text = text.replaceAll("ü", "ue");
text = text.replaceAll("ß", "ss");
text = text.replaceAll("[^\\w\\_]", "");
return text;
} }
int digitsBeforeCommaRange = Integer.parseInt(digitsBeforeCommaAsString.toString());
return (new Random()).nextInt(digitsBeforeCommaRange + 1) + "." + (new Random()).nextInt(digitsAfterCommaRange + 1);
}
public static String getRandomInteger(int valuesVon, int valuesBis) {
int randomValue = valuesVon + (new Random()).nextInt(valuesBis - valuesVon) + 1;
return String.valueOf(randomValue);
public static String getRandomTextGivenLength(int textLength) {
String str = "abcdefghijklmnopqrstuvwxyz";
StringBuilder randomText = new StringBuilder();
ArrayList<Character> charactersAsList = new ArrayList<>();
for (int j = 0; j < textLength; j++) {
charactersAsList.add(str.charAt((new Random()).nextInt(26)));
} }
for (int k = 0; k < charactersAsList.size(); ) { randomText.append(charactersAsList.get(k)); k++; }
return randomText.toString();
}
public static String getRandomBoolean() {
boolean randomValue = (new Random()).nextBoolean();
String booleanAsString;
booleanAsString = "0";
if (randomValue) booleanAsString = "1";
return booleanAsString;
}
public static String getRandomDate(LocalDate from, LocalDate till) {
Random random = new Random(); public static String getRandomDecimal(int digitsBeforeComma, int digitsAfterComma) {
int minDay = (int)LocalDate.of(from.getYear(), from.getMonth(), from.getDayOfMonth()).toEpochDay(); StringBuilder digitsAfterCommaAsString = new StringBuilder();
int maxDay = (int)LocalDate.of(till.getYear(), till.getMonth(), till.getDayOfMonth()).toEpochDay();
long randomDay = (minDay + random.nextInt(maxDay - minDay)); StringBuilder digitsBeforeCommaAsString = new StringBuilder();
LocalDate randomDate = LocalDate.ofEpochDay(randomDay); int i;
String datesAsString; for (i = 0; i < digitsAfterComma; i++) {
digitsAfterCommaAsString.append("9");
datesAsString = randomDate.getYear() + "-" + randomDate.getMonthValue() + "-" + randomDate.getDayOfMonth(); }
return datesAsString; int digitsAfterCommaRange = Integer.parseInt((digitsAfterCommaAsString.length() == 0) ? "0" : digitsAfterCommaAsString.toString());
} for (i = 0; i < digitsBeforeComma; i++) {
digitsBeforeCommaAsString.append("9");
}
int digitsBeforeCommaRange = Integer.parseInt(digitsBeforeCommaAsString.toString());
return (new Random()).nextInt(digitsBeforeCommaRange + 1) + "." + (new Random()).nextInt(digitsAfterCommaRange + 1);
}
public static void readRandomData(String which, String keyExtern) {
ArrayList<String> randomDataAsList; public static String getRandomTextGivenLength(int textLength) {
try { String str = "abcdefghijklmnopqrstuvwxyz";
BufferedReader fr; StringBuilder randomText = new StringBuilder();
ArrayList<Character> charactersAsList = new ArrayList<>();
if (which.equals("Extern")) { fr = C2.randomDataFilesExtern.get(keyExtern); } for (int j = 0; j < textLength; j++) {
else { fr = new BufferedReader(new InputStreamReader(C2.randomDataFiles.get(which))); } charactersAsList.add(str.charAt((new Random()).nextInt(26)));
randomDataAsList = new ArrayList<>(); }
String next = fr.readLine(); for (int k = 0; k < charactersAsList.size(); ) {
while (next != null) { randomText.append(charactersAsList.get(k));
randomDataAsList.add(next); k++;
next = fr.readLine(); }
} return randomText.toString();
fr.close(); }
if (which.equals("Extern")) { randomData.put(keyExtern, randomDataAsList); }
else { randomData.put(which, randomDataAsList); }
} catch (IOException e) { public static String getRandomDate(LocalDate from, LocalDate till) {
Random random = new Random();
e.printStackTrace(); int minDay = (int) LocalDate.of(from.getYear(), from.getMonth(), from.getDayOfMonth()).toEpochDay();
} int maxDay = (int) LocalDate.of(till.getYear(), till.getMonth(), till.getDayOfMonth()).toEpochDay();
} long randomDay = (minDay + random.nextInt(maxDay - minDay));
LocalDate randomDate = LocalDate.ofEpochDay(randomDay);
String datesAsString;
datesAsString = randomDate.getYear() + "-" + randomDate.getMonthValue() + "-" + randomDate.getDayOfMonth();
return datesAsString;
}
public static String getRandomData(String which, String keyExtern) { public static void readRandomData(String which, String keyExtern) {
ArrayList<String> randomDataAsList; ArrayList<String> randomDataAsList;
if (which.equals("Extern")) { randomDataAsList = randomData.get(keyExtern); } try {
else { randomDataAsList = randomData.get(which); } BufferedReader fr;
if (randomDataAsList == null) { if (which.equals("Extern")) {
readRandomData(which, keyExtern); fr = C2.randomDataFilesExtern.get(keyExtern);
} else {
fr = new BufferedReader(new InputStreamReader(C2.randomDataFiles.get(which)));
}
randomDataAsList = new ArrayList<>();
String next = fr.readLine();
while (next != null) {
randomDataAsList.add(next);
next = fr.readLine();
}
fr.close();
if (which.equals("Extern")) {
randomData.put(keyExtern, randomDataAsList);
} else {
randomData.put(which, randomDataAsList);
}
} catch (IOException e) {
e.printStackTrace();
}
}
public static String getRandomData(String which, String keyExtern) {
ArrayList<String> randomDataAsList;
if (which.equals("Extern")) {
randomDataAsList = randomData.get(keyExtern);
} else {
randomDataAsList = randomData.get(which);
}
if (randomDataAsList == null) {
readRandomData(which, keyExtern);
}
if (which.equals("Extern")) {
randomDataAsList = randomData.get(keyExtern);
} else {
randomDataAsList = randomData.get(which);
}
return randomDataAsList.get((new Random()).nextInt(randomDataAsList.size()));
} }
if (which.equals("Extern")) { randomDataAsList = randomData.get(keyExtern); }
else { randomDataAsList = randomData.get(which); }
return randomDataAsList.get((new Random()).nextInt(randomDataAsList.size()));
}
} }

View File

@ -1,87 +1,68 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
import javafx.scene.control.Alert; import javafx.scene.control.Alert;
import javafx.scene.control.ButtonType; import javafx.scene.control.ButtonType;
import javafx.scene.control.ScrollPane; import javafx.scene.control.ScrollPane;
import javafx.scene.control.Tab; import javafx.scene.control.Tab;
import javafx.scene.input.KeyEvent; import javafx.scene.input.KeyEvent;
import javafx.scene.layout.StackPane; import javafx.scene.layout.StackPane;
import java.io.File; import java.io.File;
import java.util.Optional; import java.util.Optional;
public class U1
extends Tab {
public final A3 canvas;
public final StackPane stackpane;
public final ScrollPane scrollpane;
public U1(B3 view, String name, File modelInFile) {
this.stackpane = new StackPane();
this.stackpane.setBackground(C2.AppBackground);
this.canvas = new A3(view, modelInFile, this);
this.stackpane.getChildren().add(this.canvas);
this.scrollpane = new ScrollPane(this.stackpane);
this.stackpane.setFocusTraversable(true);
this.scrollpane.setFocusTraversable(true);
public class U1
extends Tab this.scrollpane.setVmin(0.0D);
{ this.scrollpane.setVmax(this.canvas.getCanvasHeight());
public final A3 canvas; this.scrollpane.setHmin(0.0D);
public final StackPane stackpane; this.scrollpane.setHmax(this.canvas.getCanvasWidth());
public final ScrollPane scrollpane;
this.stackpane.addEventFilter(KeyEvent.ANY, e -> this.scrollpane.requestFocus());
public U1(B3 view, String name, File modelInFile) { this.scrollpane.addEventFilter(KeyEvent.ANY, e -> this.scrollpane.requestFocus());
this.stackpane = new StackPane();
this.stackpane.setBackground(C2.AppBackground); setOnCloseRequest(e -> {
this.canvas = new A3(view, modelInFile, this); if (getTabPane().getTabs().size() <= 1) {
e.consume();
this.stackpane.getChildren().add(this.canvas); return;
}
this.scrollpane = new ScrollPane(this.stackpane); C1 alert = new C1(null, Alert.AlertType.CONFIRMATION, "Close Tab", "", "Do you really want to close", Boolean.TRUE, C2.applicationImageIconAsICO, "OK", "Cancel", C2.ButtonBackgroundColor, C2.MouseSelectedColor, C2.FocusOnComponentColor);
this.stackpane.setFocusTraversable(true); Optional<ButtonType> result = alert.getResult();
this.scrollpane.setFocusTraversable(true); if (result.isPresent() && result.get() == ButtonType.OK) {
view.selectModeBTN.setSelected(true);
this.scrollpane.setVmin(0.0D); } else {
this.scrollpane.setVmax(this.canvas.getCanvasHeight()); e.consume();
this.scrollpane.setHmin(0.0D); }
this.scrollpane.setHmax(this.canvas.getCanvasWidth()); });
this.stackpane.addEventFilter(KeyEvent.ANY, e -> this.scrollpane.requestFocus());
this.scrollpane.addEventFilter(KeyEvent.ANY, e -> this.scrollpane.requestFocus()); this.scrollpane.setOnKeyPressed(U1.this.canvas::sdfdsfd567657rrt);
this.stackpane.setOnKeyPressed(U1.this.canvas::sdfdsfd567657rrt);
setOnCloseRequest(e -> {
if (getTabPane().getTabs().size() <= 1) { this.canvas.setOnKeyPressed(U1.this.canvas::sdfdsfd567657rrt);
e.consume();
return; setContent(this.scrollpane);
} if (modelInFile == null) {
C1 alert = new C1(null, Alert.AlertType.CONFIRMATION, "Close Tab", "", "Do you really want to close", Boolean.TRUE, C2.applicationImageIconAsICO, "OK", "Cancel", C2.ButtonBackgroundColor, C2.MouseSelectedColor, C2.FocusOnComponentColor); setText(name);
Optional<ButtonType> result = alert.getResult(); } else {
if (result.isPresent() && result.get() == ButtonType.OK) {
view.selectModeBTN.setSelected(true); setText(modelInFile.getName());
} else { }
e.consume(); this.canvas.requestFocus();
} }
}); }
this.scrollpane.setOnKeyPressed(U1.this.canvas::sdfdsfd567657rrt);
this.stackpane.setOnKeyPressed(U1.this.canvas::sdfdsfd567657rrt);
this.canvas.setOnKeyPressed(U1.this.canvas::sdfdsfd567657rrt);
setContent(this.scrollpane);
if (modelInFile == null) {
setText(name);
} else {
setText(modelInFile.getName());
}
this.canvas.requestFocus();
}
}

View File

@ -1,69 +1,69 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
public interface U2 { public interface U2 {
boolean getCreateColumn(); boolean getCreateColumn();
void setCreateColumn(boolean paramBoolean); void setCreateColumn(boolean paramBoolean);
String getColumnPostfix(); String getColumnPostfix();
void setColumnPostfix(String paramString); void setColumnPostfix(String paramString);
String getColumnName(); String getColumnName();
void setColumnName(String paramString); void setColumnName(String paramString);
String getMVRelationName(); String getMVRelationName();
void setMVRelationName(String paramString); void setMVRelationName(String paramString);
String getMVRelationNamePraefix(); String getMVRelationNamePraefix();
void setMVRelationNamePraefix(String paramString); void setMVRelationNamePraefix(String paramString);
String getDatatype(); String getDatatype();
void setDatatype(String paramString); void setDatatype(String paramString);
boolean isKey(); boolean isKey();
void setIsKey(boolean paramBoolean); void setIsKey(boolean paramBoolean);
boolean isAutoincrement(); boolean isAutoincrement();
void setIsAutoincrement(boolean paramBoolean); void setIsAutoincrement(boolean paramBoolean);
long getAutoincrementStartAt(); long getAutoincrementStartAt();
void setAutoincrementStartAt(long paramLong); void setAutoincrementStartAt(long paramLong);
boolean isUnique(); boolean isUnique();
void setIsUnique(boolean paramBoolean); void setIsUnique(boolean paramBoolean);
boolean isNullable(); boolean isNullable();
void setIsNullable(boolean paramBoolean); void setIsNullable(boolean paramBoolean);
String getDataGenerationType(); String getDataGenerationType();
void setDataGenerationType(String paramString); void setDataGenerationType(String paramString);
String getPar1(); String getPar1();
void setPar1(String paramString); void setPar1(String paramString);
String getPar2(); String getPar2();
void setPar2(String paramString); void setPar2(String paramString);
String getPar1_label(); String getPar1_label();
void setPar1_label(String paramString); void setPar1_label(String paramString);
String getPar2_label(); String getPar2_label();
void setPar2_label(String paramString); void setPar2_label(String paramString);
} }

View File

@ -1,25 +1,25 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
public interface U3 { public interface U3 {
boolean getCreateRelation(); boolean getCreateRelation();
void setCreateRelation(boolean paramBoolean); void setCreateRelation(boolean paramBoolean);
String getRelationPraefix(); String getRelationPraefix();
void setRelationPraefix(String paramString); void setRelationPraefix(String paramString);
String getRelationName(); String getRelationName();
void setRelationName(String paramString); void setRelationName(String paramString);
boolean getCreateInserts(); boolean getCreateInserts();
void setCreateInserts(boolean paramBoolean); void setCreateInserts(boolean paramBoolean);
long getNumberRowsToInsert(); long getNumberRowsToInsert();
void setNumberRowsToInsert(long paramLong); void setNumberRowsToInsert(long paramLong);
} }

View File

@ -1,8 +1,7 @@
package at.fos.ermodel.gui; package at.fos.ermodel.gui;
public enum U4 public enum U4 {
{ ADD, REMOVE
ADD, REMOVE
} }

View File

@ -12,98 +12,57 @@ import javafx.scene.layout.VBox;
import javafx.stage.Stage; import javafx.stage.Stage;
public class V1 public class V1
extends Stage extends Stage {
{ public static V1 thisActionMessageDialog;
public static V1 thisActionMessageDialog;
private final Label showFilename; private final Label showFilename;
private Thread th; private Thread th;
public V1(B3 siteCommanderFrame) { public V1(B3 siteCommanderFrame) {
thisActionMessageDialog = this; thisActionMessageDialog = this;
setTitle("Generate/Save SQL-Script"); setTitle("Generate/Save SQL-Script");
getIcons().add(C2.applicationImageIconAsICO);
getIcons().add(C2.applicationImageIconAsICO); ProgressBar progress = new ProgressBar();
ProgressBar progress = new ProgressBar(); progress.setPrefWidth(200.0D);
progress.setPrefWidth(200.0D); progress.setProgress(-1.0D);
progress.setProgress(-1.0D); VBox root = new VBox();
VBox root = new VBox(); progress.setBackground(new Background(new BackgroundFill(C2.ButtonBackgroundColor, CornerRadii.EMPTY, Insets.EMPTY)));
progress.setBackground(new Background(new BackgroundFill(C2.ButtonBackgroundColor, CornerRadii.EMPTY, Insets.EMPTY))); this.showFilename = new Label("");
this.showFilename = new Label(""); this.showFilename.setAlignment(Pos.CENTER);
this.showFilename.setAlignment(Pos.CENTER);
Scene scene = new Scene(root, 200.0D, 40.0D);
Scene scene = new Scene(root, 200.0D, 40.0D); root.getChildren().add(progress);
root.getChildren().add(progress); root.getChildren().add(this.showFilename);
root.getChildren().add(this.showFilename); setScene(scene);
setScene(scene);
if (siteCommanderFrame != null) {
if (siteCommanderFrame != null) { initOwner(siteCommanderFrame);
initOwner(siteCommanderFrame); }
sizeToScene();
setResizable(false);
} }
sizeToScene();
setResizable(false);
}
private void startTimer() { private void startTimer() {
this.th.setDaemon(true); this.th.setDaemon(true);
this.th.start(); this.th.start();
} }
public void setThread(Thread th) {
this.th = th;
startTimer();
showAndWait();
}
public Label getShowFilename() {
public void setThread(Thread th) { return this.showFilename;
this.th = th; }
startTimer();
showAndWait();
}
public Label getShowFilename() {
return this.showFilename;
}
} }

View File

@ -2,10 +2,9 @@ package at.fos.ermodel.gui;
public class ZZ20 public class ZZ20
extends Exception extends Exception {
{ public ZZ20(String arg0) {
public ZZ20(String arg0) { super(arg0);
super(arg0); }
}
} }

File diff suppressed because it is too large Load Diff

View File

@ -9,6 +9,5 @@
</content> </content>
<orderEntry type="inheritedJdk" /> <orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" /> <orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" name="soot.oss" level="project" />
</component> </component>
</module> </module>

3
obfuscate.bat Normal file
View File

@ -0,0 +1,3 @@
java -jar C:\Users\code0\javaObfuscation/SkidObfuscator.jar obfuscate out/artifacts/noEasyDB/noEasyDB.jar
mv out/artifacts/noEasyDB/noEasyDB.jar-out.jar ./
mv out/artifacts/noEasyDB/noEasyDB.jar ./