A comprehensive Java-based command-line application for managing gym operations, including member registration, staff management, fitness classes, and equipment inventory.
- Register new members with unique IDs
- Update member information (contact, email, membership type)
- View member lists
- Remove members from the system
- Support for Standard and Premium membership types
- Staff authentication and login system
- Add new staff members
- Update staff information
- Remove staff members
- Role-based access control
- Schedule new fitness classes
- Update existing class details
- Search classes by various criteria
- Cancel classes
- View available classes
- Add new equipment to inventory
- Update equipment information
- Search equipment by name or description
- Delete equipment from inventory
- View complete equipment inventory
- Generate membership reports
- Class attendance reports
- Equipment inventory reports
- Export reports to files
- Auto-save functionality
- Manual save/load operations
- Serialization support for data persistence
- Java 8 or higher
- Command-line interface
- Minimum 512MB RAM
- 50MB free disk space
-
Clone the repository:
git clone https://github.com/username/gym-management-system.git cd gym-management-system -
Compile the Java files:
javac *.java -
Run the application:
java Main
The system comes with a default admin account:
- Staff ID: STF0000
- Password: admin
- Role: SysAdmin
- Login - Authenticate as a staff member
- Manage Staff - Add, update, or remove staff (requires login)
- Register New Member - Add new gym members (requires login)
- Update Member Information - Modify existing member details (requires login)
- Display Member List - View all registered members
- Remove Member - Delete member from system (requires login)
- Manage Fitness Classes - Schedule, update, or cancel classes (requires login)
- Display Available Classes - View all scheduled classes
- Manage Equipment - Add, update, or remove equipment (requires login)
- View Equipment Inventory - Display all equipment
- Generate Reports - Create various system reports (requires login)
- Logout - End current session
- Exit - Close the application
The system includes comprehensive input validation:
- Names: Only alphabetic characters and spaces
- Phone Numbers: Must be 10 digits
- Email: Must follow standard email format
- Time Format: HH:MM AM/PM format
- Membership Types: Standard or Premium only
- All data is automatically saved to serialized files
- Auto-save can be toggled on/off
- Manual save operations occur after major changes
- Data is loaded automatically on startup
Main.java- Entry point and application launcherGymInterface.java- Command-line interface handlerGymManagementSystem.java- Backend operationsMember.java- Member entity with unique ID generationStaff.java- Staff entity with authentication supportUser.java- Base class for Member and StaffFitnessClass.java- Fitness class entityEquipment.java- Equipment entity
InvalidUserException- Custom exception for user-related errorsInvalidClassException- Custom exception for class-related errors
- Secure login with staff ID and password
- Session management
- Role-based access control
- Members: MEM0001, MEM0002, etc.
- Staff: STF0001, STF0002, etc.
- Thread-safe unique ID generation
- Regex-based validation for all inputs
- Error handling with user-friendly messages
- Retry mechanisms for invalid inputs
- Search classes by ID, name, instructor, or capacity
- Search equipment by name or description
- Case-insensitive search options
The system includes comprehensive error handling:
- Input validation with clear error messages
- Exception handling for all operations
- Graceful handling of invalid user inputs
- Safe data persistence operations
- GUI interface using JavaFX or Swing
- Database integration (MySQL/PostgreSQL)
- Member check-in/check-out system
- Advanced reporting with charts
This project is licensed under the MIT License - see the LICENSE file for details.
For support or questions, please create an issue in the GitHub repository.
👥 Group Members & Their Contributions This project was developed as part of a group effort for our coursework(Comp 2120). Special thanks to my teammates
Paul Osuji Designed and implemented the command-line interface (CLI) Developed core logic for managing Members, Staff, Equipment, and Fitness Classes Implemented security features including login/logout and role-based access Created the abstract User class and object templates for all major entities Led overall system architecture, testing, and integration
Inan Syed Assisted with I/O programming and data persistence logic Contributed to the autosave feature using multithreading Participated in report generation logic and code reviews
Temirlan Rashid Contributed to custom exception handling and input validation Assisted with ID generation logic and regex-based validation Participated in testing, debugging, and code reviews
Note: This is a console-based application designed for educational purposes and small gym operations.