My Project Documentation
My Project Documentation
ABSTRACT
Wellbeing indicator is a JAVA based standalone application which is intended to developed and
provide an easy and simple way services for both doctors and patients. The main objective of this
application is to design and develop in a real time, to help out patients and other end users
suffering from various diseases, or medical emergence can communicate with doctors or medical
assistance through online mode and can resolve their queries.Most of the times doctors are not be
available when the patients visit to hospital. Such sort of issues can be resolved through
Wellbeing Indicator.
INTRODUCTION
Wellbeing indicator is an application developed for patients, other end users and doctors. This
application is JAVA and MySQL based application which helps users to know if they are
suffering from any diseases, also the application suggests doctors. The main objective of this
project is to build an application which will help the users and doctors have a conversation
through application and all the queries of users can be solved. Sometimes doctors may not be
available all the time and also users may not be able to visit the hospital in their busy schedule
this application provides the users to know if they are suffering from any diseases through the
symptoms. This helps the users to skip the long procedure of visiting the hospital. Also, the
conversation between doctors and users are made available which made doctors available all the
time. Here the system allows users to get instant guidance on their health issues through this
wellbeing indicator. The system is fed with various symptoms and the disease associated with
that symptoms. This system not only shows the type of the disease but also suggests the doctor
for that disease. This is fully unique system and we are sure that it will be helpful for hospital as
well they can add this with their existing feature. Hope this will be very demandable in coming
future. The proposed system states that the patients/user(s) can access their mobile phone at any
place, anytime to manage their minor illness by providing their symptoms.
PROBLEM STATEMENT
To design and develop a java based application, which provides an interface between doctors and
patients to check the availability of a doctor and to know if they are suffering from any disease
through the symptoms.
EXISTING SYSTEM
In this present scenario most of the people are following the traditional way through visiting the
hospitals and meeting the doctor in physical mode. But due to the busy schedule people are
unable to wait in long queues and patents are unable to manage their time, and also lot of paper
work.
PROPOSED SYSTEM
The proposed system is to design an application which brings doctors and patients/user under a
same platform which makes the interaction easier through online.
OBJECTIVES
1. To learn how to design and program java applications
2. To learn how to build and package modules reusability using java
3. To learn how to design object-oriented programs
4. To learn how to use exception handling in java applications for error handling
5. To learn how to build online web application using eclipse
ADVANTAGES
1. Interaction between doctors and users become easier
2. User can know his disease by the symptoms
3. This application suggest the doctor according to the users disease
IDE : Eclipse
Database : MySQL 5.5
SYSTEM ANALYSIS
It is a process of studying and identifying the problem defined earlier by the client in the
requirement phase. The general system analysis deals with the system behavior for the input
values provided by the end user(s). the primary purpose of system analysis is a methodology of
the system and its components or modules function together according to the objectives specified
by the user.
The fundamental objective of system analysis is to ensure that the proposed system will meet the
client needs and can be delivered in time and also to provide the operational efficiency too. The
analysis made on the said project “WELLBEING INDICATOR” will give the clear idea of
“what the system should do” as specified in the objectives by the end user, the proposed system
must function through the interface and Data base modules to ensure the integrity and efficiency
of the system components. Each component of a system will work effectively accordingly to user
inputs and can be stored and retrieved with proper database designs made in next phase of the
project.
SYSTEM DESIGN
The initial phase of the proposed application incorporated one of the basic software design
modules of the software engineering such as waterfall model; this model illustrates the software
development process in a linear sequential flow. This means that any phase in the development
process begins only if the previous phase is complete. The application is designed with the
following 3 modules:
Login Module
Register Module
Disease Prediction
view Tips
Login Module: Admin, doctor and user all can be able to login into the application by providing
the username and the password where unauthorized login will be restricted.
Register Module: Here the doctors and user (s) register with their details. Here there are are
some fields are given to fill the details and create an account. They can further login by
providing username and password which were set by themselves.
Disease prediction: Here the user(s) can know their disease by providing the symptoms and if
the user is already registered then they can get the specialist doctor details, if the new user wants
to meet the doctor then they should enroll their details and login to the application.
View Tips: here the user(s) who visited the application can see the tips option where they can
view the tips for different diseases and know the control measures.
This document plays a vital role in development of life cycle as it describes the complete
requirements of the system. This project is waterfall model based; it was the first process model
to be introduced. It is also referred to as a linear sequential life cycle model. It is very simple to
understand and use. In a waterfall model, each phase must be completed before the next phase
can begin and there is no overlapping in the phase. This model illustrates the software
development process in a linear sequential flow. This means that any phase in the development
process begins only if the previous phase is complete.
Class Diagram
A class diagram in the unified modeling language (UML) is a type of static structure diagram
that describes the structure of the system by showing the system classes, their attributes,
operations and the relationships among objects. The class diagram is the main building block of
object-oriented modeling
details
Search ( )
Add ( ) Check( )
Delete ( ) Tips Create account ( )
Disease predication
Symptoms:
Get Info ()
select
Submit ( )
User
Username : varchar
Password : varchar
Gender : varchar
Ph number : bigint
Password : varchar
Age : int
USECASE DIAGRAM
Use Case Model is an approach that is a combination of text and pictures in order to improve the
understanding of requirements. A use case model describes the complete functionality of a
system by identifying how everything that is outside the system interacts with it. A use case
diagram is given below that relates to this application. The project is a java application that
maintains the user and doctor details disease prediction and control measures on particular
diseases (TIPS).
ADMIN
REGISTERATION
DISEASE PREDICTION
ADMIN ADMIN/USER
TIPS
SEQUENCE DIAGRAM
A sequence diagram shows object interactions arranged in time sequence. It depicts the objects
and classes involved in the scenario and the sequence of messages exchanged between the
objects needed to carry out the functionality of the scenario. A sequence diagram is a type of
interaction diagram it describes how and in what order A group of objects works together.
1.Login
2. Password
3. Successful
4. Access to application
7. Stores in db
12.Suggest doctor
13. Tips
15.Logout
E-R DIAGRAM
Entity Relationship modeling is a data modeling method used in software engineering to produce
a conceptual data model of an information system. Diagrams created using this Entity
Relationship modeling method are called Entity-Relationship Diagrams. An Entity Relationship
Diagram (ERD) is a visual representation of different entities within a system and how they
relate to each other. ADMIN
MANAGES
MANAGES
MANAGES
GENDER
USER. DETAILS
LOGIN DR. DETAILS USERNAME
PH NUMBER
AGE
USERNAME
DR. NAME
PASSWORD
PASSWORD
NAME
SPECIALISATION
USER
MANAGES MANAGES
MANAGES
DISEASE TIPS
DR. DETAILS
PREDICATION
SYMPTIOM 1
NAME
HEADACHE
FEVER
PH NUMBER SYMPTIOM 2
DISEASE
COMMON COLD
GENDER
SYMPTIOM 3
3
SPECILASTION
DATABASE TABLES
ATTRIBUTES DATA TYPE SIZE NULL PRIMARY KEY
Docname varchar 20 No -
gender varchar 20 No -
specialist varchar 20 No -
Ph.number bigint 10 No -
username varchar 20 No Yes
password varchar 20 No -
Name Varchar 20 No -
gender Varchar 20 No -
age Varchar 20 No -
Ph.number Bigint 10 No -
password Varchar 20 No -
IMPLEMENTATION
Implementation is the stage of the project theoretical design is turned into working system. It can
be considered to be the most critical stage in the achieving successful new system and in giving
the user, confidence that the new system will work and effective. The goal of the coding phase is
to translate the design into code in the given programming language. The coding steps translate
the detailed design of the system into programming language. The translation process continuous
when the compiler accepts source code as input and produces machine dependent object code as
output linking of object files are done to produce the machine code. Internal document is another
important factor to facilitate others to understand the code and the logic.
SOFTWARE’S USED
INTRODUCTION TO JAVA
JAVA COMPONENTS
Java Virtual Machine (JVM): JVM executes the byte code generated by compiler. This
is called program run phase.
Java Development Kit (JDK) :Java development kit includes JRE (Java Runtime
Environment), compilers and various tools like JavaDoc, Java debugger etc..In order to
create, compile and run Java program We need JDK installed on computer
Java Runtime Environment (JRE): JRE is a part of JDK which means that JDK
includes JRE.. JRE includes JVM, browser plug-in and applets support.
FEATURES OF JAVA:
Robust
Simple
Secured
Distributed
Object oriented
Portable
Compilation and execution of a Java program is two step process. During compilation phase Java
compiler compiles the source code and generates byte code. This intermediate byte code is saved
in form of a .class file. In second phase, Java virtual machine (JVM) also called Java interpreter
takes the .class as input and generates output by executing the byte code. Java is an object
oriented programming language; therefore, a program in Java is made of one or more classes. No
matter how trivial a Java program is, it must be written in form of a class.
ECLIPSE
Eclipse is an integrated development environment (IDE) for developing applications using the
Java programming language and other programming languages such as C/C++, Python, PERL,
Ruby etc..The Eclipse platform which provides the foundation for the Eclipse IDE is composed
of plug-ins and is designed to be extensible using additional plug-ins. Developed using Java, the
Eclipse platform can be used to develop rich client applications, integrated development
environments and other tools. Eclipse can be used as an IDE for any programming language for
which a plug-in is available.
The Java Development Tools (JDT) project provides a plug-in that allows Eclipse to be used as a
Java IDE, PyDev is a plug in that allows Eclipse to be used as a Python IDE, C/C++
Development Tools (CDT) is a plug-in that allows Eclipse to be used for developing application
using C/C++, the Eclipse Scala plug-in allows Eclipse to be used an IDE to develop Scala
applications and PHPeclipse is a plug-in to eclipse that provides complete development tool for
PHP.
XAMPP:it is an abbreviation for cross-platform, apache, MySQL, PHP and perl, and it allows
you to build word press site offline, on a local web server on your computer. This simple and
lightweight solution works on windows, linex, and Mac- hence the “cross-platform” part since
word press is not a stand-alone application, XAMPP provides two essential components for its
installation- apache, which is used to create the local server, and MySQL which you can use a
database for your website.
MySQL DATABASE
A database is a structured collection of data. It may be anything from a simple shopping list to a
picture gallery or the vast amounts of information in a corporate network. To add, access, and
process data stored in a computer database, you need a database management system such as
MySQL server. Since computers are very good at handling large amounts of data, Database
management system play a central role in computing, as standalone utilities, Or as parts of other
applications. MySQL is the world’s most popularopen sourcedatabase. With its proven
performance, reliability and ease-of-use, MySQL has become leading database choice for web-
based applications, used in high profile web properties including Facebook, Twitter, YouTube,
and Yahoo! And many more. Oracle drivers MySQL innovation, delivering new capabilities to
power next generation web, cloud, mobile and embedded applications. It organizes data into one
or more data tables in which the data types may be related to each other, these relations helps
structure of the database. Following are some features of MySQL.
SAMPLE CODING
Admin login page using
Admin can login only through proper username and password. The variables username and
password is taken
from textfield and is checked with username by using simple string matching.
btnSubmit.addActionListener(new ActionListener() {
try {
if(username.contains("admin123") &&password.contains("1234"))
{ user.setText(null);
passwordtf.setText (null);
dispose();
adminpage.main(null);}
else
JOptionPane.showMessageDialog(null, "Invalid
login","Loginerror",JOptionPane.ERROR_MESSAGE);
passwordtf.setText(null);
user.setText(null);}}
error",JOptionPane.ERROR_MESSAGE);}}});
Admin can login only through proper username and password. The variables username and
password is taken
from textfield and is checked with username by using simple string matching.
btnSubmit.addActionListener(new ActionListener() {
try {
if(username.contains("admin123") &&password.contains("1234"))
{ user.setText(null);
passwordtf.setText(null);
dispose();
adminpage.main(null);}
else
JOptionPane.showMessageDialog(null, "Invalid
login","Loginerror",JOptionPane.ERROR_MESSAGE);
passwordtf.setText(null);
user.setText(null);}}
error",JOptionPane.ERROR_MESSAGE);}}});
Password of admin is taken only in the form of numbers and only 4-digit valid pin number. The
below part of
code which is implemented with the help of “addKeyListener” is the keyword used for validation
of pin code.
passwordtf.addKeyListener(new KeyAdapter() {
//@Override
int count = 0;
try {
int i= Integer.parseInt(passwordtf.getText());
err.setText("");
count ++;
{ err.setText(""); }
catch(NumberFormatException e13)
});
When admin successfully logs in he can now view, add, edit and search details of doctors and
users.
btnNewButton.addActionListener(new ActionListener() {
dispose();
doctorsdetails.main(null);
});
btnViewPatientDetails.addActionListener(new ActionListener() {
dispose();
userdetails.main(null); }});
Display of doctors and users details using Mysql connector and fetching data from
database:
try {
Connection
conn=DriverManager.getConnection("jdbc:mysql://127.0.0.1:3306/miniproject","root","");
int li_row=0;
while(rs.next())
{ table.setValueAt(rs.getString("cusername"),li_row,1);
table.setValueAt(rs.getString("name"),li_row,0);
table.setValueAt(rs.getString("age"),li_row,3);
table.setValueAt(rs.getString("phonenumber"),li_row,4);
table.setValueAt(rs.getString("password"),li_row,5);
li_row++;}}
catch(Exception e26)
{}
try { Class.forName("com.mysql.jdbc.Driver");
int var = 0;
while(var<11) {
table.setValueAt((null),var,0);
table.setValueAt((null),var,1);
table.setValueAt((null),var,2);
table.setValueAt((null),var,3);
table.setValueAt((null),var,4);
table.setValueAt((null),var,5);
var++;
Connection conn =
DriverManager.getConnection("jdbc:mysql://127.0.0.1:3306/miniproject","root","");
while(rs1.next())
{ table.setValueAt(rs1.getString("cusername"),si_row,1);
table.setValueAt(rs1.getString("name"),si_row,0);
table.setValueAt(rs1.getString("gender"),si_row,2);
table.setValueAt(rs1.getString("age"),si_row,3);
table.setValueAt(rs1.getString("phonenumber"),si_row,4);
table.setValueAt(rs1.getString("password"),si_row,5);
si_row++;
} conn.close();
try {
Connection
con=DriverManager.getConnection("jdbc:mysql://127.0.0.1:3306/miniproject","root","");
PreparedStatementpst= con.prepareStatement(sql);
pst.executeUpdate();
JOptionPane.showMessageDialog(null, "Deleted","Update
info",JOptionPane.PLAIN_MESSAGE);
Catch(Exception e27)
{ System.out.println(e27);
User must enter details like name, gender, age, phone number, username and password.
btnSubmit.addActionListener(new ActionListener() {
try {
Class.forName("com.mysql.jdbc.Driver");
Connection conn =
DriverManager.getConnection("jdbc:mysql://127.0.0.1:3306/miniproject","root","");
ps.setString(1, cname.getText());
ps.setString(4, phonenumber.getText());
ps.setString(5, username.getText());
ps.setString(6, password.getText());
int zx = ps.executeUpdate();
if(zx>0) {System.out.println("Sucessful");}
else{System.out.println("Unsucessful");}
String ph = phonenumber.getText();
error",JOptionPane.ERROR_MESSAGE); }
else {
cname.setText(null);
gender.setName(null);
phonenumber.setText(null);
password.setText(null);
username.setText(null);
JOptionPane.showMessageDialog(null, "Sucessfullyupdated","Login
info",JOptionPane.PLAIN_MESSAGE);
dispose();
userloginpage.main(null);}}
This function verifies if the key typed is integer or character and throws an exception. If the
number entered is
phonenumber.addKeyListener(new KeyAdapter() {
invalid.setText("");
int count = 0;
count +=1;
{ invalid.setText(""); } }
catch(NumberFormatException e13)
btnNewButton_1.addActionListener(new ActionListener() {
String s1 = ((String)symptom1.getSelectedItem());
String s2 = ((String)symptom3.getSelectedItem());
String s3 = ((String)symptom2.getSelectedItem());
try {
s3.equals("Symptom 3"))
else{ errormsg.setText("");
s2.equals("Irritability") || s3.equals("Irritability"))
resulttext.setText("Covid-19");
covid19.setText("Alert! "
+ "If you are suffering from Covid-19 please stay at home and immedieately consult nearest
health
s2.equals("Sweating") || s3.equals("Sweating") )
{resulttext.setText("Typhoid or Malaria");}
else{resulttext.setText(s1+","+s2+","+s3);}}
{resulttext.setText("Allergies &Asthama");}
else resulttext.setText(s1+","+s2+","+s3); }
resulttext.setText("Diabetes");}
else resulttext.setText(s1+","+s2+","+s3);}}
//If the entered symptoms is valid then doctors details are fetched from database and is displayed
in table.
btnNewButton.addActionListener(new ActionListener() {
if(ser.equals(null))
else{ try {
Class.forName("com.mysql.jdbc.Driver");
int var = 0;
while(var<5) {
table.setValueAt((null),var,0);
table.setValueAt((null),var,1);
var++;}
Connection conn =
DriverManager.getConnection("jdbc:mysql://127.0.0.1:3306/miniproject","root","");
specialist ='"+ser+"';");
while(rs1.next()) {
table.setValueAt(rs1.getString("docname"),si_row,0);
table.setValueAt(rs1.getString("phonenumber"),si_row,1);
conn.close();}
Doctor must enter details like name, gender, specialized field, phone number, username and
password to
btnSubmit.addActionListener(new ActionListener() {
try {
Class.forName("com.mysql.jdbc.Driver");
Connection conn =
DriverManager.getConnection("jdbc:mysql://127.0.0.1:3306/miniproject","root","");
ps.setString(1, cname.getText());
ps.setString(4, phonenumber.getText());
ps.setString(5, username.getText());
ps.setString(6, password.getText());
int zx = ps.executeUpdate();
if(zx>0) {System.out.println("Sucessful");}
else{System.out.println("Unsucessful");}
String ph = phonenumber.getText();
error",JOptionPane.ERROR_MESSAGE); }
else {
cname.setText(null);
gender.setName(null);
phonenumber.setText(null);
password.setText(null);
username.setText(null);
JOptionPane.showMessageDialog(null, "Sucessfullyupdated","Login
info",JOptionPane.PLAIN_MESSAGE);
dispose();
userloginpage.main(null);}}
phonenumber.addKeyListener(new KeyAdapter() {
invalid.setText("");
int count = 0;
count +=1;
{ invalid.setText(""); } }
catch(NumberFormatException e13)
animals and humans.\r\n\r\nHere are few tips to stay away from corona:\r\n\r\n> Washing hands
with soaps or using
STAY HOME STAY SAFE \r\n> Social distancing is must\r\n\r\n> Cover your face while
coughing or sneezing\r\n\r\n>
Keep your surrounding clean\r\n\r\n> If a person is found with Symptoms like heavy breathing,
fever make sure that
person is home Quarantine\r\n\r\n> Products coming from outside like milk, vegetables, fruits
and others should be
washed before using it.\r\n\r\n>Stay informed and follow advice given by your healthcare
provider");
msgbox.setEditable(false);
scrollPane.setViewportView(msgbox);
fever.addActionListener(new ActionListener() {
notice.setText(null);
msgbox.setText(null);
+ "\r\n\r\nTake your temperature and assess your symptoms. if your temperature runs
100.4`F(38`C) or higher,
+ "\r\n\r\n> Keep hydrated. Drinking water, iced tea, or very diluted juice to replenish fluids lost
through
+ "\r\n\r\n> Stay cool. Remove extra layers of clothing and blankets, unless you have the chills"
+ "\r\n\r\n> Take tepid baths or using cold compresses to make you more comfortable. please
avoid cold baths
its dangerous"
+ "\r\n\r\n> But no matter what the number on the thermometer reads, if you have any concerns
consult your
doctor."); }});
SYSTEM TESTING
System testing is a level of testing that validates the complete and fully integrated software
product. The purpose of a system test is to evaluate the end-to-end system specifications. It
involves two kinds of testing integration testing and acceptance testing. Integration testing is a
level of software testing where individual units are combined and tested as a group. Acceptance
testing is a level of software testing where a system is tested for acceptability.
Software testing
Software testing is defined as an activity to check whether the actual results match the expected
results and to ensure that the software system is Defect free. It involves execution of a software
component or system component to evaluate one or more properties of interest. Software testing
also helps to identify errors, gaps or missing requirements in contrary to the actual requirements.
Testing objectives
1. Finding defects which may get created by the programmer while developing the software.
2. Gaining confidence in and providing information about the level of quality.
3. To prevent defects.
4. To make sure that the end results meet the business and user requirements.
5. To ensure that it satisfies the BRS that is Business Requirements Specification and SRS
that is System Requirement Specification.
6. To gain the confidence of the customers by providing them a quality product.
Testing strategies
1. Unit Testing
It is a process of testing a programme components such as objects, methods etc. Where it
is used:
To check and set the values of all attributes associated with the object.
To check all the operations associated with the object.
To put the object into all possible status.
(There are many modules like Login module, Add alumni module, Search alumni module, Edit
alumni module. Write u r modules)
2. Integration Testing
It is a level of software testing where individual units are combined and tested as a group.
The purpose of this level of testing is to expose faults in the interaction between
integrated units. The number of text fields specified in the design should match with the
number of entities in the database.
3. System Testing
Here the entire software system is tested. The reference document for this process is the
requirements document, and the goals to see if software meets its requirements. The
software has been tested against requirements of project and it is checked whether all
requirements of project have been satisfied or not.
4. Validation Testing
The process of evaluating software during the development process to determine whether
it satisfies specified requirements. Validation Testing ensures that the product actually
meets the client's needs. It can also be defined as to demonstrate that the product fulfils
its intended use when deployed on appropriate environment.
5. Black box testing
It considers a module as a single unit and checks the unit at interface and communication
with other modules rather getting into details at statement level.
6. White box testing
This is a unit testing method where a unit will be taken at a time and tested thoroughly at
a statement level to find the maximum possible errors.
OUTPUT SCREENS
Homepage
Details of users
Doctor details
User details
Disease prediction
Health tips
CONCLUSION
The main objective behind creating this application to predict disease and make sure that user
can get doctors details for contact. This application gets rid of the long process of consulting
doctor physically after all tests for particular disease. This application can help users to get
contact with doctors as soon as possible and through the phone number available can contact
through phone where doctors can guide them what to do regarding their symptoms. At the end of
this proposal we want to remember that this is fully unique system and we are sure that it will be
helpful for all the end user(s). Hospitals business can add this with their existing feature. Hope
this application will be very demandable in coming future.
FEATURE ENHANCEMENT
The digital technology era demands the world to provide an excellent health system, in order to
ensure the citizen and community to be alive and healthy. Our wellbeing indicator is exactly
based on this concept. Our application has good future scope which can make a revolution in
breaking the gap between users and doctors. The following points are some of the enhancements
that can be made through wellbeing indicator.
This application can help all fresher (doctor) where when doctor registers and the number
of users he treats can earn badges. Building up good profile for fresher.
Have a video conversation to treat patients.
Uploading photos and storing them by linking to patient ID, this helps easy identification.
Accepting test reports of any hospitals if they link to this application.
Link authorized pharmacy services and enable delivery services.
Improving to such a condition where patients need to visit only if it is emergency and if
there is a need of operation.
Implementing all the developed and developing technologies in order to develop the
present health care system.
BIBLOGRAPHY
www.google.com
www.github.com
www.nevonprojects.com
www.geeksforgeeks.org
www.wiki.com
www.youtube.com