├── .gitignore
├── .idea
├── .gitignore
├── artifacts
│ └── JavaFXApp.xml
├── compiler.xml
├── description.html
├── encodings.xml
├── gradle.xml
├── libraries
│ ├── lib.xml
│ └── lib1.xml
├── misc.xml
├── modules.xml
├── project-template.xml
├── uiDesigner.xml
└── vcs.xml
├── Cruise Ship.iml
├── LICENCE
├── README.md
└── src
└── sample
├── 1.fxml
├── 2.fxml
├── 3.fxml
├── 4.fxml
├── 5.fxml
├── 8.fxml
├── 9.fxml
├── Controller.java
├── Controller1.java
├── Controller2.java
├── Controller3.java
├── Controller4.java
├── Controller5.java
├── Controller8.java
├── Controller9.java
├── Main.java
├── db.java
├── sample.fxml
└── style.css
/.gitignore:
--------------------------------------------------------------------------------
1 | # Project exclude paths
2 | /out/
--------------------------------------------------------------------------------
/.idea/.gitignore:
--------------------------------------------------------------------------------
1 | # Default ignored files
2 | /shelf/
3 | /workspace.xml
4 |
--------------------------------------------------------------------------------
/.idea/artifacts/JavaFXApp.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | $PROJECT_DIR$/out/artifacts/JavaFXApp
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/.idea/compiler.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/.idea/description.html:
--------------------------------------------------------------------------------
1 | Simple JavaFX 2.0 application that includes simple .fxml file with attached controller and Main class to quick start. Artifact to build JavaFX application is provided.
2 |
--------------------------------------------------------------------------------
/.idea/encodings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/.idea/gradle.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/.idea/libraries/lib.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/.idea/libraries/lib1.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/.idea/misc.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/.idea/project-template.xml:
--------------------------------------------------------------------------------
1 |
2 | IJ_JAVAFX_VERSION
3 |
--------------------------------------------------------------------------------
/.idea/uiDesigner.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | -
6 |
7 |
8 | -
9 |
10 |
11 | -
12 |
13 |
14 | -
15 |
16 |
17 | -
18 |
19 |
20 |
21 |
22 |
23 | -
24 |
25 |
26 |
27 |
28 |
29 | -
30 |
31 |
32 |
33 |
34 |
35 | -
36 |
37 |
38 |
39 |
40 |
41 | -
42 |
43 |
44 |
45 |
46 | -
47 |
48 |
49 |
50 |
51 | -
52 |
53 |
54 |
55 |
56 | -
57 |
58 |
59 |
60 |
61 | -
62 |
63 |
64 |
65 |
66 | -
67 |
68 |
69 |
70 |
71 | -
72 |
73 |
74 | -
75 |
76 |
77 |
78 |
79 | -
80 |
81 |
82 |
83 |
84 | -
85 |
86 |
87 |
88 |
89 | -
90 |
91 |
92 |
93 |
94 | -
95 |
96 |
97 |
98 |
99 | -
100 |
101 |
102 | -
103 |
104 |
105 | -
106 |
107 |
108 | -
109 |
110 |
111 | -
112 |
113 |
114 |
115 |
116 | -
117 |
118 |
119 | -
120 |
121 |
122 |
123 |
124 |
125 |
126 |
--------------------------------------------------------------------------------
/.idea/vcs.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/Cruise Ship.iml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/LICENCE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2023 Dasun Thathsara
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Cabin-Booking-System-GUI
2 | Cabin Booking System
3 |
4 |
5 |
6 |
7 |
8 |
9 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/src/sample/1.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
24 |
32 |
40 |
48 |
53 |
58 |
63 |
68 |
73 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
92 |
97 |
102 |
107 |
112 |
117 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
--------------------------------------------------------------------------------
/src/sample/2.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
23 |
31 |
39 |
47 |
52 |
57 |
62 |
67 |
72 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
91 |
96 |
101 |
106 |
111 |
116 |
121 |
126 |
131 |
136 |
141 |
146 |
151 |
152 |
153 |
154 |
155 |
--------------------------------------------------------------------------------
/src/sample/3.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
22 |
30 |
38 |
46 |
51 |
56 |
61 |
66 |
71 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
--------------------------------------------------------------------------------
/src/sample/4.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
24 |
32 |
40 |
48 |
53 |
58 |
63 |
68 |
73 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
92 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
112 |
117 |
122 |
123 |
124 |
125 |
126 |
--------------------------------------------------------------------------------
/src/sample/5.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
24 |
32 |
40 |
48 |
53 |
58 |
63 |
68 |
73 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
92 |
97 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
117 |
122 |
123 |
124 |
125 |
126 |
--------------------------------------------------------------------------------
/src/sample/8.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
23 |
31 |
39 |
47 |
52 |
57 |
62 |
67 |
72 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
91 |
96 |
101 |
106 |
111 |
116 |
121 |
126 |
131 |
136 |
141 |
146 |
151 |
156 |
161 |
166 |
171 |
176 |
181 |
186 |
191 |
196 |
201 |
206 |
211 |
216 |
221 |
222 |
223 |
224 |
225 |
--------------------------------------------------------------------------------
/src/sample/9.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
23 |
31 |
39 |
47 |
52 |
57 |
62 |
67 |
72 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
91 |
96 |
101 |
106 |
111 |
116 |
121 |
126 |
131 |
136 |
141 |
146 |
151 |
156 |
161 |
166 |
171 |
176 |
181 |
186 |
191 |
196 |
201 |
206 |
211 |
216 |
221 |
222 |
223 |
224 |
225 |
--------------------------------------------------------------------------------
/src/sample/Controller.java:
--------------------------------------------------------------------------------
1 | package sample;
2 |
3 | import javafx.event.ActionEvent;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.Node;
7 | import javafx.scene.Parent;
8 | import javafx.scene.Scene;
9 | import javafx.stage.Stage;
10 | import java.io.IOException;
11 |
12 | public class Controller {
13 |
14 | @FXML
15 | private Stage stage;
16 | private Scene scene;
17 | private Parent root;
18 |
19 | @FXML
20 | private void UI1btn(ActionEvent event) throws IOException {
21 | Parent root = FXMLLoader.load(getClass().getResource("1.fxml"));
22 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
23 | scene = new Scene(root);
24 | stage.setScene(scene);
25 | stage.show();
26 | }
27 | @FXML
28 | private void UI2btn(ActionEvent event) throws IOException {
29 | Parent root = FXMLLoader.load(getClass().getResource("2.fxml"));
30 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
31 | scene = new Scene(root);
32 | stage.setScene(scene);
33 | stage.show();
34 | }
35 | @FXML
36 | private void UI3btn(ActionEvent event) throws IOException {
37 | Parent root = FXMLLoader.load(getClass().getResource("3.fxml"));
38 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
39 | scene = new Scene(root);
40 | stage.setScene(scene);
41 | stage.show();
42 | }
43 | @FXML
44 | private void UI4btn(ActionEvent event) throws IOException {
45 | Parent root = FXMLLoader.load(getClass().getResource("4.fxml"));
46 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
47 | scene = new Scene(root);
48 | stage.setScene(scene);
49 | stage.show();
50 | }
51 | @FXML
52 | private void UI5btn(ActionEvent event) throws IOException {
53 | Parent root = FXMLLoader.load(getClass().getResource("5.fxml"));
54 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
55 | scene = new Scene(root);
56 | stage.setScene(scene);
57 | stage.show();
58 | }
59 | @FXML
60 | private void UI6btn(ActionEvent event) throws IOException {
61 | Parent root = FXMLLoader.load(getClass().getResource("6.fxml"));
62 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
63 | scene = new Scene(root);
64 | stage.setScene(scene);
65 | stage.show();
66 | }
67 | @FXML
68 | private void UI7btn(ActionEvent event) throws IOException {
69 | Parent root = FXMLLoader.load(getClass().getResource("7.fxml"));
70 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
71 | scene = new Scene(root);
72 | stage.setScene(scene);
73 | stage.show();
74 | }
75 | @FXML
76 | private void UI8btn(ActionEvent event) throws IOException {
77 | Parent root = FXMLLoader.load(getClass().getResource("8.fxml"));
78 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
79 | scene = new Scene(root);
80 | stage.setScene(scene);
81 | stage.show();
82 | }
83 | @FXML
84 | private void UI9btn(ActionEvent event) throws IOException {
85 | Parent root = FXMLLoader.load(getClass().getResource("9.fxml"));
86 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
87 | scene = new Scene(root);
88 | stage.setScene(scene);
89 | stage.show();
90 | }
91 | }
92 |
--------------------------------------------------------------------------------
/src/sample/Controller1.java:
--------------------------------------------------------------------------------
1 | package sample;
2 |
3 | import javafx.event.ActionEvent;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.Node;
7 | import javafx.scene.Parent;
8 | import javafx.scene.Scene;
9 | import javafx.stage.Stage;
10 |
11 | import java.io.IOException;
12 |
13 | public class Controller1 {
14 |
15 | @FXML
16 | private Stage stage;
17 | private Scene scene;
18 | private Parent root;
19 |
20 | @FXML
21 | private void UI0btn(ActionEvent event) throws IOException {
22 | Parent root = FXMLLoader.load(getClass().getResource("sample.fxml"));
23 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
24 | scene = new Scene(root);
25 | stage.setScene(scene);
26 | stage.show();
27 | }
28 | @FXML
29 | private void UI2btn(ActionEvent event) throws IOException {
30 | Parent root = FXMLLoader.load(getClass().getResource("2.fxml"));
31 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
32 | scene = new Scene(root);
33 | stage.setScene(scene);
34 | stage.show();
35 | }
36 | @FXML
37 | private void UI3btn(ActionEvent event) throws IOException {
38 | Parent root = FXMLLoader.load(getClass().getResource("3.fxml"));
39 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
40 | scene = new Scene(root);
41 | stage.setScene(scene);
42 | stage.show();
43 | }
44 | @FXML
45 | private void UI4btn(ActionEvent event) throws IOException {
46 | Parent root = FXMLLoader.load(getClass().getResource("4.fxml"));
47 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
48 | scene = new Scene(root);
49 | stage.setScene(scene);
50 | stage.show();
51 | }
52 | @FXML
53 | private void UI5btn(ActionEvent event) throws IOException {
54 | Parent root = FXMLLoader.load(getClass().getResource("5.fxml"));
55 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
56 | scene = new Scene(root);
57 | stage.setScene(scene);
58 | stage.show();
59 | }
60 | @FXML
61 | private void UI6btn(ActionEvent event) throws IOException {
62 | Parent root = FXMLLoader.load(getClass().getResource("6.fxml"));
63 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
64 | scene = new Scene(root);
65 | stage.setScene(scene);
66 | stage.show();
67 | }
68 | @FXML
69 | private void UI7btn(ActionEvent event) throws IOException {
70 | Parent root = FXMLLoader.load(getClass().getResource("7.fxml"));
71 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
72 | scene = new Scene(root);
73 | stage.setScene(scene);
74 | stage.show();
75 | }
76 | @FXML
77 | private void UI8btn(ActionEvent event) throws IOException {
78 | Parent root = FXMLLoader.load(getClass().getResource("8.fxml"));
79 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
80 | scene = new Scene(root);
81 | stage.setScene(scene);
82 | stage.show();
83 | }
84 | @FXML
85 | private void UI9btn(ActionEvent event) throws IOException {
86 | Parent root = FXMLLoader.load(getClass().getResource("9.fxml"));
87 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
88 | scene = new Scene(root);
89 | stage.setScene(scene);
90 | stage.show();
91 | }
92 | }
93 |
--------------------------------------------------------------------------------
/src/sample/Controller2.java:
--------------------------------------------------------------------------------
1 | package sample;
2 |
3 | import javafx.event.ActionEvent;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.Node;
7 | import javafx.scene.Parent;
8 | import javafx.scene.Scene;
9 | import javafx.stage.Stage;
10 |
11 | import java.io.IOException;
12 |
13 | public class Controller2 {
14 | @FXML
15 | private Stage stage;
16 | private Scene scene;
17 | private Parent root;
18 |
19 | @FXML
20 | private void UI0btn(ActionEvent event) throws IOException {
21 | Parent root = FXMLLoader.load(getClass().getResource("sample.fxml"));
22 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
23 | scene = new Scene(root);
24 | stage.setScene(scene);
25 | stage.show();
26 | }
27 | @FXML
28 | private void UI1btn(ActionEvent event) throws IOException {
29 | Parent root = FXMLLoader.load(getClass().getResource("1.fxml"));
30 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
31 | scene = new Scene(root);
32 | stage.setScene(scene);
33 | stage.show();
34 | }
35 | @FXML
36 | private void UI2btn(ActionEvent event) throws IOException {
37 | Parent root = FXMLLoader.load(getClass().getResource("2.fxml"));
38 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
39 | scene = new Scene(root);
40 | stage.setScene(scene);
41 | stage.show();
42 | }
43 | @FXML
44 | private void UI3btn(ActionEvent event) throws IOException {
45 | Parent root = FXMLLoader.load(getClass().getResource("3.fxml"));
46 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
47 | scene = new Scene(root);
48 | stage.setScene(scene);
49 | stage.show();
50 | }
51 | @FXML
52 | private void UI4btn(ActionEvent event) throws IOException {
53 | Parent root = FXMLLoader.load(getClass().getResource("4.fxml"));
54 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
55 | scene = new Scene(root);
56 | stage.setScene(scene);
57 | stage.show();
58 | }
59 | @FXML
60 | private void UI5btn(ActionEvent event) throws IOException {
61 | Parent root = FXMLLoader.load(getClass().getResource("5.fxml"));
62 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
63 | scene = new Scene(root);
64 | stage.setScene(scene);
65 | stage.show();
66 | }
67 | @FXML
68 | private void UI6btn(ActionEvent event) throws IOException {
69 | Parent root = FXMLLoader.load(getClass().getResource("6.fxml"));
70 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
71 | scene = new Scene(root);
72 | stage.setScene(scene);
73 | stage.show();
74 | }
75 | @FXML
76 | private void UI7btn(ActionEvent event) throws IOException {
77 | Parent root = FXMLLoader.load(getClass().getResource("7.fxml"));
78 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
79 | scene = new Scene(root);
80 | stage.setScene(scene);
81 | stage.show();
82 | }
83 | @FXML
84 | private void UI8btn(ActionEvent event) throws IOException {
85 | Parent root = FXMLLoader.load(getClass().getResource("8.fxml"));
86 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
87 | scene = new Scene(root);
88 | stage.setScene(scene);
89 | stage.show();
90 | }
91 | @FXML
92 | private void UI9btn(ActionEvent event) throws IOException {
93 | Parent root = FXMLLoader.load(getClass().getResource("9.fxml"));
94 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
95 | scene = new Scene(root);
96 | stage.setScene(scene);
97 | stage.show();
98 | }
99 | }
100 |
--------------------------------------------------------------------------------
/src/sample/Controller3.java:
--------------------------------------------------------------------------------
1 | package sample;
2 |
3 | import javafx.event.ActionEvent;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.Node;
7 | import javafx.scene.Parent;
8 | import javafx.scene.Scene;
9 | import javafx.stage.Stage;
10 |
11 | import java.io.IOException;
12 |
13 | public class Controller3 {
14 | @FXML
15 | private Stage stage;
16 | private Scene scene;
17 | private Parent root;
18 |
19 | @FXML
20 | private void UI0btn(ActionEvent event) throws IOException {
21 | Parent root = FXMLLoader.load(getClass().getResource("sample.fxml"));
22 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
23 | scene = new Scene(root);
24 | stage.setScene(scene);
25 | stage.show();
26 | }
27 | @FXML
28 | private void UI1btn(ActionEvent event) throws IOException {
29 | Parent root = FXMLLoader.load(getClass().getResource("1.fxml"));
30 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
31 | scene = new Scene(root);
32 | stage.setScene(scene);
33 | stage.show();
34 | }
35 | @FXML
36 | private void UI2btn(ActionEvent event) throws IOException {
37 | Parent root = FXMLLoader.load(getClass().getResource("2.fxml"));
38 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
39 | scene = new Scene(root);
40 | stage.setScene(scene);
41 | stage.show();
42 | }
43 | @FXML
44 | private void UI4btn(ActionEvent event) throws IOException {
45 | Parent root = FXMLLoader.load(getClass().getResource("4.fxml"));
46 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
47 | scene = new Scene(root);
48 | stage.setScene(scene);
49 | stage.show();
50 | }
51 | @FXML
52 | private void UI5btn(ActionEvent event) throws IOException {
53 | Parent root = FXMLLoader.load(getClass().getResource("5.fxml"));
54 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
55 | scene = new Scene(root);
56 | stage.setScene(scene);
57 | stage.show();
58 | }
59 | @FXML
60 | private void UI6btn(ActionEvent event) throws IOException {
61 | Parent root = FXMLLoader.load(getClass().getResource("6.fxml"));
62 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
63 | scene = new Scene(root);
64 | stage.setScene(scene);
65 | stage.show();
66 | }
67 | @FXML
68 | private void UI7btn(ActionEvent event) throws IOException {
69 | Parent root = FXMLLoader.load(getClass().getResource("7.fxml"));
70 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
71 | scene = new Scene(root);
72 | stage.setScene(scene);
73 | stage.show();
74 | }
75 | @FXML
76 | private void UI8btn(ActionEvent event) throws IOException {
77 | Parent root = FXMLLoader.load(getClass().getResource("8.fxml"));
78 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
79 | scene = new Scene(root);
80 | stage.setScene(scene);
81 | stage.show();
82 | }
83 | @FXML
84 | private void UI9btn(ActionEvent event) throws IOException {
85 | Parent root = FXMLLoader.load(getClass().getResource("9.fxml"));
86 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
87 | scene = new Scene(root);
88 | stage.setScene(scene);
89 | stage.show();
90 | }
91 | }
92 |
--------------------------------------------------------------------------------
/src/sample/Controller4.java:
--------------------------------------------------------------------------------
1 | package sample;
2 |
3 | import javafx.event.ActionEvent;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.Node;
7 | import javafx.scene.Parent;
8 | import javafx.scene.Scene;
9 | import javafx.stage.Stage;
10 |
11 | import java.io.IOException;
12 |
13 | public class Controller4 {
14 | @FXML
15 | private Stage stage;
16 | private Scene scene;
17 | private Parent root;
18 |
19 | @FXML
20 | private void UI0btn(ActionEvent event) throws IOException {
21 | Parent root = FXMLLoader.load(getClass().getResource("sample.fxml"));
22 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
23 | scene = new Scene(root);
24 | stage.setScene(scene);
25 | stage.show();
26 | }
27 | @FXML
28 | private void UI1btn(ActionEvent event) throws IOException {
29 | Parent root = FXMLLoader.load(getClass().getResource("1.fxml"));
30 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
31 | scene = new Scene(root);
32 | stage.setScene(scene);
33 | stage.show();
34 | }
35 | @FXML
36 | private void UI2btn(ActionEvent event) throws IOException {
37 | Parent root = FXMLLoader.load(getClass().getResource("2.fxml"));
38 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
39 | scene = new Scene(root);
40 | stage.setScene(scene);
41 | stage.show();
42 | }
43 | @FXML
44 | private void UI3btn(ActionEvent event) throws IOException {
45 | Parent root = FXMLLoader.load(getClass().getResource("3.fxml"));
46 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
47 | scene = new Scene(root);
48 | stage.setScene(scene);
49 | stage.show();
50 | }
51 | @FXML
52 | private void UI5btn(ActionEvent event) throws IOException {
53 | Parent root = FXMLLoader.load(getClass().getResource("5.fxml"));
54 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
55 | scene = new Scene(root);
56 | stage.setScene(scene);
57 | stage.show();
58 | }
59 | @FXML
60 | private void UI6btn(ActionEvent event) throws IOException {
61 | Parent root = FXMLLoader.load(getClass().getResource("6.fxml"));
62 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
63 | scene = new Scene(root);
64 | stage.setScene(scene);
65 | stage.show();
66 | }
67 | @FXML
68 | private void UI7btn(ActionEvent event) throws IOException {
69 | Parent root = FXMLLoader.load(getClass().getResource("7.fxml"));
70 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
71 | scene = new Scene(root);
72 | stage.setScene(scene);
73 | stage.show();
74 | }
75 | @FXML
76 | private void UI8btn(ActionEvent event) throws IOException {
77 | Parent root = FXMLLoader.load(getClass().getResource("8.fxml"));
78 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
79 | scene = new Scene(root);
80 | stage.setScene(scene);
81 | stage.show();
82 | }
83 | @FXML
84 | private void UI9btn(ActionEvent event) throws IOException {
85 | Parent root = FXMLLoader.load(getClass().getResource("9.fxml"));
86 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
87 | scene = new Scene(root);
88 | stage.setScene(scene);
89 | stage.show();
90 | }
91 | }
92 |
--------------------------------------------------------------------------------
/src/sample/Controller5.java:
--------------------------------------------------------------------------------
1 | package sample;
2 |
3 | import javafx.event.ActionEvent;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.Node;
7 | import javafx.scene.Parent;
8 | import javafx.scene.Scene;
9 | import javafx.stage.Stage;
10 |
11 | import java.io.IOException;
12 |
13 | public class Controller5 {
14 | @FXML
15 | private Stage stage;
16 | private Scene scene;
17 | private Parent root;
18 |
19 | @FXML
20 | private void UI0btn(ActionEvent event) throws IOException {
21 | Parent root = FXMLLoader.load(getClass().getResource("sample.fxml"));
22 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
23 | scene = new Scene(root);
24 | stage.setScene(scene);
25 | stage.show();
26 | }
27 | @FXML
28 | private void UI1btn(ActionEvent event) throws IOException {
29 | Parent root = FXMLLoader.load(getClass().getResource("1.fxml"));
30 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
31 | scene = new Scene(root);
32 | stage.setScene(scene);
33 | stage.show();
34 | }
35 | @FXML
36 | private void UI2btn(ActionEvent event) throws IOException {
37 | Parent root = FXMLLoader.load(getClass().getResource("2.fxml"));
38 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
39 | scene = new Scene(root);
40 | stage.setScene(scene);
41 | stage.show();
42 | }
43 | @FXML
44 | private void UI3btn(ActionEvent event) throws IOException {
45 | Parent root = FXMLLoader.load(getClass().getResource("3.fxml"));
46 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
47 | scene = new Scene(root);
48 | stage.setScene(scene);
49 | stage.show();
50 | }
51 | @FXML
52 | private void UI4btn(ActionEvent event) throws IOException {
53 | Parent root = FXMLLoader.load(getClass().getResource("4.fxml"));
54 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
55 | scene = new Scene(root);
56 | stage.setScene(scene);
57 | stage.show();
58 | }
59 | @FXML
60 | private void UI6btn(ActionEvent event) throws IOException {
61 | Parent root = FXMLLoader.load(getClass().getResource("6.fxml"));
62 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
63 | scene = new Scene(root);
64 | stage.setScene(scene);
65 | stage.show();
66 | }
67 | @FXML
68 | private void UI7btn(ActionEvent event) throws IOException {
69 | Parent root = FXMLLoader.load(getClass().getResource("7.fxml"));
70 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
71 | scene = new Scene(root);
72 | stage.setScene(scene);
73 | stage.show();
74 | }
75 | @FXML
76 | private void UI8btn(ActionEvent event) throws IOException {
77 | Parent root = FXMLLoader.load(getClass().getResource("8.fxml"));
78 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
79 | scene = new Scene(root);
80 | stage.setScene(scene);
81 | stage.show();
82 | }
83 | @FXML
84 | private void UI9btn(ActionEvent event) throws IOException {
85 | Parent root = FXMLLoader.load(getClass().getResource("9.fxml"));
86 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
87 | scene = new Scene(root);
88 | stage.setScene(scene);
89 | stage.show();
90 | }
91 | }
92 |
--------------------------------------------------------------------------------
/src/sample/Controller8.java:
--------------------------------------------------------------------------------
1 | package sample;
2 |
3 | import javafx.event.ActionEvent;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.Node;
7 | import javafx.scene.Parent;
8 | import javafx.scene.Scene;
9 | import javafx.stage.Stage;
10 |
11 | import java.io.IOException;
12 |
13 | public class Controller8 {
14 | @FXML
15 | private Stage stage;
16 | private Scene scene;
17 | private Parent root;
18 |
19 | @FXML
20 | private void UI0btn(ActionEvent event) throws IOException {
21 | Parent root = FXMLLoader.load(getClass().getResource("sample.fxml"));
22 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
23 | scene = new Scene(root);
24 | stage.setScene(scene);
25 | stage.show();
26 | }
27 | @FXML
28 | private void UIbtn(ActionEvent event) throws IOException {
29 | Parent root = FXMLLoader.load(getClass().getResource("1.fxml"));
30 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
31 | scene = new Scene(root);
32 | stage.setScene(scene);
33 | stage.show();
34 | }
35 | @FXML
36 | private void UI2btn(ActionEvent event) throws IOException {
37 | Parent root = FXMLLoader.load(getClass().getResource("2.fxml"));
38 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
39 | scene = new Scene(root);
40 | stage.setScene(scene);
41 | stage.show();
42 | }
43 | @FXML
44 | private void UI3btn(ActionEvent event) throws IOException {
45 | Parent root = FXMLLoader.load(getClass().getResource("3.fxml"));
46 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
47 | scene = new Scene(root);
48 | stage.setScene(scene);
49 | stage.show();
50 | }
51 | @FXML
52 | private void UI4btn(ActionEvent event) throws IOException {
53 | Parent root = FXMLLoader.load(getClass().getResource("4.fxml"));
54 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
55 | scene = new Scene(root);
56 | stage.setScene(scene);
57 | stage.show();
58 | }
59 | @FXML
60 | private void UI5btn(ActionEvent event) throws IOException {
61 | Parent root = FXMLLoader.load(getClass().getResource("5.fxml"));
62 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
63 | scene = new Scene(root);
64 | stage.setScene(scene);
65 | stage.show();
66 | }
67 | @FXML
68 | private void UI6btn(ActionEvent event) throws IOException {
69 | Parent root = FXMLLoader.load(getClass().getResource("6.fxml"));
70 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
71 | scene = new Scene(root);
72 | stage.setScene(scene);
73 | stage.show();
74 | }
75 | @FXML
76 | private void UI7btn(ActionEvent event) throws IOException {
77 | Parent root = FXMLLoader.load(getClass().getResource("7.fxml"));
78 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
79 | scene = new Scene(root);
80 | stage.setScene(scene);
81 | stage.show();
82 | }
83 | @FXML
84 | private void UI8btn(ActionEvent event) throws IOException {
85 | Parent root = FXMLLoader.load(getClass().getResource("8.fxml"));
86 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
87 | scene = new Scene(root);
88 | stage.setScene(scene);
89 | stage.show();
90 | }
91 | @FXML
92 | private void UI9btn(ActionEvent event) throws IOException {
93 | Parent root = FXMLLoader.load(getClass().getResource("9.fxml"));
94 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
95 | scene = new Scene(root);
96 | stage.setScene(scene);
97 | stage.show();
98 | }
99 | }
100 |
--------------------------------------------------------------------------------
/src/sample/Controller9.java:
--------------------------------------------------------------------------------
1 | package sample;
2 |
3 | import javafx.event.ActionEvent;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.Node;
7 | import javafx.scene.Parent;
8 | import javafx.scene.Scene;
9 | import javafx.stage.Stage;
10 |
11 | import java.io.IOException;
12 |
13 | public class Controller9 {
14 | @FXML
15 | private Stage stage;
16 | private Scene scene;
17 | private Parent root;
18 |
19 | @FXML
20 | private void UI0btn(ActionEvent event) throws IOException {
21 | Parent root = FXMLLoader.load(getClass().getResource("sample.fxml"));
22 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
23 | scene = new Scene(root);
24 | stage.setScene(scene);
25 | stage.show();
26 | }
27 | @FXML
28 | private void UIbtn(ActionEvent event) throws IOException {
29 | Parent root = FXMLLoader.load(getClass().getResource("1.fxml"));
30 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
31 | scene = new Scene(root);
32 | stage.setScene(scene);
33 | stage.show();
34 | }
35 | @FXML
36 | private void UI2btn(ActionEvent event) throws IOException {
37 | Parent root = FXMLLoader.load(getClass().getResource("2.fxml"));
38 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
39 | scene = new Scene(root);
40 | stage.setScene(scene);
41 | stage.show();
42 | }
43 | @FXML
44 | private void UI3btn(ActionEvent event) throws IOException {
45 | Parent root = FXMLLoader.load(getClass().getResource("3.fxml"));
46 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
47 | scene = new Scene(root);
48 | stage.setScene(scene);
49 | stage.show();
50 | }
51 | @FXML
52 | private void UI4btn(ActionEvent event) throws IOException {
53 | Parent root = FXMLLoader.load(getClass().getResource("4.fxml"));
54 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
55 | scene = new Scene(root);
56 | stage.setScene(scene);
57 | stage.show();
58 | }
59 | @FXML
60 | private void UI5btn(ActionEvent event) throws IOException {
61 | Parent root = FXMLLoader.load(getClass().getResource("5.fxml"));
62 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
63 | scene = new Scene(root);
64 | stage.setScene(scene);
65 | stage.show();
66 | }
67 | @FXML
68 | private void UI6btn(ActionEvent event) throws IOException {
69 | Parent root = FXMLLoader.load(getClass().getResource("6.fxml"));
70 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
71 | scene = new Scene(root);
72 | stage.setScene(scene);
73 | stage.show();
74 | }
75 | @FXML
76 | private void UI7btn(ActionEvent event) throws IOException {
77 | Parent root = FXMLLoader.load(getClass().getResource("7.fxml"));
78 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
79 | scene = new Scene(root);
80 | stage.setScene(scene);
81 | stage.show();
82 | }
83 | @FXML
84 | private void UI8btn(ActionEvent event) throws IOException {
85 | Parent root = FXMLLoader.load(getClass().getResource("8.fxml"));
86 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
87 | scene = new Scene(root);
88 | stage.setScene(scene);
89 | stage.show();
90 | }
91 | @FXML
92 | private void UI9btn(ActionEvent event) throws IOException {
93 | Parent root = FXMLLoader.load(getClass().getResource("9.fxml"));
94 | stage = (Stage)((Node)event.getSource()).getScene().getWindow();
95 | scene = new Scene(root);
96 | stage.setScene(scene);
97 | stage.show();
98 | }
99 | }
100 |
--------------------------------------------------------------------------------
/src/sample/Main.java:
--------------------------------------------------------------------------------
1 | package sample;
2 |
3 | import javafx.application.Application;
4 | import javafx.fxml.FXMLLoader;
5 | import javafx.scene.Parent;
6 | import javafx.scene.Scene;
7 | import javafx.stage.Stage;
8 |
9 | public class Main extends Application {
10 |
11 | @Override
12 | public void start(Stage primaryStage) throws Exception{
13 | Parent root = FXMLLoader.load(getClass().getResource("sample.fxml"));
14 | primaryStage.setTitle("Cabin Booking System");
15 | primaryStage.setScene(new Scene(root, 600, 400));
16 | primaryStage.setResizable(false);
17 | primaryStage.show();
18 | }
19 |
20 |
21 | public static void main(String[] args) {
22 | launch(args);
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/src/sample/db.java:
--------------------------------------------------------------------------------
1 | package sample;
2 |
3 | import java.sql.Connection;
4 | import java.sql.DriverManager;
5 | import java.sql.SQLException;
6 |
7 | public class db {
8 | private static String HOST = "localhost";
9 | private static int PORT = 8080;
10 | private static String DB_NAME = "hotel";
11 | private static String USERNAME = "root";
12 | private static String PASSWORD = "";
13 | private static Connection connection;
14 |
15 |
16 | public static Connection getConnection (){
17 | try {
18 | connection = DriverManager.getConnection((String.format("jdbc:mysql://%s:%d/%s", HOST, PORT, DB_NAME)));
19 | } catch (SQLException e) {
20 | throw new RuntimeException(e);
21 | }
22 |
23 |
24 | return connection;
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/src/sample/sample.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
23 |
31 |
39 |
47 |
52 |
57 |
62 |
67 |
72 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
91 |
92 |
93 |
94 |
95 |
--------------------------------------------------------------------------------
/src/sample/style.css:
--------------------------------------------------------------------------------
1 | .btn{
2 | -fx-background-radius: 0;
3 | -fx-background-color:black;
4 | -fx-text-fill:white;
5 | }
6 |
7 | .btn: hover{
8 | -fx-background-color:white;
9 | -fx-text-fill:black;
10 | }
11 |
12 | .selected_btn{
13 | -fx-background-color:white;
14 | -fx-text-fill:black;
15 | -fx-background-radius: 0;
16 | }
17 |
--------------------------------------------------------------------------------