Upload
abinayamalathy
View
261
Download
2
Embed Size (px)
Citation preview
8/9/2019 Cs2357 Ooad Lab Manual
1/349
GOPAL RAMALINGAM MEMORIAL ENGINEERING COLLEGE
Rajeshwari nagar, Panapakkam, Near Padappai, Chennai-60101!
"EPAR#MEN# O$ COMP%#ER &CIENCE AN" ENGINEERING
OOA" LA' MAN%AL
&()! C*de+&()! Name C&./-O)je Oriened Ana23sis and "esign
4ear+&em III+5I
&()mied )3
N!ARIARAN ME!,
AP+C&E
8/9/2019 Cs2357 Ooad Lab Manual
2/349
8/9/2019 Cs2357 Ooad Lab Manual
3/349
E@NO 1a PA&&POR# A%#OMA#ION &4EM
AIM
To develop the Passport Automation System using rational rose tools, visual basic
and MS access.
PRO'LEM ANAL4&I& AN" PRO7EC# PLAN
To simplify the process of applying passport, software has been created by
designing through rational rose tool, using visual basic as a front end and
Microsoft access as a back end. Initially the applicant login the passport
automation system and submits his details. These details are stored in the database
and verification process done by the passport administrator, regional administrator
and police the passport is issued to the applicant.
PRO'LEM A#EMEN#
. Passport Automation System is used in the effective dispatch of passport to
all of the applicants. This system adopts a comprehensive approach to
minimi!e the manual work and schedule resources, time in a cogent manner.
". The core of the system is to get the online registration form #with details
such as name, address etc.,$ filled by the applicant whose testament is
verified for its genuineness by the Passport Automation System with respect
to the already e%isting information in the database.
&. This forms the first and foremost step in the processing of passport
application. After the first round of verification done by the system, the
information is in turn forwarded to the regional administrator's #Ministry of
(%ternal Affairs$ office.
). The application is then processed manually based on the report given by the
system, and any forfeiting identified can make the applicant liable to penalty
as per the law.
*. The system forwards the necessary details to the police for its separate
verification whose report is then presented to the administrator. After all the
necessary criteria have been met, the original information is added to the
database and the passport is sent to the applicant.
&O$#ARE REB%IREMEN#& &PECI$ICA#ION
&NO &O$#ARE REB%IREMEN#&
8/9/2019 Cs2357 Ooad Lab Manual
4/349
&PECI$ICA#ION
.+
.
."
.&
.)
.*.
.-
Introduction
Purpose
Scope
efinition, Acronyms and
Abbreviations
/eferenceTechnology to be used
Tools to be used
0verview
".+
".
"."
".&
".)
".*
".".-
0verall description
Productive description
Software interface
1ardware interface
System function
2ser 3haracteristic
3onstraintsAssumption and ependences
1!0 IN#RO"%C#ION
Passport Automation System is an interface between the Applicant and the
Authority responsible for the Issue of Passport. It aims at improving the efficiency
in the Issue of Passport and reduces the comple%ities involved in it to the
ma%imum possible e%tent.
1!1 P%RPO&E
If the entire process of 'Issue of Passport' is done in a manual manner then it
would take several months for the passport to reach the applicant. 3onsidering the
fact that the number of applicants for passport is increasing every year, an
Automated System becomes essential to meet the demand. So this system uses
several programming and database techni4ues to elucidate the work involved in
this process. As this is a matter of 5ational Security, the system has been carefully
verified and validated in order to satisfy it.
1! &COPE
The System provides an online interface to the user where they can fill in
their personal details. The authority concerned with the issue of passport can
use this system to reduce his workload and process the application in a
speedy manner.Provide a communication platform between the applicant and
the administrator Transfer of data between the Passport Issuing Authority
and the 6ocal Police for verification of applicant's information.
8/9/2019 Cs2357 Ooad Lab Manual
5/349
1! "E$INI#ION&, ACRON4M& AN" #E A''RE5IA#ION&
. Administrator 7 /efers to the super user who is the 3entral Authority who
has been vested with the privilege to manage the entire system. It can be any
higher official in the /egional Passport 0ffice of Ministry of (%ternal
Affairs.
". Applicant 7 0ne who wishes to obtain the Passport.&. PAS 7 /efers to this Passport Automation System.
1!= RE$ERENCE& I((( Software /e4uirement Specification format.
1!. #ECNOLOGIE& #O 'E %&E" 8 Microsoft 9isual :asic .+
1!6 #OOL& #O 'E %&E" 8 /ational /ose tool #for developing 2M6 Patterns$
1!/ O5ER5IE
S/S includes two sections overall description and specific re4uirements 7 0verall
description will describe ma;or role of the system components and inter7
connections. Specific re4uirements will describe roles < functions of the actors.
!0 O5ERALL "E&CRIP#ION
!1 PRO"%C# PER&PEC#I5E
The PAS acts as an interface between the 'applicant' and the 'administrator'. This
system tries to make the interface as simple as possible and at the same time notrisking the security of data stored in. This minimi!es the time duration in which the
user receives the passport.
! &O$#ARE IN#ER$ACE
. $r*n End C2ien 7 The applicant and Administrator online interface is built
using Microsoft 9isual :asic .+.
". 'ak End = MS Access database
! AR"ARE IN#ER$ACE
The server is directly connected to the client systems. The client systems have
access to the database in the server.
!= &4EM $%NC#ION&
. Secure /egistration of information by the Applicants.
8/9/2019 Cs2357 Ooad Lab Manual
6/349
". Message bo% for Passport Application Status isplay by the Administrator.
&. Administrator can generate reports from the information and is the only
authori!ed personnel to add the eligible application information to the
database.
!. %&ER CARAC#ERIIC&
. Applicant 7 They are the people who desires to obtain the passport andsubmit the information to the database.
". Administrator 7 1e has the certain privileges to add the passport status and
to approve the issue of passport. 1e may contain a group of persons under
him to verify the documents and give suggestion whether or not to approve
the dispatch of passport.
&. Police 7 1e is the person who upon receiving intimation from the PAS,
perform a personal verification of the applicant and see if he has any
criminal case against him before or at present. 1e has been vetoed with the
power to decline an application by suggesting it to the Administrator if he
finds any discrepancy with the applicant. 1e communicates via this PAS.
!6 CONRAIN#&
. The applicants re4uire a computer to submit their information.
". Although the security is given high importance, there is always a chance of
intrusion in the web world which re4uires constant monitoring.
&. The user has to be careful while submitting the information. Much care is
re4uired.
!/ A&&%MP#ION& AN" "EPEN"ENCIE&
. The Applicants and Administrator must have basic knowledge of computers
and (nglish 6anguage.
". The applicants may be re4uired to scan the documents and send.
%ML "IAGRAM&
&n* %ML "IAGRAM&
2se 3ase diagram" 3lass diagram
& Interaction diagram
) Se4uence diagram
* 3ollaboration diagram
State 3hart diagram
- Activity diagram
> 3omponent diagram
? eployment diagram
+ Package diagram
8/9/2019 Cs2357 Ooad Lab Manual
7/349
"OC%MEN#A#ION O$ %&ECA&E "IAGRAM
a. The actors in use case diagram are Applicant, regional administrator,
database, passport Administrator, Police.
b. The use cases are 6ogin, givedetails, logout, collectdetails,
verification, issue.
c. The actors use the use case are denoted by the arrow
d. The login use case checks the username and password for applicant,
regional administrator, passport administrator and police.
e. The submit details use case is used by the applicant for submitting his
details
f. The check status use case is used by the applicant for checking the
status of the application process.
8/9/2019 Cs2357 Ooad Lab Manual
8/349
g. The get details, verify and store verification use case is used by
passport administrator, regional administrator, and police.
h. The details use case is used for getting the details form the database
for verification
". The verify use case is used for verifying the details by comparing the data in
the database.
a. The store verification use case is to update the data in the database
b. And finally the issue passport use case is used by the passport
administrator for issuing passport who@s application verified
successfully by all the actor .
CLA&&"IAGRAM
A class is drawn as rectangle bo% with three compartments or componentsseparated by hori!ontal lines. The top compartment holds the class name and
middle compartment holds the attribute and bottom compartment holds list of
operations.
"OC%MEN#A#ION O$ CLA&& "IAGRAM
a. APPLICAN#7The applicant has attribute such as name and password
and operations are login, givedetails and logout. The applicant login
8/9/2019 Cs2357 Ooad Lab Manual
9/349
and fill the details that are re4uired for applying the passport .After
applying the person can view the status of the passport verification
process
b. #E "A#A'A&E7The database has attributed such as name and
operation is store. The purpose is to store the data.
c. REGIONAL A"MINIRA#OR 7 The regional administrator has
attribute such as name and operation are get details, verify details and
send. The regional administrator get the details form database and
verify with their database
d. PA&&POR# A"MINIRA#OR 7The passport administrator has
attributed such as name and operation are get details, verify details
and issue. The passport administrator get the details form database and
verify with their database , update the verification and issue the passport
e. #E POLICE7The police has attribute such as name and operation
are get details, verify details and send. The police get the details form
database and verify with their database , update the verification in the
database
&EB%ENCE "IAGRAM
A se4uence diagram shows an interaction arranged in time se4uence,
It shows ob;ect participating in interaction by their lifeline by the message they
e%change arranged in time se4uence. 9ertical dimension represent time and
hori!ontal dimension represent ob;ect.
8/9/2019 Cs2357 Ooad Lab Manual
10/349
"OC%MEN#A#ION O$ &EB%ENCE "IAGRAM.
a. The applicant login the database and give his details and database
store the details.
b. The passport administrator get the details from the database and do
verification and the forward to regional administrator.
c. The regional administrator get details form passport administrator and
perform verification and send report to passport administrator.
d. The police get the details form passport administrator and perform
verification and send report to passport administrator
COLLA'ORA#ION "IAGRAM
A collaboration diagram is similar to se4uence diagram but the message in number
format. In a collaboration diagram se4uence diagram is indicated by the numbering
8/9/2019 Cs2357 Ooad Lab Manual
11/349
the message. A collaboration diagram, also called a communication diagram or
interaction diagram, A sophisticated modeling tool can easily convert a
collaboration diagram into a se4uence diagram and the vice versa. A collaboration
diagram resembles a flowchart that portrays the roles, functionality and behavior of
individual ob;ects as well as the overall operation of the system in real time
A#E CAR# "IAGRAM
The state chart diagram contains the states in the rectangle bo%es and starts in
indicated by the dot and finish is indicated by dot encircled. The purpose of state
chart diagram is to understand the algorithm in the performing method.
"OC%MEN#A#ION O$ A#E CAR# "IAGRAM
a. The states of the passport automation system are denoted in the state
chart diagram
b. 6ogin state represent authentication for login the passport automation
system.
c. In this state, it checks whether the applicant has provided all the
details that is re4uired.
d. Police, regional administrator and passport administrator get
necessary details and verification of the applicant are denoted from
the et detail state and verification state
AC#I5I#4 "IAGRAM
An activity diagram is a variation or special case of a state machine in which the
states or activity representing the performance of operation and transitions are
triggered by the completion of operation. The purpose is to provide view of close
and what is going on inside a use case or among several classes. An activity is
8/9/2019 Cs2357 Ooad Lab Manual
12/349
shown as rounded bo% containing the name of operation
"OC%MEN#A#ION O$ AC#I5I#4 "IAGRAM
a. The activities in the passport automation system are login, submit
details, get details, issue passport and penalty and verification.
b. In the login activity applicant give username and password and then
login into the passport automation system after then fill the details that
are re4uired for application.
c. After the verification procedure completed successfully the passport is
issued to the applicant.
COMPONEN# "IAGRAM
The component diagram is represented by figure dependency and it is a graph of
design of figure dependency. The component diagram's main purpose is to show
the structural relationships between the components of a systems. It is represented
by bo%ed figure. ependencies are represented by communication assosiation.
8/9/2019 Cs2357 Ooad Lab Manual
13/349
"OC%MEN#A#ION O$ COMPONEN# "IAGRAM
a. The components in the passport automation system are passport
automation system, applicant, passport administrator, regional
administrator, and police.
b. Applicant ,passport administrator, regional administrator and police
are dependent on passport automation system are shown by the dotted
arrow
"EPLO4MEN# "IAGRAM
It is a graph of nodes connected by communication association. It is represented by
a three dimensional bo%. A deployment diagram in the unified modeling language
serves to model the physical deployment of artifacts on deployment targets.eployment diagrams show Bthe allocation of artifacts to nodes according to the
eployments defined between them. It is represented by &7dimentional bo%.
ependencies are represented by communication association. The basic element of
a deployment diagram is a node of two types
"E5ICE NO"E =
A physical computing resource with processing and memory service to e%ecute
software, such as a typical computer or a mobile phone.
8/9/2019 Cs2357 Ooad Lab Manual
14/349
E@EC%#ION EN5IRONMEN# NO"E
This is a software computing resource that runs within an outer node and which
itself provides a service to host an e%ecute other e%ecutable software element.
"OC%MEN#A#ION O$ "EPLO4MEN# "IAGRAM
The device node is passport automation system and e%ecution environment node
are applicant passport administrator, regional administrator, and police.
PACAGE "IAGRAM
A package diagram is represented as a folder shown as a large rectangle with a topattached to its upper left corner. A package may contain both sub ordinate package
and ordinary model elements. All uml models and diagrams are organi!ed into
package. A package diagram in unified modeling language that depicts the
dependencies between the packages that make up a model. A Package iagram
#P$ shows a grouping of elements in the 00 model, and is a 3radle e%tension to
2M6. Ps can be used to show groups of classes in 3lass iagrams #3s$, groups
of components or processes in 3omponent iagrams #3Ps$, or groups of
processors in eployment iagrams #Ps$.
There are three types of layer. They are
o 2ser interface layer
o omain layer
o Technical services layer
8/9/2019 Cs2357 Ooad Lab Manual
15/349"OC%MEN#A#ION O$ PACAGE "IAGRAM
8/9/2019 Cs2357 Ooad Lab Manual
16/349
The three layer in the passport automation system are user interface layer, domain
layer, technical service layer
a. #he (ser iner9ae 2a3er- represents the user interface components
such as web, applicant, passport administrator, police, and regional
administrator.
b. #he d*main 2a3er- has ma;or actions such as give and get details,
verification and issues.
c. #ehnia2 ser8ie 2a3er7 authenticated user only can access the
technical services.
$ORM&
$ORM1
$ORM
8/9/2019 Cs2357 Ooad Lab Manual
17/349
$ORM
8/9/2019 Cs2357 Ooad Lab Manual
18/349
$ORM=
8/9/2019 Cs2357 Ooad Lab Manual
19/349
$ORM.
8/9/2019 Cs2357 Ooad Lab Manual
20/349
8/9/2019 Cs2357 Ooad Lab Manual
21/349
$ORM6
$ORM/
8/9/2019 Cs2357 Ooad Lab Manual
22/349
&O%RCE CO"E
$ORM1
Private Sub 3ommandC3lick#$
im app As Applicant
Set app D 5ew Applicantapp.6ogin
(nd Sub
Private Sub 3ommand"C3lick#$
im pass As PassportAdministrator
Set pass D 5ew PassportAdministrator
pass.6ogin
(nd Sub
Private Sub 3ommand&C3lick#$
im reg As /egionalAdminstratorSet reg D 5ew /egionalAdminstrator
reg.6ogin
(nd Sub
8/9/2019 Cs2357 Ooad Lab Manual
23/349
Private Sub 3ommand)C3lick#$
im pol As Police
Set pol D 5ew Police
pol.6ogin
(nd Sub
Private Sub 3ommand*C3lick#$
If Eorm.Te%t.Te%t D BB And Eorm.Te%t".Te%t D BB Then
Msg:o% B60I5 S233(SSE26BEorm.Show
(lse
Msg:o% BI59A6I 2S(/5AM( A5 PASSF0/B
2nload Me
(nd If
(nd Sub
Private Sub 3ommandC3lick#$
(nd
(nd Sub
$ORMPrivate Sub 3ommandC3lick#$
im subdetails As Applicant
Set subdetails D 5ew Applicant
subdetails.Submitetails
(nd Sub
Private Sub 3ommand&C3lick#$
ata./ecordset.(dit
(nd Sub
Private Sub 3ommand)C3lick#$ata./ecordset.update
(nd Sub
Private Sub EormC6oad#$
Te%t.Te%t D BB
Te%t".Te%t D BB
Te%t&.Te%t D BB
Te%t).Te%t D BB
Te%t*.Te%t D BB
Te%t.Te%t D BB
Te%t-.Te%t D BBTe%t>.Te%t D BB
8/9/2019 Cs2357 Ooad Lab Manual
24/349
(nd Sub
$ORM
Private Sub aC3lick#$
ata"./ecordset.Add5ew
(nd Sub
Private Sub 3ommandC3lick#$
im search As PassportAdministrator
Set search D 5ew PassportAdministratorsearch.update
(nd Sub
Private Sub 3ommand"C3lick#$
If ata./ecordset.:0E Then
Msg:o% B50 ATA E025B
(lse
ata./ecordset.MovePrevious
(nd If
(nd Sub
Private Sub 3ommand&C3lick#$If ata./ecordset.(0E Then
Msg:o% B50 ATA E025B
(lse
ata./ecordset.Move5e%t
(nd If
(nd Sub
Private Sub 3ommand)C3lick#$
Eorm.Show
2nload Me(nd Sub
Private Sub 3ommand*C3lick#$
ata./ecordset.MoveEirst
(nd Sub
Private Sub 3ommandC3lick#$
ata./ecordset.Move6ast
(nd Sub
Private Sub 3ommand-C3lick#$
ata./ecordset.(dit
8/9/2019 Cs2357 Ooad Lab Manual
25/349
ata./ecordset.Eields#?$ D BsuccessfulB
ata./ecordset.update
(nd Sub
Private Sub 3ommand>C3lick#$
ata./ecordset.(dit
ata./ecordset.Eields#?$ D BunsuccessfulB
ata./ecordset.update
(nd SubPrivate Sub veC3lick#$
im verify As PassportAdministrator
Set verify D 5ew PassportAdministrator
verify.update
(nd Sub
$ORM=
Private Sub 3ommandC3lick#$
im search As /egionalAdminstrator
Set search D 5ew /egionalAdminstrator
search.verify(nd Sub
Private Sub 3ommand"C3lick#$
ata./ecordset.(dit
ata./ecordset.Eields#+$ D BsuccessfulB
ata./ecordset.update
(nd Sub
Private Sub 3ommand&C3lick#$
ata./ecordset.(dit
ata./ecordset.Eields#+$ D BunsuccessfulBata./ecordset.update
(nd Sub
Private Sub 3ommand)C3lick#$
Eorm.Show
2nload Me
(nd Sub
Private Sub 3ommand*C3lick#$
im update As /egionalAdminstrator
Set update D 5ew /egionalAdminstrator
update.update
8/9/2019 Cs2357 Ooad Lab Manual
26/349
(nd Sub
Private Sub 3ommandC3lick#$
ata./ecordset.Move6ast
(nd Sub
Private Sub 3ommand-C3lick#$
ata./ecordset.MoveEirst
(nd Sub
Private Sub 3ommand>C3lick#$If ata./ecordset.:0E Then
Msg:o% B50 ATA E025B
(lse
ata./ecordset.MovePrevious
(nd If
(nd Sub
Private Sub 3ommand?C3lick#$
If ata./ecordset.(0E Then
Msg:o% B50 ATA E025B
(lseata./ecordset.Move5e%t
(nd If
(nd Sub
$ORM.
Private Sub 3ommandC3lick#$
im search As Police
Set search D 5ew Police
search.verify
(nd SubPrivate Sub 3ommand"C3lick#$
ata"./ecordset.(dit
ata"./ecordset.Eields#$ D BsuccessfulB
ata"./ecordset.update
(nd Sub
Private Sub 3ommand&C3lick#$
ata"./ecordset.(dit
ata"./ecordset.Eields#$ D BunsuccessfulB
ata"./ecordset.update
(nd Sub
8/9/2019 Cs2357 Ooad Lab Manual
27/349
Private Sub 3ommand)C3lick#$
Eorm.Show
2nload Me
(nd Sub
Private Sub 3ommandC3lick#$
ata"./ecordset.Move6ast
(nd Sub
Private Sub 3ommand-C3lick#$ata"./ecordset.MoveEirst
(nd Sub
Private Sub 3ommand>C3lick#$
If ata"./ecordset.:0E Then
Msg:o% B50 ATA E025B
(lse
ata"./ecordset.MovePrevious
(nd If
(nd Sub
Private Sub 3ommand?C3lick#$If ata"./ecordset.(0E Then
Msg:o% B50 ATA E025B
(lse
ata"./ecordset.Move5e%t
(nd If
(nd Sub
$ORM6
Private Sub 3ommandC3lick#$
im checkstate As ApplicantSet checkstate D 5ew Applicant
checkstate.3heckStatus
(nd Sub
Private Sub 3ommand"C3lick#$
Eorm.Show
2nload Me
(nd Sub
%ML CO"ING&
APPLICAN#
8/9/2019 Cs2357 Ooad Lab Manual
28/349
0ption (%plicit
'GGModelIdD)-*"(>+"-
Private 5ame As 9ariant
'GGModelIdD)-*"((+"3(
Private Eather5ame As 9ariant
'GGModelIdD)-*"E&++?3
Private ate0f:irth As 9ariant
'GGModelIdD)-*""+:+A*Private PermanentAddress As 9ariant
'GGModelIdD)-*"""++&&3
Private TemporaryAddress As 9ariant
'GGModelIdD)-*"")+()
Private (mailI As 9ariant
'GGModelIdD)-*"")-+()
Private Phone5umber As 9ariant
'GGModelIdD)-*"")(+&3
Private Pan5o As 9ariant
'GGModelIdD)-*""*?+")"Private Application5o As 9ariant
'GGModelIdD)-*""*+&>A
Private 2ser5ame As 9ariant
'GGModelIdD)-*""&++3:
Private Password As 9ariant
'GGModelIdD)-*"&&++"-
Public 5ewProperty As atabase
'GGModelIdD)-*""?++?
Public Sub 6ogin#$If Eorm.Te%t.Te%t D BB And Eorm.Te%t".Te%t D BB Then
Msg:o% B60I5 S233(SSE26B
Eorm".Show
(lse
Msg:o% BI59A6I 2S(/5AM( A5 PASSF0/B
2nload Me
(nd If
(nd Sub
'GGModelIdD)-*""-+&"3
Public Sub Submitetails#$im ap As Integer
Eorm.ata./ecordset.Move6ast
ap D ata./ecordset.Eields#+$
ata./ecordset.Add5ew
ap D ap H
Eorm.ata./ecordset.Eields#+$ D ap
8/9/2019 Cs2357 Ooad Lab Manual
29/349
Eorm.ata./ecordset.Eields#$ D Te%t.Te%t
Eorm.ata./ecordset.Eields#"$ D Te%t".Te%t
Eorm.ata./ecordset.Eields#&$ D Te%t&.Te%t
Eorm.ata./ecordset.Eields#)$ D Te%t).Te%t
Eorm.ata./ecordset.Eields#*$ D Te%t*.Te%t
Eorm.ata./ecordset.Eields#$ D Te%t.Te%t
Eorm.ata./ecordset.Eields#-$ D Te%t-.Te%t
Eorm.ata./ecordset.Eields#>$ D Te%t>.Te%tEorm.ata./ecordset.Eields#?$ D B2nder ProcessB
Eorm.ata./ecordset.Eields#+$ D B2nder ProcessB
Eorm.ata./ecordset.Eields#$ D B2nder ProcessB
Eorm.ata./ecordset.update
Eorm.Show
2nload Me
(nd Sub
'GGModelIdD)-*""-+"
Public Sub 3heckStatus#$
im 3urrentdb As atabaseSet 3urrentdb D 0penatabase#BJPASSP0/TP/0K(3TJPASSP0/T.mdbB$
im ata As /ecordset
Set ata D 3urrentdb.0pen/ecordset#BapplicantB, db0penynaset$
ata.EindEirst B#LApplication5o$DB < Eorm.Te%t.Te%t
If ata.5oMatch Then
Msg:o% B5o such recordB
(lse
Msg:o% BsuccessB
Eorm.Te%t.Te%t D ata.Eields#+$Eorm.6abel* D ata.Eields#$
Eorm.6abel- D ata.Eields#?$
Eorm.label? D ata.Eields#+$
Eorm.6abel D ata.Eields#$
(nd If
ata.3lose
(nd Sub
"A#A 'A&E
0ption (%plicit
'GGModelIdD)-*""A&+"""Private 5ame As 9ariant
'GGModelIdD)-*"&&3++*
Public 5ewProperty As PassportAdministrator
'GGModelIdD)-*"&&(++
8/9/2019 Cs2357 Ooad Lab Manual
30/349
Public 5ewProperty" As /egionalAdminstrator
'GGModelIdD)-*"&)"+":E
Public 5ewProperty& As Police
'GGModelIdD)-*""A*+>
Public Sub store#$
(nd Sub
PA&&POR# A"MINRA#OR
0ption (%plicit'GGModelIdD)-*""A?+">
Private 2ser5ame As 9ariant
'GGModelIdD)-*""E?+&*:
Private Password As 9ariant
'GGModelIdD)-*"":"+"&"
Public Sub 6ogin#$
If Eorm.Te%t.Te%t D BpassadminB And Eorm.Te%t".Te%t D B"&)*B Then
Msg:o% B60I5 S233(SSE26B
Eorm.Te%t.Te%t D BB
Eorm.Te%t".Te%t D BBEorm.Te%t.SetEocus
Eorm&.Show
(lse
Msg:o% BI59A6I 2S(/5AM( 0/ PASSF0/B
Eorm.Te%t.Te%t D BB
Eorm.Te%t".Te%t D BB
Eorm.Te%t.SetEocus
(nd If
(nd Sub'GGModelIdD)-*"":A++)(
Public Sub verify#$
Set 3urrentdb D 0penatabase#BJPASSP0/TP/0K(3TJpassport.mdbB$
im ata As /ecordset
Set ata D 3urrentdb.0pen/ecordset#BPassportAdministratorB, db0penynaset$
If Eorm&.Te%t.Te%t D BB Then
Msg:o% Bselect any dataB
(lse
ata.EindEirst B#LPan5o$DB < Eorm&.Te%t.Te%t
If ata.5oMatch ThenMsg:o% B5o such recordB
(lse
Msg:o% BsuccessB
Eorm&.Te%t-.Te%t D ata.Eields#$
8/9/2019 Cs2357 Ooad Lab Manual
31/349
Eorm&.Te%t>.Te%t D ata.Eields#"$
(nd If
(nd If
(nd Sub
'GGModelIdD)-*"":E+)
Public Sub update#$
If Eorm&.Te%t".Te%t D Eorm&.Te%t-.Te%t And Eorm&.Te%t&.Te%t D
Eorm&.Te%t>.Te%t ThenEorm&.ata./ecordset.(dit
Eorm&.ata./ecordset.Eields#?$ D BsuccessfulB
Eorm&.ata./ecordset.update
Msg:o% BsuccessB
(lse
Msg:o% Bno B
Eorm&.Te%t-.Te%t D BB
Eorm&.Te%t>.Te%t D BB
(nd If
(nd SubPOLICE
0ption (%plicit
'GGModelIdD)-*""(++E
Private 2ser5ame As 9ariant
'GGModelIdD)-*"&"+)
Private Password As 9ariant
'GGModelIdD)-*""(&+"*
Public Sub 6ogin#$
If Eorm.Te%t.Te%t D BpoladminB And Eorm.Te%t".Te%t D B"&)*B ThenMsg:o% B60I5 S233(SSE26B
Eorm.Te%t.Te%t D BB
Eorm.Te%t".Te%t D BB
Eorm.Te%t.SetEocus
Eorm*.Show
(lse
Msg:o% BI59A6I 2S(/5AM( 0/ PASSF0/B
Eorm.Te%t.Te%t D BB
Eorm.Te%t".Te%t D BB
Eorm.Te%t.SetEocus(nd If
(nd Sub
'GGModelIdD)-*""(>++>3
Public Sub verify#$
im 3urrentdb As atabase
Set 3urrentdb D 0penatabase#BJPASSP0/TP/0K(3TJpassport.mdbB$
im ata As /ecordset
8/9/2019 Cs2357 Ooad Lab Manual
32/349
Set ata D 3urrentdb.0pen/ecordset#BPoliceB, db0penynaset$
If Eorm*.Te%t.Te%t D BB Then
Msg:o% Bselect any dataB
(lse
ata.EindEirst B#LPan5o$DB < Eorm*.Te%t.Te%t
If ata.5oMatch Then
Msg:o% B5o such recordB
(lseMsg:o% BsuccessB
If ata.Eields#*$ D B5otallowedB Then
Msg:o% Bnot allowedB
(lse
Msg:o% BallowedB
(nd If
(nd If
(nd If
ata.3lose
(nd Sub'GGModelIdD)-*""(A+":E
Public Sub update#$
(nd Sub
REGIONAL A"MINRA#OR
0ption (%plicit
'GGModelIdD)-*""3>+"""
Private 2ser5ame As 9ariant
'GGModelIdD)-*"&A++?
Private Password As 9ariant'GGModelIdD)-*""3:+"3(
Public Sub 6ogin#$
If Eorm.Te%t.Te%t D BregadminB And Eorm.Te%t".Te%t D B"&)*B Then
Msg:o% B60I5 S233(SSE26B
Eorm.Te%t.Te%t D BB
Eorm.Te%t".Te%t D BB
Eorm.Te%t.SetEocus
Eorm).Show
(lse
Msg:o% BI59A6I 2S(/5AM( 0/ PASSF0/BEorm.Te%t.Te%t D BB
Eorm.Te%t".Te%t D BB
Eorm.Te%t.SetEocus
(nd If
(nd Sub
8/9/2019 Cs2357 Ooad Lab Manual
33/349
'GGModelIdD)-*""3(+A*
Public Sub verify#$
im 3urrentdb As atabase
Set 3urrentdb D 0penatabase#BJPASSP0/TP/0K(3TJpassport.mdbB$
im ata As /ecordset
Set ata D 3urrentdb.0pen/ecordset#B/egionalAdminstratorB, db0penynaset$
If Eorm).Te%t.Te%t D BB Then
Msg:o% Bselect any dataB(lse
ata.EindEirst B#LPan5o$DB < Eorm).Te%t.Te%t
If ata.5oMatch Then
Msg:o% B5o such recordB
(lse
Msg:o% BsuccessB
Eorm).Te%t.Te%t D ata.Eields#$
Eorm).Te%t-.Te%t D ata.Eields#"$
Eorm).Te%t>.Te%t D ata.Eields#&$
Eorm).Te%t?.Te%t D ata.Eields#)$(nd If
(nd If
(nd Sub
'GGModelIdD)-*""++":E
Public Sub update#$
If Eorm).Te%t".Te%t D Te%t.Te%t And Eorm).Te%t&.Te%t D Eorm).Te%t-.Te%t And
Eorm).Te%t).Te%t D Eorm).Te%t>.Te%t And Eorm).Te%t*.Te%t D Eorm).Te%t?.Te%t
Then
Msg:o% Betails matchB(lse
Msg:o% Betails donot matchB
(nd If
(nd Sub
RE&%L#
Thus the pro;ect to develop passport automation system was developed using
/ational /ose Software and to implement the software in 9isual :asic is donesuccessfully.
8/9/2019 Cs2357 Ooad Lab Manual
34/349
E@NO 1) PA&&POR# A%#OMA#ION &4EM
AIM
To develop the Passport Automation System using rational rose tools, Kava and MS
access
PRO'LEM ANAL4&I& AN" PRO7EC# PLAN
To simplify the process of applying passport, software has been created by
designing through rational rose tool, using visual basic as a front end and
Microsoft access as a back end. Initially the applicant login the passport
automation system and submits his details. These details are stored in the database
and verification process done by the passport administrator, regional administrator
and police the passport is issued to the applicant.
PRO'LEM A#EMEN#
a. Passport Automation System is used in the effective dispatch of
passport to all of the applicants. This system adopts a comprehensive
approach to minimi!e the manual work and schedule resources, time
in a cogent manner.
b. The core of the system is to get the online registration form #with
details such as name, address etc.,$ filled by the applicant whose
testament is verified for its genuineness by the Passport Automation
System with respect to the already e%isting information in thedatabase.
c. This forms the first and foremost step in the processing of passport
application. After the first round of verification done by the system,
the information is in turn forwarded to the regional administrator's
#Ministry of (%ternal Affairs$ office.
d. The application is then processed manually based on the report given
by the system, and any forfeiting identified can make the applicant
liable to penalty as per the law.
e. The system forwards the necessary details to the police for its separate
verification whose report is then presented to the administrator. After
all the necessary criteria have been met, the original information is
added to the database and the passport is sent to the applicant.
8/9/2019 Cs2357 Ooad Lab Manual
35/349
&O$#ARE REB%IREMEN#& &PECI$ICA#ION
&NO &O$#ARE
REB%IREMEN#&
&PECI$ICA#ION
.+
.
."
.&.)
.*
.
.-
Introduction
Purpose
Scope
efinition, Acronymsand Abbreviations
/eference
Technology to be used
Tools to be used
0verview
".+
".
"."".&
".)
".*
".
".-
0verall description
Productive description
Software interface1ardware interface
System function
2ser 3haracteristic
3onstraints
Assumption and
ependences
1!0 IN#RO"%C#ION
Passport Automation System is an interface between the Applicant and the
Authority responsible for the Issue of Passport. It aims at improving the efficiency
in the Issue of Passport and reduces the comple%ities involved in it to the
ma%imum possible e%tent.
1!1 P%RPO&E
If the entire process of 'Issue of Passport' is done in a manual manner then it
would take several months for the passport to reach the applicant. 3onsidering the
fact that the number of applicants for passport is increasing every year, an
Automated System becomes essential to meet the demand. So this system uses
several programming and database techni4ues to elucidate the work involved in
this process. As this is a matter of 5ational Security, the system has been carefully
verified and validated in order to satisfy it.
8/9/2019 Cs2357 Ooad Lab Manual
36/349
1! &COPE
a. The System provides an online interface to the user where they can fill
in their personal details
b. The authority concerned with the issue of passport can use this system
to reduce his workload and process the application in a speedy
manner. 8 Provide a communication platform between the applicant
and the administrator. Transfer of data between the Passport IssuingAuthority and the 6ocal Police for verification of applicant's
information.
1! "E$INI#ION&, ACRON4M& AN" #E A''RE5IA#ION& 8
Administrator 7 /efers to the super user who is the 3entral Authority who has been
vested with the privilege to manage the entire system. It can be any higher official
in the /egional Passport 0ffice of Ministry of (%ternal Affairs. 8 Applicant 7 0ne
who wishes to obtain the Passport. 8 PAS 7 /efers to this Passport Automation
System.
1!= RE$ERENCE& I((( Software /e4uirement Specification format.
1!. #ECNOLOGIE& #O 'E %&E" 8 Microsoft 9isual :asic .+
1!6 #OOL& #O 'E %&E" 8 /ational /ose tool #for developing 2M6 Patterns$
1!/ O5ER5IE
S/S includes two sections overall description and specific re4uirements 7 0veralldescription will describe ma;or role of the system components and inter7
connections. Specific re4uirements will describe roles < functions of the actors.
!0 O5ERALL "E&CRIP#ION
!1 PRO"%C# PER&PEC#I5E
The PAS acts as an interface between the 'applicant' and the 'administrator'. This
system tries to make the interface as simple as possible and at the same time not
risking the security of data stored in. This minimi!es the time duration in which the
user receives the passport.
! &O$#ARE IN#ER$ACE
a. $r*n End C2ien 7 The applicant and Administrator online interface
is built using Kava
b. 'ak End = MS Access database.
! AR"ARE IN#ER$ACE
The server is directly connected to the client systems. The client systems have
access to the database in the server.
8/9/2019 Cs2357 Ooad Lab Manual
37/349
!= &4EM $%NC#ION&
a. Secure /egistration of information by the Applicants.
b. Message bo% for Passport Application Status isplay by the
Administrator.
c. Administrator can generate reports from the information and is the
only authori!ed personnel to add the eligible application information
to the database.
!. %&ER CARAC#ERIIC&
a. Applicant 7 They are the people who desires to obtain the passport and
submit the information to the database.
b. Administrator 7 1e has the certain privileges to add the passport status
and to approve the issue of passport. 1e may contain a group of
persons under him to verify the documents and give suggestion
whether or not to approve the dispatch of passport.
c. Police 7 1e is the person who upon receiving intimation from the PAS, perform a personal verification of the applicant and see if he has any
criminal case against him before or at present. 1e has been vetoed
with the power to decline an application by suggesting it to the
Administrator if he finds any discrepancy with the applicant. 1e
communicates via this PAS.
!6 CONRAIN#&
o The applicants re4uire a computer to submit their information.o Although the security is given high importance, there is always a
chance of intrusion in the web world which re4uires constant
monitoring.
o The user has to be careful while submitting the information. Much
care is re4uired.
!/ A&&%MP#ION& AN" "EPEN"ENCIE&
o The Applicants and Administrator must have basic knowledge of
computers and (nglish 6anguage.
o The applicants may be re4uired to scan the documents and send.
8/9/2019 Cs2357 Ooad Lab Manual
38/349
%ML "IAGRAM&
&n* %ML "IAGRAM&
2se 3ase diagram
" 3lass diagram
& Interaction diagram
) Se4uence diagram
* 3ollaboration diagram
State 3hart diagram- Activity diagram
> 3omponent diagram
? eployment diagram
+ Package diagram
%&E CA&E "IAGRAM
2se case is shown as an ellipse containing the name of use case .An actor is shown
as a stick figure with the name below it. 2se case diagram is a graph of actors.
"OC%MEN#A#ION O$ %&ECA&E "IAGRAM
a. The actors in use case diagram are Applicant, regional administrator,
database, passport Administrator, Police.
8/9/2019 Cs2357 Ooad Lab Manual
39/349
b. The use cases are 6ogin, givedetails, logout, collectdetails,
verification, issue.
c. The actors use the use case are denoted by the arrow
CLA&&"IAGRAM
A class is drawn as rectangle bo% with three compartments or componentsseparated by hori!ontal lines. The top compartment holds the class name and
middle compartment holds the attribute and bottom compartment holds list of
operations.
"OC%MEN#A#ION O$ CLA&& "IAGRAM
o The classes are Applicant, database, regional administrator, passport
administrator, and police.
o The applicant has attribute such as name and password and operations
are login, givedetails and logout.
8/9/2019 Cs2357 Ooad Lab Manual
40/349
o The database has attribute such as name and operation is store.
o The regional administrator has attribute such as name and operation
are get details, verify details and send.
o The passport administrator has attribute such as name and operation
are get details, verify details and issue.
o The police has attribute such as name and operation are get details,
verify details and send.
&EB%ENCE "IAGRAM
A se4uence diagram shows an interaction arranged in time se4uence,
It shows ob;ect participating in interaction by their lifeline by the message they
e%change arranged in time se4uence. 9ertical dimension represent time and
hori!ontal dimension represent ob;ect.
"OC%MEN#A#ION O$ &EB%ENCE "IAGRAM.
o The applicant login the database and give his details and database
store the details.
o The passport administrator get the details from the database and do
verification and the forward to regional administrator.
8/9/2019 Cs2357 Ooad Lab Manual
41/349
o The regional administrator get details form passport administrator and
perform verification and send report to passport administrator.
o The police get the details form passport administrator and perform
verification and send report to passport administrator.
COLLA'ORA#ION "IAGRAM
A collaboration diagram is similar to se4uence diagram but the message in number
format. In a collaboration diagram se4uence diagram is indicated by the numbering
the message
"OC%MEN#A#ION O$ COLLA'ORA#ION "IAGRAM
a. The applicant, passport administrator, regional administrator, police
and database functions are show in se4uence number
b. The applicant first login the passport automation system and submit
his details the passport administrator, regional administrator and
police verification are denoted.
A#E CAR# "IAGRAM
8/9/2019 Cs2357 Ooad Lab Manual
42/349
The state chart diagram contains the states in the rectangle bo%es and starts in
indicated by the dot and finish is indicated by dot encircled. The purpose of state
chart diagram is to understand the algorithm in the performing method.
"OC%MEN#A#ION O$ A#E CAR# "IAGRAM
a. The states of the passport automation system are denoted in the state
chart diagram
b. 6ogin state represent authentication for login the passport automation
system.
c. In this state, it checks whether the applicant has provided all thedetails that is re4uired.
d. Police, regional administrator and passport administrator get
necessary details and verification of the applicant are denoted from
the et detail state and verification state
AC#I5I#4 "IAGRAM
An activity diagram is a variation or special case of a state machine in which the
states or activity representing the performance of operation and transitions aretriggered by the completion of operation.
The purpose is to provide view of close and what is going on inside a use case or
among several classes. An activity is shown as rounded bo% containing the name of
operation.
8/9/2019 Cs2357 Ooad Lab Manual
43/349
"OC%MEN#A#ION O$ AC#I5I#4 "IAGRAM
a. The activities in the passport automation system are login, submit
details, get details, issue passport and penalty and verification.
b. In the login activity applicant give username and password and then
login into the passport automation system after then fill the details that
are re4uired for application.
c. After the verification procedure completed successfully the passport is
issued to the applicant.
8/9/2019 Cs2357 Ooad Lab Manual
44/349
COMPONEN# "IAGRAM
The component diagram is represented by figure dependency and it is a graph of
design of figure dependency.
"OC%MEN#A#ION O$ COMPONEN# "IAGRAM
a. The components in the passport automation system are passport
automation system, applicant, passport administrator, regional
administrator, and police.
b. Applicant ,passport administrator, regional administrator and police
are dependent on passport automation system are shown by the dotted
arrow
"EPLO4MEN# "IAGRAM
It is a graph of nodes connected by communication association. It is represented by
a three dimensional bo%. The basic element of a deployment diagram is a node of
two types
"E5ICE NO"E
A physical computing resource with processing and memory service to e%ecute
software, such as a typical computer or a mobile phone.
E@EC%#ION EN5IRONMEN# NO"E
8/9/2019 Cs2357 Ooad Lab Manual
45/349
This is a software computing resource that runs within an outer node and which
itself provides a service to host an e%ecute other e%ecutable software element.
"OC%MEN#A#ION O$ "EPLO4MEN# "IAGRAM
The device node is passport automation system and e%ecution environment node
are applicant passport administrator, regional administrator, and police.
PACAGE "IAGRAM
A package diagram is represented as a folder shown as a large rectangle with a topattached to its upper left corner. A package may contain both sub ordinate package
and ordinary model elements. All uml models and diagrams are organi!ed into
package
8/9/2019 Cs2357 Ooad Lab Manual
46/349
8/9/2019 Cs2357 Ooad Lab Manual
47/349
"OC%MEN#A#ION O$ PACAGE "IAGRAM
a. The three layer in the passport automation system are user interface
layer, domain layer, technical service layer
b. The user interface layer represents the user interface components such
as web, applicant, passport administrator, police, and regional
administrator.
c. The domain layer has ma;or actions such as give and get details,
verification and issues.
d. Technical service layer, authenticated user only can access the
technical services.
$ORM&
$ORM 1
$ORM
8/9/2019 Cs2357 Ooad Lab Manual
48/349
8/9/2019 Cs2357 Ooad Lab Manual
49/349
FORM 3
8/9/2019 Cs2357 Ooad Lab Manual
50/349
FORM 4
8/9/2019 Cs2357 Ooad Lab Manual
51/349
FORM 5
8/9/2019 Cs2357 Ooad Lab Manual
52/349
FORM 6
8/9/2019 Cs2357 Ooad Lab Manual
53/349
FORM 7
8/9/2019 Cs2357 Ooad Lab Manual
54/349
&O%RCE CO"E
L*gin"em*!ja8a DDL*gin$*rm
import ;ava%.swing.NO
import ;ava.awt.NO
import ;ava.awt.event.NO
import ;ava.s4l.NO
class 6oginemo
K:utton S2:MITO
KErame fO
K6abel label,label"O
final KTe%tEield te%tO
final KPasswordEield te%t"O
6oginemo#$
fDnew KErame#$O
f.get3ontentPane#$.set6ayout#null$O
label D new K6abel#$Olabel.setTe%t#B2ser5ameB$O
label.set:ounds#)++,*+,++,"+$O
8/9/2019 Cs2357 Ooad Lab Manual
55/349
te%t D new KTe%tEield#"*$O
te%t.set:ounds#*++,*+,++,"+$O
label" D new K6abel#$O
label".setTe%t#BPasswordB$O
label".set:ounds#)++,>+,++,"+$O
te%t" D new KPasswordEield#"*$O
te%t".set:ounds#*++,>+,++,"+$O
S2:MITDnew K:utton#B6oginB$OS2:MIT.set:ounds#)++,+,++,"+$O
QQ 5(F2S(/Dnew K:utton#B3reate AccountB$O
QQ5(F2S(/.set:ounds#*++,+,"++,"+$O
f.add#label$O
f.add#te%t$O
f.add#label"$O
f.add#te%t"$O
f.add#S2:MIT$O
QQf.add#5(F2S(/$O
f.setSi!e#+"),->$Of.setTitle#BPassport Automation SystemB$O
f.set9isible#true$O
S2:MIT.addAction6istener#new Action6istener#$
public void actionPerformed#Action(vent ae$
String valueDte%t.getTe%t#$O
String value"Dte%t".getTe%t#$O
String userDBBOString passDBBO
String user"DBBO
String pass"DBBO
try
3lass.for5ame#Bsun.;dbc.odbc.Kdbc0dbcriverB$O
3onnection con D riverManager.get3onnection#BKdbc0dbcpassB,BB,BB$O
Statement st D con.createStatement#$O
/esultSet res D st.e%ecuteRuery#BS(6(3T N E/0M login where
usernameD'BHvalueHB' and passwordD'BHvalue"HB'B$O
while #res.ne%t#$$user D res.getString#BusernameB$O
pass D res.getString#BpasswordB$O
if#value.e4uals#user"$
8/9/2019 Cs2357 Ooad Lab Manual
56/349
else
K0ptionPane.showMessageialog#null,BIncorrect login or
passwordB,B(rrorB,K0ptionPane.(//0/CM(SSA($O
catch#(%ception e$
System.out.println#e.getMessage#$$O $O
public static void main#String argL$
6oginemo frameDnew 6oginemo#$O
3reateAccount.;ava JJata (ntry Eorm
import ;ava%.swing.NO
import ;ava.awt.NO
import ;ava.s4l.NO
import ;ava.awt.event.NOimport ;ava.lang.String.NO
class 3reateAccount e%tends KErame
KTe%tEield te%t,te%t",te%t&,te%t&,te%t),te%t*,te%t,te%t-,te%t>O
K6abel label,label",label&,label&,label),label*,label,label-,label>O
KPanel panelO
K:utton button,button",button&O
String reDB BO
3reateAccount#$
te%tDnew KTe%tEield#*$O
te%t"Dnew KTe%tEield#*$O
te%t&Dnew KTe%tEield#*$O
te%t&Dnew KTe%tEield#*$O
te%t)Dnew KTe%tEield#*$O
te%t*Dnew KTe%tEield#*$O
te%tDnew KTe%tEield#*$O
te%t-Dnew KTe%tEield#*$O
te%t>Dnew KTe%tEield#*$OlabelDnew K6abel#B5ameB$O
label"Dnew K6abel#BEathernameB$O
label&Dnew K6abel#B.0.:B$O
label&Dnew K6abel#BenderB$O
label)Dnew K6abel#BPermanentAddressB$O
label*Dnew K6abel#BTemporary AddressB$O
labelDnew K6abel#BProofB$O
8/9/2019 Cs2357 Ooad Lab Manual
57/349
label-Dnew K6abel#B3ontact 5umberB$O
label>Dnew K6abel#B(mailidB$O
buttonDnew K:utton#BSaveB$O
button"Dnew K:utton#B9erificationB$O
button&Dnew K:utton#B/esetB$O
panelDnew KPanel#new rid6ayout#,"$$O
panel.add#label$O
panel.add#te%t$O panel.add#label"$O
panel.add#te%t"$O
panel.add#label&$O
panel.add#te%t&$O
panel.add#label&$O
panel.add#te%t&$O
panel.add#label)$O
panel.add#te%t)$O
panel.add#label*$O
panel.add#te%t*$O panel.add#label$O
panel.add#te%t$O
panel.add#label-$O
panel.add#te%t-$O
panel.add#label>$O
panel.add#te%t>$O
panel.add#button$O
panel.add#button"$O
panel.add#button&$O button.addAction6istener#new Action6istener#$
public void actionPerformed#Action(vent ae$
String valueDte%t.getTe%t#$O
String value"Dte%t".getTe%t#$O
String value&Dte%t&.getTe%t#$O
String value&Dte%t&.getTe%t#$O
String value)Dte%t).getTe%t#$O
String value*Dte%t*.getTe%t#$OString valueDte%t.getTe%t#$O
String value-Dte%t-.getTe%t#$O
String value>Dte%t>.getTe%t#$O
try
3lass.for5ame#Bsun.;dbc.odbc.Kdbc0dbcriverB$O
3onnection con D riverManager.get3onnection#BKdbc0dbcpassB,BB,BB$O
Statement st D con.createStatement#$O
8/9/2019 Cs2357 Ooad Lab Manual
58/349
int kDst.e%ecute2pdate#Binsert into
userdetails#name,fathername,dateofbirth,gender,permanentaddress,temporaryaddre
ss,phoneno,emailid,proof$
values#'BHvalueHB','BHvalue"HB','BHvalue&HB','BHvalue&HB','BHvalue)HB','BHvalue*
HB','BHvalue-HB','BHvalue>HB','BHvalueHB'$B$O
K0ptionPane.showMessageialog#null,Bata is successfully insertedB$O
catch#(%ception e$
System.out.println#e$O
$O
add#panel$O
setSi!e#"++,)++$O
set9isible#true$O
button".addAction6istener#new Action6istener#$
public void actionPerformed#Action(vent ae$
if#ae.getSource#$DDbutton"$
a f"Dnew a#$O
f".setSi!e#>++,++$O
f".setTitle#BPassport Administrator 9erificationB$O
f".show#$O
else
$O
button&.addAction6istener#new Action6istener#$
public void actionPerformed#Action(vent ae$
te%t.setTe%t#re$Ote%t".setTe%t#re$O
te%t&.setTe%t#re$O
te%t&.setTe%t#re$O
te%t).setTe%t#re$O
te%t*.setTe%t#re$O
te%t.setTe%t#re$O
te%t-.setTe%t#re$O
te%t>.setTe%t#re$O
8/9/2019 Cs2357 Ooad Lab Manual
59/349
$O
public static void main#String argsL$
3reateAccount accDnew 3reateAccount#$O
a.;ava JJ Passport adminstrator
import ;ava%.swing.NO
import ;ava.awt.NO
import ;ava.awt.event.NO
import ;ava.s4l.NO
class a e%tends KErame implements Action6istener,Item6istener
K:utton search,del,reg,verifyO
K6abel name,findO
K3ombo:o% listOKTe%tEield te%tO
3ontainer con,conO
String searchte%t,searchfield,s4lO
/esultSet rsO
/esultSet rsO
KTable tableO
0b;ect rowsLLO
int tvalD+,tvalD+O
KScrollPane scrollPaneOString verDB9erifiedBO
a#$
conDget3ontentPane#$O
con.set6ayout#null$O
conDget3ontentPane#$O
con.set6ayout#null$O
rowsDnew 0b;ectL*+L&O
0b;ect headersL D
BnameB,BfathernameB,BdateofbirthB,BgenderB,BpermanentaddressB,Btemporaryaddr essB,BphonenoB,BemailidB,BproofB,BadminverifyB,BregverifyB,BpoliceverifyBO
table D new KTable#rows, headers$O
scrollPane D new KScrollPane#table$O
scrollPane.set:ounds#"*+,*+,*++,&++$O
scrollPane.set:ackground#3olor.F1IT($O
8/9/2019 Cs2357 Ooad Lab Manual
60/349
con.add#scrollPane$O
searchDnew K:utton#BSearchB$O
search.set:ounds#&++,*++,++,"*$O
con.add#search$O
search.addAction6istener#this$O
delDnew K:utton#BeleteB$O
del.set:ounds#&?+,*++,++,"*$O
con.add#del$Odel.addAction6istener#this$O
verifyDnew K:utton#B9erifiedB$O
verify.set:ounds#)?+,*++,++,"*$O
con.add#verify$O
verify.addAction6istener#this$O
regDnew K:utton#B/egional 9erificationB$O
reg.set:ounds#*>+,*++,++,"*$O
con.add#reg$O
reg.addAction6istener#this$O
nameDnew K6abel#B1ow To Search B$Oname.set:ounds#++,++,"++,"*$O
con.add#name$O
findDnew K6abel#BB$O
find.set:ounds#&++,)*+,&*+,)+$O
con.add#find$O
te%tDnew KTe%tEield#$O
te%t.set:ounds#)+,++,++,"*$O
con.add#te%t$O
te%t.addAction6istener#this$OlistDnew K3ombo:o%#$O
list.setModel#new efault3ombo:o%Model#new StringL BSelectB,BproofB $$O
list.set:ounds#&++,++,++,"*$O
con.add#list$O
list.addItem6istener#this$O
public void actionPerformed#Action(vent ae$
8/9/2019 Cs2357 Ooad Lab Manual
61/349
if#ae.getSource#$DDte%t$
find.setTe%t#BB$O
if#ae.getSource#$DDdel$
String getdelDK0ptionPane.showInputialog#search, B(nter the Proofno
B,BPassPortB,$O
try
3lass.for5ame#Bsun.;dbc.odbc.Kdbc0dbcriverB$O3onnection cntn&DriverManager.get3onnection#BKdbc0dbcpassB,BB,BB$O
Statement ste&Dcntn&.createStatement#$O
ste&.e%ecute2pdate#Bdelete from userdetails where proof D'BHgetdelHB'B$O
find.setTe%t#B2S(/(TAI6 (6(T(B$O
catch#(%ception dele$
if#ae.getSource#$DDverify$
try
3lass.for5ame#Bsun.;dbc.odbc.Kdbc0dbcriverB$O
3onnection cntn&DriverManager.get3onnection#BKdbc0dbcpassB,BB,BB$O
Statement ste&Dcntn&.createStatement#$O
String rtDte%t.getTe%t#$O
ste&.e%ecute2pdate#B2PAT( userdetails S(T adminverifyD'BHverHB' where
proofD'BHrtHB'B$O
find.setTe%t#B2S(/(TAI6 9(/IEI(B$O
catch#(%ception dele$
if#ae.getSource#$DDreg$
try
b g"Dnew b#$Og".setTitle#B/egional 0fficer 9erificationB$O
8/9/2019 Cs2357 Ooad Lab Manual
62/349
catch#(%ception reg$
if#ae.getSource#$DDsearch$
if#searchfieldDDnull$find.setTe%t#BPlease Select Search 3ategory..,B$O
else
s4lDBselect N from userdetails where BO
s4lHDsearchfieldO
s4lHDBD'BHte%t.getTe%t#$HB'BO
System.out.println#s4l$O QQ the 4uery for s4l statement
try
3lass.for5ame#Bsun.;dbc.odbc.Kdbc0dbcriverB$O
3onnection cntnDriverManager.get3onnection#BKdbc0dbcpassB,BB,BB$OStatement steDcntn.createStatement#$O
rsDste.e%ecuteRuery#s4l$O
tvalD+O
while#rs.ne%t#$$
table.set9alueAt#BBHrs.getString#$,tval,+$O
table.set9alueAt#BBHrs.getString#"$,tval,$O
table.set9alueAt#BBHrs.getString#&$,tval,"$O
table.set9alueAt#BBHrs.getString#)$,tval,&$Otable.set9alueAt#BBHrs.getString#*$,tval,)$O
table.set9alueAt#BBHrs.getString#$,tval,*$O
table.set9alueAt#BBHrs.getString#-$,tval,$O
table.set9alueAt#BBHrs.getString#>$,tval,-$O
table.set9alueAt#BBHrs.getString#?$,tval,>$O
table.set9alueAt#BBHrs.getString#+$,tval,?$O
table.set9alueAt#BBHrs.getString#$,tval,+$O
table.set9alueAt#BBHrs.getString#"$,tval,$O
tvalHHO
if#tvalDD+$
find.setTe%t#Betails 5ot Availabel# BHsearchfieldHB BHte%t.getTe%t#$HB $Jn Tri
Again...,B$O
catch#(%ception e$
K0ptionPane.showMessageialog#search,BSorry,ata:ase Problem,B,BPassPort
System,B,K0ptionPane.I5E0/MATI05CM(SSA($O
8/9/2019 Cs2357 Ooad Lab Manual
63/349
public void itemState3hanged#Item(vent ie$
find.setTe%t#BB$O
te%t.setTe%t#BB$Olist.removeItem#BSelectB$O
for#int iD+OitvalOiHH$
table.set9alueAt#BB,i,+$O
QQtable.set9alueAt#BB,i,$O
QQtable.set9alueAt#BB,i,"$O
searchfieldDBBHie.getItem#$O
setSi!e#>++,++$O
setTitle#BPassPort SystemB$Osetefault3lose0peration#KErame.(UITC05C360S($O
set9isible#true$O
set/esi!able#false$O
public static void main#StringL argv$
a f"Dnew a#$O
b.;ava JJ/egional officer form
import ;ava%.swing.NO
import ;ava.awt.NO
import ;ava.awt.event.NO
import ;ava.s4l.NO
class b e%tends KErame implements Action6istener
K:utton S2:MIT,verify,policeO
KErame fO
K6abel label,label"Ofinal KTe%tEield te%t, te%t"O
b#$
8/9/2019 Cs2357 Ooad Lab Manual
64/349
fDnew KErame#$O
f.get3ontentPane#$.set6ayout#null$O
label D new K6abel#$O
label.setTe%t#B5ameB$O
label.set:ounds#)++,*+,++,"+$O
te%t D new KTe%tEield#"*$O
te%t.set:ounds#*++,*+,++,"+$O
label" D new K6abel#$Olabel".setTe%t#BProof noB$O
label".set:ounds#)++,>+,++,"+$O
te%t" D new KTe%tEield#"*$O
te%t".set:ounds#*++,>+,++,"+$O
S2:MITDnew K:utton#BfindB$O
S2:MIT.set:ounds#)++,+,++,"+$O
verifyDnew K:utton#BverifiedB$O
verify.set:ounds#*++,+,++,"+$O
policeDnew K:utton#BPolice 9erificationB$O
police.set:ounds#++,+,+,"+$O police.addAction6istener#this$O
f.add#label$O
f.add#te%t$O
f.add#label"$O
f.add#te%t"$O
f.add#S2:MIT$O
f.add#verify$O
f.add#police$O
f.setTitle#BPassport Automation System/egional 0fficer 9erificationB$Of.setSi!e#?++,*++$O
f.set9isible#true$O
S2:MIT.addAction6istener#new Action6istener#$
public void actionPerformed#Action(vent ae$
String valueDte%t.getTe%t#$O
String value"Dte%t".getTe%t#$O
String userDBBO
String passDBBOString user"DBBO
String pass"DBBO
String verDB9erifiedBO
try
8/9/2019 Cs2357 Ooad Lab Manual
65/349
3lass.for5ame#Bsun.;dbc.odbc.Kdbc0dbcriverB$O
3onnection con D riverManager.get3onnection#BKdbc0dbcpassB,BB,BB$O
Statement st D con.createStatement#$O
/esultSet res D st.e%ecuteRuery#BS(6(3T N E/0M /egionalatabase where
5ameD'BHvalueHB' and ProofD'BHvalue"HB'B$O
while #res.ne%t#$$
user D res.getString#B5ameB$O
pass D res.getString#BProofB$O
if#value.e4uals#user"$
8/9/2019 Cs2357 Ooad Lab Manual
66/349
catch#(%ception police$
public static void main#String argL$
b g"Dnew b#$O
c.;ava JJPolice 9erification Eorm
import ;ava%.swing.NO
import ;ava.awt.NO
import ;ava.awt.event.NO
import ;ava.s4l.NO
class c
K:utton S2:MIT,verifyOKErame fO
K6abel label,label",label&O
final KTe%tEield te%t, te%t",te%t&O
c#$
fDnew KErame#$O
f.get3ontentPane#$.set6ayout#null$O
label D new K6abel#$O
label.setTe%t#B5ameB$Olabel.set:ounds#)++,*+,++,"+$O
te%t D new KTe%tEield#"*$O
te%t.set:ounds#*++,*+,++,"+$O
label" D new K6abel#$O
label".setTe%t#BpermanentaddressB$O
label".set:ounds#)++,>+,++,"+$O
te%t" D new KTe%tEield#"*$O
te%t".set:ounds#*++,>+,++,"+$O
label& D new K6abel#$O
label&.setTe%t#BtemporaryaddressB$Olabel&.set:ounds#)++,+,++,"+$O
te%t& D new KTe%tEield#"*$O
te%t&.set:ounds#*++,+,++,"+$O
8/9/2019 Cs2357 Ooad Lab Manual
67/349
S2:MITDnew K:utton#BfindB$O
S2:MIT.set:ounds#)++,*+,++,"+$O
verifyDnew K:utton#BverifiedB$O
verify.set:ounds#*++,*+,"++,"+$O
f.add#label$O
f.add#te%t$O
f.add#label"$O
f.add#te%t"$Of.add#label&$O
f.add#te%t&$O
f.add#S2:MIT$O
f.add#verify$O
f.setTitle#BPassport Automation SystemPolice 9erificationB$O
f.setSi!e#?++,*++$O
f.set9isible#true$O
S2:MIT.addAction6istener#new Action6istener#$
public void actionPerformed#Action(vent ae$
String valueDte%t.getTe%t#$O
String value"Dte%t".getTe%t#$O
String value&Dte%t&.getTe%t#$O
String userDBBO
String passDBBO
String pass&DBBO
String user"DBBO
String pass"DBBOString pass)DBBO
String verDB9erifiedBO
try
3lass.for5ame#Bsun.;dbc.odbc.Kdbc0dbcriverB$O
3onnection con D riverManager.get3onnection#BKdbc0dbcpassB,BB,BB$O
Statement st D con.createStatement#$O
/esultSet res D st.e%ecuteRuery#BS(6(3T N E/0M Policeb where
5ameD'BHvalueHB' and permanentaddressD'BHvalue"HB' and
temporaryaddressD'BHvalue&HB'B$Owhile #res.ne%t#$$
user D res.getString#B5ameB$O
pass D res.getString#BpermanentaddressB$O
pass& Dres.getString#BtemporaryaddressB$O
if#value.e4uals#user"$
8/9/2019 Cs2357 Ooad Lab Manual
68/349
K0ptionPane.showMessageialog#null,BType the name and
ProofB,B(rrorB,K0ptionPane.(//0/CM(SSA($O
else if#value.e4uals#user$
8/9/2019 Cs2357 Ooad Lab Manual
69/349
E@ NO 'OO 'AN MANAGEMEN# &4EM
AIM
To develop a pro;ect of :ook bank management system using /ational /ose
Software and to implement the software in 9isual :asic.
PRO'LEM ANAL4&I& AN" PRO7EC# "E&IGN
The book bank management system is an software in which a member can register
themselves and then he can borrow books from the book bank. It mainly
concentrates on providing books for engineering students.
PRO'LEM A#EMEN#
The process of members registering and purchasing books from the book bank are
described se4uentially through following steps
a. Eirst the member registers himself if he was new to the book bank.
b. 0ld members will directly select old member button..
c. They select their corresponding year.
d. After selecting the year they fill the necessary details and select the
book and he will be directed towards administrator
e. The administrator will verify the status and issue the book.
&O$#ARE REB%IREMEN# &PECI$ICA#ION
&!NO CON#EN#&
1!
IN#RO"%C#ION
!
O'7EC#I5E
!
O5ER5IE
GLO&&AR4
8/9/2019 Cs2357 Ooad Lab Manual
70/349
=!
.!
P%RPO&E
6!
&COPE
/!
$%NC#IONALI#4
>!
%&A'ILI#4
?!
PER$ORMANCE
10!
RELIA'ILI#4
$%NC#IONAL REB%IREMEN#&
11!
E@#ERNAL IN#ER$ACE
REB%REMEN#&
1! IN#RO"%C#ION
This system would be used by members who are students of any college to check
the availability of the books and borrow the books, and then the databases are
8/9/2019 Cs2357 Ooad Lab Manual
71/349
updated. The purpose of this document is to analy!e and elaborate on the high7
level needs and features of the book bank management system! It also tells the
usability, reliability defined in use case specification.
! O'7EC#I5E
The main ob;ective of the system are was to design an online book7bank
monitoring system to enable a central monitoring mechanism of the book7bank bemore faster and less error prone. Apart from this,
a. To help the students ac4uire the right books for the syllabus at the
right time.
b. To ensure availability of basic te%tbooks to students against limited
funds and To develop students ability to handle property loaned to
them
.
! O5ER5IE
The overview of this pro;ect is to design a tool for book bank so that it can be used
by any book banks to lend their books as well as colleges.
=! GLO&&AR4
#ERM& "E&CRIP#ION
M(M:(/ The one who registers himself and
purchase books from the bank.
ATA:AS( atabase is used to store the details
of members and books.
AMI5IST/AT0/ The one who verifies the
availability of book and issue them
2S(/ MemberS0ETFA/( /(R2I/(M(5T
SP(3IEI3ATI05
This software specification
documents full set of features and
function for online recruitment
system that is performed in
company website.
.! P%RPO&E
The purpose of the book bank management system is to reduce the manual
8/9/2019 Cs2357 Ooad Lab Manual
72/349
intervention .
6! &COPE
The scope of this book bank management system is to act as a tool for book bank
administrator for 4uick reference, availability of the books.
/! $%NC#IONALI#4
Many members will be waiting to take the book from the book bank at a single
day. To serve all the members
>! %&A'ILI#4
2ser interface makes the /ecruitment system to be efficient. That is the system
will help the member to register easily and helps them to get their books easily.
The system should be user friendly.
?! PER$ORMANCE
It describes the capability of the system to perform the recruitment process of the
applicant without any error and performing it efficiently.
10! RELIA'ILI#4
The book bank management system should be able to serve the applicant
withcorrect information and day7to7day update of information.
11! $%NC#IONAL REB%IREMEN#&
Eunctional re4uirements are those refer to the functionality of the system.
That is the services that are provided to the member who borrows book.
1! E@#ERNAL IN#ER$ACE REB%IREMAN#&
&O$#ARE REB%IREMEN#&
. $r*n end I:M rational rose enterprise edition.
". 'ak end visual basic >.+.
AR"ARE REB%IREMEN#&
. Pr*ess*r pentium ).
8/9/2019 Cs2357 Ooad Lab Manual
73/349
". RAM .6 mb
&. Operaing s3aem Microsoft windows %p.
). $ree disk spae 1gb
%ML "IAGRAM&
The following 2M6 diagrams describe the process involved in the online
recruitment system
a. 2se case diagram
b. 3lass diagram
c. Se4uence diagram
d. 3ollaboration diagram
e. State chart diagram
f. Activity diagram
g. 3omponent diagram
h. eployment diagram
i. Package diagram
%&E CA&E "IAGRAM
A use case is a methodology used in system analysis to identify, clarify, and
organi!e system re4uirements. The use case is made up of a set of possible
se4uences of interactions between systems and users in a particular environment
and related to a particular goal. It is represented using ellipse.
Actor is any e%ternal entity that makes use of the system being modeled. It isrepresented using stick figure.
"OC%MEN#A#ION O$ %&E CA&E "IAGRAM
The actors in this use case diagram are member and database. The use cases are the
activities performed by actors.
a. The member will register himself in the book bank.
b. After registration he will select the year to which he belongs
c. After selecting he will select books
d. atabase will verify the status of book and the books will be given.
8/9/2019 Cs2357 Ooad Lab Manual
74/349
CLA&& "IAGRAM
A class diagram in the unified modeling language #2M6$ is a type of static
structure diagram that describes the structure of a system by showing the system's
classes, their attributes, and the relationships between the classes. It is represented
using a rectangle with three compartments. Top compartment have the class name,
middle compartments the attributes and the bottom compartment with operations.
"OC%MEN#A#ION O$ CLA&& "IAGRAM
This class diagram has > classes
o Mem)er deai2s 2ass- is the class name. Its attributes are name,
father name, date of birth, address, phone number, member id,
college, degree, course and semester. Its operations are registration,authentication, and year selection.
o Adminisra*r- is the class name. Its attributes are name, address,
phone, mail id. Its operations are authentication, verification and issue
books.
o 4ear-is the class name. Its attribute is year selection. Its operations are
st year,"nd year, &rd year,)th year.
o Iss(e 9*r 1s 3ear-is the class name. Its attributes are member code,
member name, book code, book name, and 4uantity. Its operation is
issue
Iss(e 9*r nd 3ear-is the class name. Its attributes are member code,
member name, book code, book name, and 4uantity. Its operation is
issue
o Iss(e 9*r rd 3ear-is the class name. Its attributes are member code,member name, book code, book name, and 4uantity. Its operation is
issue
&EB%ENCE "IAGRAM
A se4uence diagram in 2nified Modeling 6anguage #2M6$ is a kind of interaction
diagram that shows how processes operate with one another and in what order. It is
a construct of a Message Se4uence 3hart. There are two dimensions.
8/9/2019 Cs2357 Ooad Lab Manual
75/349
. 9eritcal dimension7represent time.
". 1ori!ontal dimension7represent different ob;ects.
"OC%MEN#A#ION O$ &EB%ENCE "IAGRAM
The se4uence diagram describes the se4uence of steps to show
a. The member registers himself in book bank
b. 1e will select the year
c. 1e select the books given and the database will update the status of
book.
d. Then administrator will log in and verify the status of books.
e. If the book is available he will issue the book.
COLLA'RA#ION "IAGRAM
A collaboration diagram, also called a communication diagram or interaction
diagram,. A sophisticated modeling tool can easily convert a collaboration diagram
into a se4uence diagram and the vice versa. A collaboration diagram resembles a
flowchart that portrays the roles, functionality and behavior of individual ob;ects as
well as the overall operation of the system in real time
"OC%MEN#A#ION O$ COLLA'ORA#ION "IAGRAM
The collaboration diagram is to show how the member registers himself and
borrow the book from the book bank. 1ere the se4uence is numbered according to
the flow of e%ecution.
A#E CAR# "IAGRAM
The purpose of state chart diagram is to understand the algorithm involved in
performing a method. It is also called as state diagram. A state is represented as a
round bo%, which may contain one or more compartments. An initial state is
represented as small dot. An final state is represented as circle surrounding a small
dot.
"OC%MEN#A#ION O$ A#E CAR# "IAGRAM
This state diagram describes the behavior of the system.
8/9/2019 Cs2357 Ooad Lab Manual
76/349
a. In the first state the member registers himself in book bank
b. After that he will select the year in ne%t state.
c. In the ne%t state he will select the books.
d. In the ne%t state database will update the status of book.
e. In the ne%t state administrator will log in.
f. After authentication he will verify the availability of book.
g. If available he will issue the book.
h.
AC#I5I#4 "IAGRAM
Activity diagrams are graphical representations of workflows of stepwise activities
and actions with support for choice, iteration and concurrency. In the 2nified
Modeling 6anguage, activity diagrams can be used to describe the business and
operational step7by7step workflows of components in a system. An activity
diagram shows the overall flow of control. An activity is shown as an rounded bo%
containing the name of the operation
8/9/2019 Cs2357 Ooad Lab Manual
77/349
"OC%MEN#A#ION O$ AC#I5I#4 "IAGRAM
This activity diagram flow of stepwise activities performed in book bank
management system.
a. The member registers himself in book bank
b. After that he will select the year.
c. 1e will select the books.
d. atabase will update the status of book.
e. atabase will update the details
f. Then the administrator will log in to his account.
g. After authentication he will verify the availability of book.
h. If available he will issue the book.
COMPONEN# "IAGRAM
The component diagram's main purpose is to show the structural relationships between the components of a system. It is represented by bo%ed figure.
ependencies are represented by communication association
"OC%MEN#A#ION O$ COMPONEN# "IAGRAM
8/9/2019 Cs2357 Ooad Lab Manual
78/349
The main component in this component diagram is online book bank management
systems. And member details, issue for first year, issue for second year issue for
third year and issue for fourth year are components comes under the main
component
"EPLO4MEN# "IAGRAM
A deployment diagram in the unified modeling language serves to model the physical deployment of artifacts on deployment targets. eployment diagrams
show Bthe allocation of artifacts to nodes according to the eployments defined
between them. It is represented by &7dimentional bo%. ependencies are
represented by communication association.
"OC%MEN#A#ION O$ "EPLO4MEN# "IAGRAM
The processor in this deployment diagram is the book bank which is the main part
and which are the some of the main activities performed in the system. And issue
for first year, issue for second year issue for third year and issue for fourth year are
some activities performed in this system.
PACAGE "IAGRAM
A package diagram in unified modeling language that depicts the dependencies
between the packages that make up a model. A Package iagram #P$ shows a
grouping of elements in the 00 model, and is a 3radle e%tension to 2M6. Ps can
be used to show groups of classes in 3lass iagrams #3s$, groups of components
or processes in 3omponent iagrams #3Ps$, or groups of processors ineployment iagrams #Ps$.
There are three types of layer. They are
o 2ser interface layer
o omain layer
o
Technical services layer
8/9/2019 Cs2357 Ooad Lab Manual
79/349
"OC%MEN#A#ION O$ PACAGE "IAGRAM
The three layers in the online recruitment system are
a. #he %ser iner9ae 2a3er 7 consists of the web and member details.
This layer describes how the member goes to book bank and registers
himself..
b. #he "*main 2a3er = shows the activities that are performed in the
book bank management system. The activities are register and book
issues..
c. #he #ehnia2 ser8ie 2a3er - the member details and verification
details are stored in the database.
$ORM&
$ORM 1
8/9/2019 Cs2357 Ooad Lab Manual
80/349
$ORM
8/9/2019 Cs2357 Ooad Lab Manual
81/349
$ORM =
8/9/2019 Cs2357 Ooad Lab Manual
82/349
$ORM .
8/9/2019 Cs2357 Ooad Lab Manual
83/349
$ORM 6
8/9/2019 Cs2357 Ooad Lab Manual
84/349
$ORM /
8/9/2019 Cs2357 Ooad Lab Manual
85/349
$ORM >
8/9/2019 Cs2357 Ooad Lab Manual
86/349
$ORM ?
8/9/2019 Cs2357 Ooad Lab Manual
87/349
8/9/2019 Cs2357 Ooad Lab Manual
88/349
&O%RCE CO"E
Adminisra*r! C2ass
0ption (%plicit
'GGModel IdD)*A"E3)+&>A
Private name As 9ariant
'GGModel IdD)3:>&:++
Private address As 9ariant
'GGModel IdD)3:>)?+"(
Private phone As 9ariant
'GGModel IdD)3:>*++++
Private mail id As 9ariant
'GGModel IdD)*A&)->+">+
Public 5ew Property As year'GGModel IdD)*A&)>:+"?+
Public 5ewProperty" As database
'GGModel IdD)*A&:&+?
Public Sub authentication #$
0n (rror o To (rror 1andler
'GG your code goes here...
If Eorm+.Te%t.Te%t D BadminB And Eorm+.Te%t".Te%t D B"&)B Then
Msg:o% Blogin successfullyB
Eorm?.Show
(lse
Msg:o% Binvalid passwordB
(nd If
(%it Sub
(rror1andler
3all /aise (rror #My 2nhandled (rror, Bauthentication SubB$
(nd Sub
'GGModel IdD)*A&()+":E
Public Sub verification #$
0n (rror o To (rror 1andler'GG your code goes here...
(%it Sub
(rror 1andler
3all /aise (rror #My 2nhandled (rror , Bverification SubB$
(nd Sub
'GGModel IdD)3:>()+&:?
Public Sub issueCbooks#$
0n (rror o To (rror 1andler
'GG your code goes here...
8/9/2019 Cs2357 Ooad Lab Manual
89/349
(%it Sub
(rror 1andler
3all /aise (rror #My 2nhandled (rror, BissueCbooks SubB$
(nd Sub
"aa)ase !2ass
0ption (%plicit
'GGModel IdD)*A"E:++">
Private name As 9ariant
8/9/2019 Cs2357 Ooad Lab Manual
90/349
'GGModel IdD)*+>"+3*
Public Sub update #$
0n (rror o To (rror 1andler
'GG your code goes here...
(%it Sub
(rror 1andler
3all /aise (rror #My 2nhandled (rror , Bupdate SubB$
(nd Sub4ear ! C2ass
0ption (%plicit
'GGModel IdD)*A&-E++A
Private yearCselection As 9ariant
'GGModel IdD)*A&?:+">
Public Sub styear#$
0n (rror oTo (rror1andler
'GG your code goes here...
(%it Sub
(rror1andler3all /aise(rror#My2nhandled(rror, Bstyear SubB$
(nd Sub
'GGModelIdD)*A&?E++3:
Public Sub "ndCyear#$
0n (rror oTo (rror1andler
'GG your code goes here...
(%it Sub
(rror1andler
3all /aise(rror#My2nhandled(rror, BndCyear SubB$(nd Sub
'GGModelIdD)*A&A"+&"3
Public Sub &rdCyear#$
0n (rror oTo (rror1andler
'GG your code goes here...
(%it Sub
(rror1andler
3all /aise(rror#My2nhandled(rror, BrdCyear SubB$
(nd Sub
Iss(e 9*r 9irs 3ear! 2ass0ption (%plicit
'GGModelIdD)*A&&>++E
Private memberCcode As 9ariant
'GGModelIdD)*A&&>++-+
Private memberCname As 9ariant
8/9/2019 Cs2357 Ooad Lab Manual
91/349
'GGModelIdD)*A&&>++-"
Private bookCname As 9ariant
'GGModelIdD)*A&)-:+&:?
Public 5ewProperty As year
'GGModelIdD)*A&&>++(
Public Sub issueCforCfirst#$
0n (rror oTo (rror1andler
'GG your code goes here...Eorm.ata./ecordset.Add5ew
Eorm.Te%t*.Te%t D Eorm.Te%t*.Te%t H
Eorm.Te%t).Te%t D Eorm.Te%t).Te%t 7
If #Eorm.Te%t).Te%t D +$ Then
Msg:o% Bonly four books can be selectedB
Eorm>.Show
(nd If
(%it Sub
(rror1andler
3all /aise(rror#My2nhandled(rror, BissueCforCfirst SubB$(nd Sub
Iss(e 9*r se*nd 3ear 2ass
0ption (%plicit
'GGModelIdD)*A&&?+"((
Private memberCcode As 9ariant
'GGModelIdD)*A&&3+&>
Private memberCname As 9ariant
'GGModelIdD)*A&&(&+-
Private bookCname As 9ariant'GGModelIdD)*A&)-3+&>
Public 5ewProperty As year
'GGModelIdD)*A&&(++::
Public Sub issueCforCsecond#$
0n (rror oTo (rror1andler
'GG your code goes here...
ata./ecordset.Add5ew
Eorm-.Te%t*.Te%t D Eorm-.Te%t*.Te%t H
Eorm-.Te%t).Te%t D Te%t).Te%t 7
If #Eorm-.Te%t).Te%t D +$ ThenMsg:o% Bonly four books can be selectedB
Eorm>.Show
(nd If
(%it Sub
(rror1andler
3all /aise(rror#My2nhandled(rror, BissueCforCsecond SubB$
(nd Sub
Iss(e 9*r hird 3ear 2ass
0ption (%plicit
8/9/2019 Cs2357 Ooad Lab Manual
92/349
'GGModelIdD)*A&&E"+&:
Private memberCcode As 9ariant
'GGModelIdD)*A&&EA++(A
Private memberCname As 9ariant
'GGModelIdD)*A&)++&??
Private bookCname As 9ariant
'GGModelIdD)*A&)-(+&>
Public 5ewProperty As year'GGModelIdD)*A&)+E+:*
Public Sub issueCforCthird#$
0n (rror oTo (rror1andler
'GG your code goes here...
Eorm>.ata./ecordset.Add5ew
Eorm>.Te%t*.Te%t D Eorm>.Te%t*.Te%t H
Eorm>.Te%t).Te%t D Eorm>.Te%t).Te%t 7
If #Eorm>.Te%t).Te%t D +$ Then
Msg:o% Bonly four books can be selectedB
Eorm>.Show(nd If
(%it Sub
(rror1andler
3all /aise(rror#My2nhandled(rror, BissueCforCthird SubB$
(nd Sub
$*rm 1
Private Sub 3ommandC3lick#$
Eorm.Show
(nd SubPrivate Sub 3ommand"C3lick#$
Eorm?.Show
(nd Sub
Private Sub 3ommand&C3lick#$
Eorm*.Show
(nd Sub
$*rm
Private Sub 3ommandC3lick#$
ata./ecordset.Add5ew
(nd SubPrivate Sub 3ommand"C3lick#$
ata./ecordset.update
Eorm".Show
(nd Sub
$*rm
Private Sub 3ommandC3lick#$
Eorm).Show
(nd Sub
Private Sub 3ommand"C3lick#$
8/9/2019 Cs2357 Ooad Lab Manual
93/349
Eorm.Show
8/9/2019 Cs2357 Ooad Lab Manual
94/349
(nd Sub
Private Sub 3ommand&C3lick#$
Eorm-.Show
(nd Sub
$*rm =
Private Sub 3ommand"C3lick#$
im fi As Issue for first year
Set fi Dnew Issue for first yearfi.issueCforCfirst
(nd Sub
Private Sub 3ommand&C3lick#$
ata./ecordset.update
(nd Sub
Private Sub EormC6oad#$
Te%t).Te%t D *
Te%t*.Te%t D +
(nd Sub
Private Sub 6istC3lick#$Te%t&.Te%t D 6ist.Te%t
(nd Sub
$*rm .
Private Sub 3ommand"C3lick#$
im se As Issue for second year
Set se Dnew Issue for second year
se.issueCforCsecond
(nd Sub
Private Sub 3ommand&C3lick#$ata./ecordset.update
(nd Sub
Private Sub EormC6oad#$
Te%t).Te%t D *
Te%t*.Te%t D +
(nd Sub
Private Sub 6istC3lick#$
Te%t&.Te%t D 6ist.Te%t
(nd Sub
$*rm 6Private Sub 3ommand"C3lick#$
im th As Issue for third year
Set th Dnew Issue for third year
th.issueCforCthird
(nd Sub
Private Sub 3ommand&C3lick#$
ata./ecordset.update
(nd Sub
Private Sub EormC6oad#$
8/9/2019 Cs2357 Ooad Lab Manual
95/349
Te%t).Te%t D *
8/9/2019 Cs2357 Ooad Lab Manual
96/349
Te%t*.Te%t D +
(nd Sub
Private Sub 6istC3lick#$
Te%t&.Te%t D 6ist.Te%t
(nd Sub
$*rm /
private Sub 3ommandC3lick#$
im au As AdministratorSet au Dnew Administrator
au. authentication
(nd Sub
Private Sub 3ommand"C3lick#$
2nload Me
(nd Sub
RE&%L#
Thus the pro;ect to develop book bank management system using /ational /ose
Software and to implement the software in 9isual :asic was done successfully
E@NOa E@AM REGIRA#ION &4EM
8/9/2019 Cs2357 Ooad Lab Manual
97/349
AIM
To develop a pro;ect (%am /egistration using /ational /ose Software and to
implement the software in 9isual :asic.
PRO'LEM ANAL4&I& AN" PRO7EC# PLANNING
The (%am /egistration is an application in which applicant can register themselves
for the e%am. The details of the students who have registered for the e%amination
will be stored in a database and will be maintained. The registered details can then
be verified for any fraudulent or duplication and can be removed if found so. The
database which is verified can be used to issue hall tickets and other necessary
materials to the eligible students.
PRO'LEM A#EMEN#
The process of students accessing the registration application and applying for the
e%amination by filling out the form with proper details and then the authorities
verify those details given for truth and correctness are se4uenced through steps
a. The students access e%am registration application.
b. They fill out the form with correct and eligible details.
c. They complete the payment process.
d. The authorities verify or check the details.
e. After all verification the e%am registration database is finali!ed.
&O$#ARE REB%IREMEN# &4EM
1! IN#RO"%C#ION
8/9/2019 Cs2357 Ooad Lab Manual
98/349
1! O'7EC#I5E
1=! O5ER5IE
1.! GLO&&AR4
16! P%RPO&E
1/! &COPE
1>! $%NC#IONALI#4
1?! %&A'ILI#4
0! PER$ORMANCE
1! RELIA'ILI#