Skip to content

dulanjayabhanu/globemed-hms

Repository files navigation

Image of GlobeMed HMS main poster

GlobeMed Healthcare Management System

A demonstration of modern healthcare management using Java, JPA, and object-oriented design patterns

Image of the main dashboard screen

Introduction

The GlobeMed Healthcare Management System is a Java SE based desktop application developed as part of an advanced Object Oriented Design Patterns project. The system was designed not as a full commercial product but as a demonstration of how design patterns can be applied to real-world healthcare requirements. The application focuses on critical modules such as patient record management, appointment scheduling, billing and payment, role-based access control, report generation, and secure handling of sensitive healthcare data.

The purpose of this documentation is to provide a detailed description of the system architecture, development process, persistence approach, testing, and the role of design patterns in improving flexibility, maintainability, and scalability.

System Overview

The GlobeMed system simulates the operational requirements of a healthcare management platform. It integrates multiple modules that reflect the core operations of hospitals and clinics. Each module corresponds to a key requirement and demonstrates the application of a specific design pattern.

The software is built using Java SE, Maven for project management, and follows a layered architecture with separation of concerns. The system has been structured with clear package organization including model, dao, persistence, ui, util, and report, which ensures modularity and maintainability.

Persistence Approach

For persistence and database management, the system adopts JPA (Java Persistence API) with Hibernate ORM as the provider. The reason for this choice lies in the requirement for a universal and enterprise-ready persistence solution.

Using JPA allows the system to remain database-agnostic. This means that the application can be connected to different relational databases without rewriting persistence code. It also enables future integration with enterprise-level services that require standardized persistence management. Hibernate, as a robust implementation of JPA, provides advanced ORM features, caching, and efficient query handling.

Another important reason for selecting JPA + Hibernate is transaction management. The system uses a dedicated PersistenceManager class with a Singleton pattern to ensure consistent creation of EntityManagerFactory. Additionally, a TransactionTemplate class was introduced to simplify transaction execution, reducing code duplication for begin, commit, and rollback operations. This structure gives the system full control over transaction boundaries, ensures data consistency, and provides flexibility for implementing efficient transaction handling strategies.

Role of Design Patterns

The GlobeMed system was developed around the use of design patterns, each carefully selected to address a specific healthcare requirement.

  • Decorator Pattern: Used in patient record management to add authorization and logging dynamically without changing the base record structure. This ensures secure, layered access to sensitive patient data.
  • Mediator Pattern: Applied in appointment scheduling to centralize communication between patients and doctors while preventing direct coupling. This design allows conflict-free and real-time scheduling across multiple locations.
  • Chain of Responsibility Pattern: Implemented in billing and payments to process direct payments and insurance claims through a chain of handlers. This eliminated complex conditionals and improved modularity in billing workflows.
  • Composite Pattern: Used for role-based access control. Roles and permissions are modeled hierarchically, ensuring doctors, nurses, pharmacists, and administrators can access only the features they are entitled to.
  • Visitor Pattern: Applied to reporting. Different reports such as patient treatment summaries, diagnostic results, and financial reports are generated without modifying entity classes, supporting extensibility.
  • Compound Pattern (Decorator + Proxy): Implemented for special medical records to enforce multi-layered security. Proxy handles access control and verification, while Decorator adds encryption and audit logging dynamically.

The use of these patterns improves the system by enhancing modularity, promoting reusability, and adhering to software engineering principles such as the Open/Closed Principle. They make the system more maintainable and scalable, allowing new features and rules to be integrated without affecting the core logic.

Testing

Each module was tested independently to confirm that the selected design pattern was correctly implemented. For example, patient record management was tested with different user roles to ensure authorization decorators functioned correctly. Appointment scheduling was tested with multiple doctors and locations to verify that conflicts were handled in real time. Billing was validated with both direct and insurance workflows, ensuring that the chain of responsibility properly processed payments and claims.

Integration testing was performed to confirm that modules worked together as expected. For instance, a doctor with the correct role could access patient records, schedule appointments, and generate treatment reports, while unauthorized roles were appropriately restricted.

Documentation of Screenshots and Class Diagram

The documentation will include:

  • Screenshots of the application UI showing the patient record management interface, appointment scheduling, billing screens, reporting features, and security modules.
Image of the patient records management screen
Manage Patient Records Screen

Image of the appointment scheduling screen
Appointment Scheduling Screen

Image of the process insurance claims screen
Process Insurance Claiming Screen

Image of the report generating screen
Report Generating Screen

Image of the special medical records managing screen
Special Medical Records Manage Screen

Image of data entry managing screen
Data Entry Managing Screen

  • Full Class Diagram of the application, illustrating the package structure, key entities, DAO classes, and the design pattern implementations.
Image of the full class diagram of the GlobeMed HMS
Class Diagram Of GlobeMed HMS

These visual elements will provide a complete understanding of the system’s design and functionality.

Conclusion

The GlobeMed Healthcare Management System demonstrates how advanced object-oriented design patterns can be effectively applied to address real-world problems in healthcare management. By combining JPA with Hibernate for persistence, the system benefits from a universal and enterprise-ready approach to database management, offering robust transaction control and long-term scalability. The use of design patterns has enhanced security, reduced complexity, and ensured flexibility for future enhancements.

License

This project is licensed under the Apache License.