UNIVERSITY OF WEST ATTICA
SCHOOL OF ENGINEERING
DEPARTMENT OF COMPUTER ENGINEERING AND INFORMATICS
Software Engineering
Vasileios Evangelos Athanasiou
Student ID: 19390005
Supervision
Supervisor: Georgios Prezerakos, Professor
Athens, August 2023
This repository phase contains the full implementation of the Preze Cinemas Desktop system.
Phase 4 focuses on transforming previous analysis and design phases into a working desktop application.
The system is implemented using:
- Java Swing for the desktop graphical interface
- JDBC for database connectivity
- MySQL databases for cinema and banking operations
| Section | Folder/File | Description |
|---|---|---|
| 1 | assign/ |
Assignment instructions and supporting material |
| 1.1 | assign/seng_instructions_2022_23_v2.pdf |
Assignment instructions (English) |
| 1.2 | assign/λμηχ_οδηγίες_2022_23_β2.pdf |
Assignment instructions (Greek) |
| 2 | CinemaApplication/build/ |
Compiled application files and build artifacts |
| 2.1 | CinemaApplication/build/classes/cinemaapplication/ |
Compiled .class files for the CinemaApplication |
| 2.2 | CinemaApplication/build/classes/cinemaapplication/banksystem/BankSystem.class |
Bank system backend compiled class |
| 2.3 | CinemaApplication/build/.netbeans_automatic_build/ |
NetBeans automatic build metadata |
| 2.4 | CinemaApplication/build/.netbeans_update_resources/ |
NetBeans resource update files |
| 2.5 | CinemaApplication/build/built-jar.properties |
JAR build properties |
| 3 | CinemaApplication/nbproject/ |
NetBeans project configuration files |
| 3.1 | nbproject/private/ |
Private project settings (private.properties, private.xml) |
| 3.2 | build-impl.xml |
Ant build implementation file |
| 3.3 | genfiles.properties |
Generated file properties |
| 3.4 | project.properties |
Project properties |
| 3.5 | project.xml |
Project metadata |
| 4 | CinemaApplication/src/ |
Source code of the CinemaApplication |
| 4.1 | src/cinemaapplication/ |
Main package containing application .java files |
| 4.2 | src/cinemaapplication/banksystem/BankSystem.java |
Bank system source code |
| 4.3 | Other Java source files | Frames and application logic (CheckAvailabilityFrame.java, ChooseMovieFrame.java, etc.) |
| 5 | CinemaApplication/ |
Media and supporting files for the application |
| 5.1 | Bachelor2.png, Barbie.png, ... |
Movie posters and related images |
| 5.2 | build.xml |
Ant build script |
| 5.3 | manifest.mf |
Manifest file for JAR packaging |
| 5.4 | TicketsBill123.txt, TransactionReceiptPanos.txt, ... |
Sample tickets and transaction receipts |
| 6 | walkthrough/ |
Demonstration and walkthrough media |
| 6.1 | walkthrough/Cinema-Desktop-App-TL.mkv |
Video walkthrough of the Cinema Desktop Application |
| 7 | README.md |
Repository overview and usage instructions |
The goal of this phase is to implement all previously modeled use cases as executable components of the system.
Each major use case is translated into a Java Swing Frame, enabling user interaction and system operations through graphical windows.
The application uses Java Swing to build a desktop interface where:
- Each operation is represented as a separate window
- Navigation occurs between frames
- User inputs trigger database operations
Each use case corresponds to a dedicated class, such as:
CheckAvailabilityFrame.javaChooseMovieFrame.javaChooseTicketsFrame.javaChooseTimeViewFrame.javaPayFrame.javaDownloadTicketsFrame.java
Example:
CheckAvailabilityFrame.java checks ticket availability and determines whether the user can proceed to payment.
The system connects to MySQL databases through JDBC drivers.
Two databases are used:
Stores:
- Movies
- Screenings
- Available seats
- Reservations
- Customer information
Simulates payment processing by storing:
- Customer banking information
- Account balances
- Transaction updates
A separate module simulates an external bank system.
The BankSystem class performs:
- Transaction validation
- Account balance checks
- Payment execution
- Account amount updates
This module allows the cinema system to verify payments before completing reservations.
- User logs in or registers
- User selects movie and screening
- User selects tickets
- System checks availability
- Payment is validated via bank system
- Reservation is completed
- Receipt is generated
Each step corresponds to a frame interaction and database transaction.
| Folder/File | Description |
|---|---|
cinemaapplication/ |
Main application source code |
cinemaapplication/banksystem/ |
Banking system simulation module |
Frame.java files |
UI windows implementing each use case |
database/ |
SQL schema or setup scripts (if included) |
README.md |
Project documentation |
At the end of this phase:
- All system use cases are implemented
- GUI interaction is functional
- Database communication is operational
- Payment simulation is integrated
- Reservation workflow is executable
This phase results in a fully functional desktop cinema reservation prototype.
Phase 4 completes the transition from system design to implementation, delivering a working application capable of managing cinema reservations, availability checks, and payment validation through an integrated desktop system.
This guide will help you set up and run the Preze Cinemas Desktop application on your local machine.
- Java Development Kit (JDK 11 or later)
- NetBeans IDE (or any Java IDE supporting Swing & JDBC)
- MySQL Server (≥ 8.0 recommended)
- Download: https://dev.mysql.com/downloads/mysql/
- MySQL Workbench (optional, for database inspection)
- Git (optional, for cloning the repository)
- Command-line terminal
- Text editor for configuration file edits
git clone https://github.com/Preze-Cinemas-Desktop/Code.git
cd CodeThe project folder structure:
assign/
CinemaApplication/
README.mdCinemaApplication/ contains:
src/→ Java source files for GUI and business logicbuild/→ compiled .class filesnbproject/→ NetBeans project filesbuild.xml→ build scriptmanifest.mf→ JAR packaging file
The application requires two databases: cinema and bank.
- Log in to MySQL:
mysql -u root -p- Create databases:
CREATE DATABASE cinema;
CREATE DATABASE bank;If .sql scripts are provided in the repository (e.g., CinemaApplication/database/), import them:
mysql -u root -p cinema < cinema_schema.sql
mysql -u root -p bank < bank_schema.sqlIf no scripts are provided, manually create tables according to the project documentation:
- Cinema Database Tables:
movies,screenings,seats,reservations,customers - Bank Database Tables:
accounts,transactions,balances
Open the main configuration file (or CinemaApplication.java/BankSystem.java) and check the JDBC connection strings:
String urlCinema = "jdbc:mysql://localhost:3306/cinema";
String urlBank = "jdbc:mysql://localhost:3306/bank";
String user = "root";
String password = "your_mysql_password";Update the username and password to match your MySQL setup.
- Launch NetBeans IDE.
- Click File → Open Project.
- Navigate to
CinemaApplication/and select the folder. - NetBeans should detect the project as a Java application.
- Wait until the IDE fully loads the project and resolves dependencies.
- Right-click the project → Clean and Build.
- Check for compilation errors in the Output window.
- The executable
.classfiles will be generated inbuild/.
Right-click the main class CinemaApplication.java → Run File.
Or run from command line:
cd CinemaApplication/build/classes
java cinemaapplication.CinemaApplication- Login or Register: Start by creating a new user or logging in.
- Choose Movie: Select a movie and screening time.
- Select Tickets: Pick the number and type of tickets.
- Check Availability: Ensure tickets are available.
- Payment: Simulated via
BankSystem. - Download Receipts/Tickets: Save outputs as
.txt.
- JDBC Driver Not Found: Ensure
mysql-connector-java.jaris in the classpath. - Database Connection Error: Verify credentials and MySQL service status.
- GUI Issues: Use NetBeans’ “Clean and Build” to resolve corrupted Swing layouts.
- Payment Validation Errors: Ensure bank database contains sufficient account balances.
