Skip to content

The Vehicle Rental System. It simulates a basic rental service where users can rent, return, and view vehicles such as cars and motorcycles

Notifications You must be signed in to change notification settings

gptdevansh/Vehicle-Rental-System

ย 
ย 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

34 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿš— Vehicle Rental System

A simple GUI-based Java application to manage a vehicle rental system using OOP concepts. It allows users to rent and return vehicles, view available vehicles, and track rentals through a unique rental ID.


๐Ÿ“Œ Features

  • Rent vehicles (Car / Motorcycle)
  • Return rented vehicles using Rental ID
  • View available vehicles
  • Unique rental ID generation (e.g., RC5, RM3)
  • Basic input validation and error handling
  • GUI with colorful modern buttons and font styling

๐Ÿงฑ Technologies Used

  • Java (JDK 8 or higher)
  • Swing for GUI
  • OOP Concepts (Encapsulation, Inheritance, Composition)
  • IntelliJ

๐Ÿ—‚๏ธ Project Structure

VehicleRentalSystem/ โ”‚ โ”œโ”€โ”€ models/ # Vehicle, Car, Motorcycle, Customer classes โ”œโ”€โ”€ system/ # RentalSystem, DataStore classes โ”œโ”€โ”€ ui/ # GUI interfaces (MainMenuUI, RentalFormUI, ReturnFormUI, UIDesign ) โ””โ”€โ”€ VehicleRentalSystem.java # Entry point of the application


๐Ÿš€ How to Run

  1. Clone the repository or download the ZIP.
  2. Open the project in your preferred Java IDE.
  3. Compile the entire project.
  4. Run VehicleRentalSystem.java to launch the application.

๐ŸŽฎ Usage

Rent a Vehicle:

  • Click on Rent Vehicle
  • Select a vehicle
  • Enter your Name and Contact Number
  • Youโ€™ll get a unique rental ID like RC3

Return a Vehicle:

  • Click on Return Vehicle
  • Enter your Rental ID (e.g., RM5)
  • Vehicle will be returned and added back to availability

Validation

  • Contact number must be numeric and 10 digits
  • Name field cannot be empty
  • Rental ID format is validated during return

๐Ÿ“Œ Notes

  • No database integration; data is stored in memory using ArrayLists.
  • Data is reset every time the application restarts.
  • You can add more sample vehicles in DataStore for testing.

๐Ÿ“ง Contact

For improvements or questions, feel free to reach out!


About

The Vehicle Rental System. It simulates a basic rental service where users can rent, return, and view vehicles such as cars and motorcycles

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 100.0%