Você está na página 1de 6

Design Pattern Project Report

“Hospital Management System”

Project Members:

Submitted To:

Hospital Management:
Our project is based on hospital management system, in which we give rights to
Admin and User separately to use the system according to their limitations. We added
multiple modules related needed in Hospital management system, Admin can use his
own modules and User his own.
In this project, our main agenda is to optimize the system and try to solve
commonly occur problems in the development stage of the software. There are multiple
modules named as: Patient Registration, OPD, IPD, Information Desk, Staff
Management, Statistical Reports, Blood Bank, etc… We try to apply Design Patterns to
make this project feasible and efficient in working and produce less chance of errors.

Used Design Patterns:


We used 5 Design patterns:
1. Factory DP
2. Strategy DP
3. Facade DP
4. Singleton DP
5. Prototype DP

Here are some pictorial views of the project:

MAIN PAGE:
LOGIN PAGE:

ADMIN DASHBOARD PAGE:


PHARMACY PAGE:

BLOOD BANK PAGE:

Here are some coding examples:


Singleton:
class SingletonLogger
{
private static readonly SingletonLogger lgr = new
SingletonLogger();

private SingletonLogger()
{
}
public static SingletonLogger GetLogger()
{
return lgr;
}
}

private void LoginButton_Click(object sender, EventArgs e)


{
LoggingPerson obj = new LoggingPerson(textBox1,textBox2);
}

Facade:
public partial class Dashboard : MetroFramework.Forms.MetroForm
{
//Applying Facade for Admin

private pat_eg patReg;


private OPD opd;
private IPD ipd;
private info_desk info;
private Staff staff;
private BED bed;
private ward wardMngmnt;
private cash_billing cash;
private BloodBank bld;
private pharmacy phrmcy;
private Statistics stats;
public Dashboard()

{
InitializeComponent();
patReg = new pat_eg();
opd = new OPD();
ipd = new IPD();
info = new info_desk();
staff = new Staff();
bed = new BED();
wardMngmnt = new ward();
cash = new cash_billing();
bld = new BloodBank();
phrmcy = new pharmacy();
stats = new Statistics();
}
}

Factory:
public interface FactoryForCash
{
void showing();
}

class FactoryIPD:FactoryForCash
{
cash_billing obj;
public void showing()
{
obj.panel3.Hide();
obj.panel1.Show();
}
}

class FactoryOPD:FactoryForCash
{
cash_billing obj;
public void showing()
{
obj.panel1.Hide();
obj.panel3.Show();
}
}

And other design patterns applied…

Você também pode gostar