A Java-based Car Rental Management System that allows customers to browse and book cars while providing administrators with powerful tools to manage vehicles, bookings, and users. The application features a user-friendly Swing GUI, MySQL database integration, and role-based authentication.
The Car Rental Management System simplifies the process of renting and managing vehicles. Customers can create accounts, browse available cars, make bookings, and manage reservations. Administrators can oversee the entire system through a dedicated dashboard.
- User Registration & Login
- Browse Available Cars
- View Car Details
- Book Cars with Rental Dates
- Automatic Rental Cost Calculation
- View Booking History
- Cancel Existing Bookings
- Manage Personal Profile
- Secure Admin Login
- Admin Dashboard
- Add New Cars
- Update Car Information
- Delete Cars
- View All Bookings
- Update Booking Status
- Manage User Accounts
- Generate Reports & Statistics
- Filter Bookings by Status
- Role-Based Authentication (Admin & Customer)
- MySQL Database Integration
- JDBC Connectivity
- Secure Password Handling
- Real-Time Data Updates
- User-Friendly Swing GUI
- Modular and Maintainable Code Structure
| Technology | Purpose |
|---|---|
| Java (JDK 11+) | Core Programming Language |
| Swing | Graphical User Interface |
| JDBC | Database Connectivity |
| MySQL | Database Management |
| XAMPP | Local Development Environment |
- Operating System: Windows 10/11, macOS, or Linux
- RAM: 4 GB (8 GB Recommended)
- Storage: 500 MB Free Space
- Java JDK: Version 11 or Higher
- MySQL: Version 8.0 or Higher
- IntelliJ IDEA
- Eclipse
- VS Code with Java Extensions
Car-Rental-System/
β
βββ src/
β βββ main/
β βββ models/
β βββ services/
β βββ database/
β βββ ui/
β
βββ bin/
β
βββ lib/
β βββ mysql-connector-java-8.0.33.jar
β
βββ database/
β βββ car_rental.sql
β
βββ README.md
Download and install Java JDK 11 or higher:
- Oracle JDK: https://www.oracle.com/java/technologies/downloads/
- OpenJDK: https://adoptium.net/
Verify installation:
java --version
javac --versionChoose one of the following:
- Download XAMPP
- Start Apache and MySQL
- Open phpMyAdmin
Download: https://www.apachefriends.org/
Download: https://dev.mysql.com/downloads/workbench/
CREATE DATABASE car_rental_system;- Open phpMyAdmin or MySQL Workbench
- Create the database
- Import the provided SQL file
Modify your database connection settings:
String url = "jdbc:mysql://localhost:3306/car_rental_system";
String username = "root";
String password = "";javac -d bin src/**/*.javajava -cp "bin;lib\mysql-connector-java-8.0.33.jar" main.Mainjava -cp "bin:lib/mysql-connector-java-8.0.33.jar" main.Main| Username | Password |
|---|---|
| admin | admin123 |
| Username | Password |
|---|---|
| john_doe | john123 |
- Register a new account or login.
- Browse available cars.
- Select a vehicle.
- Choose rental dates.
- Confirm booking.
- View booking history.
- Cancel bookings if necessary.
- Login as Administrator.
- Access the Dashboard.
- Manage vehicles.
- View and manage bookings.
- Manage users.
- Generate reports and monitor system activity.
Project Video:
https://drive.google.com/drive/folders/1jOLPBdL-NDSlbEiPSF4JgYLIZViaJjIg?usp=sharing
- Ensure MySQL server is running.
- Verify database credentials.
- Confirm database exists.
Make sure the MySQL connector is inside the lib folder:
mysql-connector-java-8.0.33.jar
Check Java installation:
java --version- Online Payment Integration
- Email Notifications
- Vehicle Image Upload
- PDF Invoice Generation
- Advanced Analytics Dashboard
- Mobile Application Version
- Multi-Language Support
- REST API Integration