Toll plaza system

47
ACKNOWLEDEMENT In completing this graduate project I have been fortunate to have help, support and encouragement from many people. I would like to acknowledge them for their cooperation. First, I would like to thank constant guidance and encouragement received from Mr . HARISH SAINI, HEAD, Department of BSc Voc has been of the great help in the carrying out the project work and is acknowledged with rever ential thank. I would also like to thanks Ms. SHILA NAR!LA, my mentor who showed immense pati ence and unders tanding throughout the project and provided suggestion. Finally I would like to dedicate this project to my parents for their love, encouragement and help throughout the project. Farheen Chauhan 242

Transcript of Toll plaza system

Page 1: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 1/47

ACKNOWLEDEMENT

In completing this graduate project I have been fortunate to have

help, support and encouragement from many people. I would like to

acknowledge them for their cooperation.

First, I would like to thank constant guidance and encouragement

received from Mr. HARISH SAINI, HEAD , Department of BSc Voc

has been of the great help in the carrying out the project work and

is acknowledged with reverential thank.

I would also like to thanks Ms. SHIL A NAR!LA , my mentor who

showed immense patience and understanding throughout the

project and provided suggestion.

Finally I would like to dedicate this project to my parents for their

love, encouragement and help throughout the project.

Farheen Chauhan

24 2

Page 2: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 2/47

VISION

!o be the leader in the industry oriented "uality education and

training and be the country#s premier institute for certi$cation in the

$eld of information, electronics and communications technology

%I&C!'.

MISSION

(ur mission is to be the best source for "uality assurance in

software education.

Page 3: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 3/47

TABLE OF CONTENTS

TITLE PAGE NO.

Introduction 6-9

1.1 Gas Agency System

. 1.2 Types of Toll Plaza System

1.3 Project Scope

1.4 Terminology

Problem Statement !

Ob"ecti#e o$ S%&tem

Toll Pla'a (e&i)n and S*eci$ication +

,or in) En#ironment -+6

2.1 History

2.2 Front En !etails

2.2.1 A"o#t $a%a

2.2.2 Ho& oes it &or'

2.2.3 ()y $a%a

2.2.4 *nterface

2.2.+ ()y ,otepa

2.2.- ang#ages #se on ,otepa

2.3 /ac' En !etails

2.3.1 0icrosoft Access

2.3.2 History of 0S Access

2.4 )aracteristics of $a%a

2.+ A %antages of $a%a

2.- Feat#res an Specification

Page 4: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 4/47

S%&tem (e&i)n +/-06

3.1 0et)o to esign

3.2 $a%a Frame&or'

3.3 $a%a Arc)itect#re

3.4 !esign

3.4.1 o ing for 0ain page

3.+ $A A ersion

1e&ult and Anal%&i& 06-

4.1 Snaps)ots

4.2 S#mmary of es#lt

Conclu&ion 2

Future Sco*e /

1e$erence& 3

Page 5: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 5/47

INT1O(4CTION OF P1O5ECT

. GAS AGENC S STE7

Toll ta is collecte to reco%er t)e total capital o#tlay &)ic) incl# es t)e cost of

constr#ction5 repairs5 maintenance5 e penses on toll operation an interest on t)e

o#tlay. T)e ne& facility t)#s constr#cte s)o#l pro%i e re #ce tra%el time an

increase le%el of ser%ice. *n *n ia most of t)e )ig)&ay projects are gi%en on PPP

"asis5 i.e. P#"lic Pri%ate Partners)ip. *n t)is t)e pri%ate organization finances an

constr#cts t)e facility an reco%ers t)e capital from t)e #sers in t)e form of toll ta .

T)is ta is collecte for a reasona"le perio of time after &)ic) t)e facility iss#rren ere to t)e p#"lic. 6f late5 toll ta is "eing le%ie on par'ing of %e)icles in t)e

#r"an centres7 in a mo%e to econgest t)e streets an re #ce t)e poll#tion le%els. T)is

concept is 'no&n as ongestion Pricing.

Toll Plaza System 8TPS9 is a &e":"ase portal t)ro#g) &)ic) ,ational Hig)&ay #sers

may easily access information relate to toll fee an ot)er etails %iz. c#rrent toll

c)arges; an concessions< isco#nts a%aila"le for local %e)icles at %ario#s toll plaza8s9

in t)e o#ntry; commercial operation ate; ate of toll fee notification; effecti%e an#e ate of toll rate re%ision; name an contact etails of 'ey personnel on toll plaza;

etails of nearest police station; )ospitals etc. in a ition to facilities a%aila"le near

toll plaza8s9. T)e portal is G*S "ase &)erein toll plazas may "e easily searc)e on a

map. Toll plaza8s9 can also "e searc)e "et&een any t&o stations &it) s)ortest pat) on

map an applica"le toll fee at %ario#s toll plazas along t)e ro#te can "e ascertaine .

opy of Gazette ,otification for Toll Fee is a%aila"le for o&nloa ing. Toll ates can

also "e accesse t)ro#g) mo"ile p)ones "y sen ing S0S to +-=>= &it) pre efinete t messages. TPS can "e opene t)ro#g) internet on any "ro&ser t)ro#g) t)e ?

&&&.n)tis.org. T)is man#al is prepare for t)e p#"lic<roa #sers. T)is 0an#al

e plains in etail )o& to access %ario#s information relate to t)e toll plazas.

A facility is a%aila"le to ascertain t)e Toll Plaza ocations as &ell as t)e amo#nt of

fee t)at a #ser s)all )a%e to pay &)ile tra%elling t)ro#g) a selecte stretc) of ,ational

Hig)&ay. To prece e a #ser )as to clic' on @Toll Plaza "et&een t&o stations .

.+ T PE OF TOLL PLA8A S STE7

Page 6: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 6/47

T)ere are t&o types of toll collection systems a%aila"le. T)ese areB 8i9 6pen Toll

System5 an 8ii9 lose Toll System.

OPEN TOLL S STE7

*n an open toll system5 not all patrons are c)arge a toll. *n s#c) a system5 t)e toll

plaza is generally locate at t)e e ge of t)e #r"an area5 &)ere a majority of long

istance tra%ellers are committe to t)e facility5 &it) a minim#m li'eli)oo of

s&itc)ing to t)e parallel free ro#te5 or at t)e "#siest section of t)e toll &ay C2D. Patrons

are i entifie "y t)eir category an pay a fi e toll for it. T)e local traffic aro#n t)e

plaza eit)er gets re"ate or can #se a ser%ice lane. T)e general layo#t of an open toll

collecting system is )ig)lig)te in Fig. ) .

Fi)ure . 6pen Toll System

C*(+& !(** +-+!&

*n a close toll system5 patrons pay t)e toll "ase on miles of tra%el on t)e facility an

category of %e)icle. T)ere are no free:ri es. *n a close toll system5 plazas are locate

at all t)e entry an e it points5 &it) t)e patron recei%ing a tic'et #pon entering t)e

system. ?pon e iting5 patron s#rren ers t)e tic'et to t)e collector an is c)arge a

prescri"e fee "ase on category of %e)icle an istance tra%elle C2D. *t )as j#st t&o

stops for t)e %e)icles &)ereas open system can )a%e m#ltiple stops. /#t close

system is e pensi%e to constr#ct t)an open system. T)e general layo#t of an open toll

collecting system is )ig)lig)te in Fig#re.

0an#al toll collection is most &i ely #se collection met)o in *n ia. *t re #ires a

toll collector or atten ant. /ase on t)e %e)icle classification5 cas) toll is recei%e "y

t)e collector. T)e collector5 &)o also ispenses c)ange5 may accept an sell scrip5

tic'ets5 co#pons5 ma'ing an entry of t)e %e)icle in t)e system an iss#ing receipt to

t)e patron C2D. !#e to man#al inter%ention5 t)e processing time is )ig)est.

Page 7: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 7/47

Fi)ure .+ lose Toll System

.0 P1O5ECT SCOPE

Here &e are going to see some points regar ing to p#rpose "e)in c)oosing t)is topic

&)at is t)e re #irement of t)is type of t)e project in o#r ay to ay life.

A%oi t)e f#el loss.Sa%ing of time in collecting toll.A%oi financial loss.To monitor t)e traffic.

So5 accor ing to ser%e of 0a)aras)tra Go%ernment carrie o#t in Sept.2=1=5t)ey

)a%e propose to get t)e ann#al toll collection of 1+== corers<year ./#t in t)e present

sit#ation only 12== corers of t)e toll %al#e is collecte . 0eans t)ere is loss of 3==

cores #e to some )#man errors. So5 &e )a%e to control t)is lea'age. ,o& t)e present

system &e )a%e &it) #s on t)e )ig) &ays ta'es 1 min#te to complete t)e toll

collection process for one %e)icle. (it) t)is a#tomatic process5 it &ill ta'e j#st 4= to

42 sec. to complete t)e &)ole process. As t)ere is re #ction in time for completion of

t)e process so in irectly t)ere &ill "e no traffic as s#c) as t)ere is no traffic so no

f#el &astage ta'es place t)e p#rpose of esigning t)e )ig)&ays is ac)ie%e i.e.

re #ction in jo#rney time also t)e money loss &ill "e re #ce .

A Toll Ser%ices ons#ltant 8TS 9 for t)e 0aine T#rnpi'e A#t)ority 8A#t)ority9 s)all

pro%i e #alifie tec)nical an professional personnel to perform t)e #ties an

responsi"ilities assigne #n er t)e terms of t)is ontract. ,o& a ays t)ere is a )#ge

r#s) in t)e toll plazas in or er to pay t)e toll ta . T)erefore in or er to re #ce t)e

traffic jam an to sa%e time also to re #ce t)e money loss of 3== cores < year. &e

)a%e esigne project for t)e a#tomation in toll ta payment. T)is translates to

re #ce Traffic congestion at toll plazas an )elps in lo&er f#el cons#mption. T)is is

%ery important a %antage of t)is system.

Page 8: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 8/47

. TE17INOLOG

Some of t)e "asic terms t)at &ill "e #se in t)e c)apters to come )a%e "een isc#sse

in t)is section. Follo&ing are t)e terms an t)eir efinitionsB

T:1O4G:P4T - *t is t)e n#m"er of %e)icles passing t)ro#g) t)e toll plaza o%er a

s)ort perio of time5 #s#ally 1 )o#r .

(E7AN( - *t is t)e s#m of t)ro#g)p#t an t)e n#m"er of %e)icles #e#e #p at t)etoll plaza #ring 1 )o#r.P1OCESSING TI7E - *t is t)e ifference "et&een t)e time a %e)icle lea%es an

t)e time &)en it enters t)e toll area. T)e entry time is ta'en from t)e moment a

%e)icle stops in t)e #e#e.;4E4ING A1EA - *t is t)e area of t)e toll plaza &)ere t)e n#m"er of lanes of

incoming %e)icles increase from t)e n#m"er of lanes on )ig)&ay to t)e n#m"er of

toll"oot)s. T)e %e)icles #e#e #p in t)is area to ma'e t)e toll payment. Fig. / s)o&s

t)e location of #e#ing area in a toll plaza.7E1GING A1EA - *t is t)e area of t)e toll plaza &)ere t)e n#m"er of lanes of

o#tgoing %e)icles ecreases from t)e n#m"er of toll"oot)s to t)e n#m"er of lanes on

)ig)&ay. T)e %e)icles )a%e to merge &it) ot)er %e)icles in t)is area "efore t)e

)ig)&ay comes to its normal &i t). Fig#re s)o&s t)e location of merging area in atoll plaza.OPTI7AL TOLL PLA8A CONFIG41ATION - *t is t)e one &)ic) minimizes t)e

e pecte time a ri%er m#st spen &)ile tra%elling t)ro#g) t)e system.

STATE7ENT ABO4T

T:E P1OBLE7 OF E<ISTING S STE7

T)ere are fe& pro"lems &it) Toll Plaza system are s)o&n "ello&.

Page 9: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 9/47

Page 10: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 10/47

6pen:roa tolling is a smart tec)nology t)at offers con%enience an co#l )elp

lo&er prices for ta es an tolls. *n an open:roa tolling system5 t)e toll operator collects tolls on toll roa s &it)o#t

#sing "oot)s. *nstea 5 ri%ers e #ip t)eir cars &it) transpon ers 'eye to a cre it

car . ?sers simply ri%e t)ro#g) a toll plaza at )ig)&ay spee s an are c)arge

electronically &it)o#t )a%ing to slo& o&n. 6pen:roa systems also can #se

license:plate recognition tec)nology to "ill t)ose &)o on t )a%e transpon ers.

#rrently5 2 states in t)e ?.S. #tilize open:roa an electronic tolling:collection

systems5 "#t none )a%e e pan e t)eir programs t)ro#g)o#t t)eir metropolitan

areas. Here are some "enefits of electronic toll:collection in metropolitan areas an a

loo' at &)y toll "oot)s &ill easily "ecome o"solete &it)in t)e ne t eca e.

*f t)e time ta'en "y t)e %e)icles in t)e toll plaza &ere as s)ort as possi"le5 t)e toll

plaza &o#l o"tain a larger traffic capacity. To impro%e t)e traffic capacity5 T)e

relations)ips among t)e amo#nt of t)e time ta'en "y %e)icles entering t)e system5

ser%ice time5 t)e n#m"er of toll"oot)s an t)e eparting time of t)e %e)icles m#st "e

consi ere sim#ltaneo#sly. *f t)e n#m"er of t)e toll"oot)s increases or t)e ser%ing

time ecreases5 t)e a%erage &aiting time ecreases an t)e eparting time increases.

TOLL PLA8A (ESIGN AN( SPECIFICATION

T)e oncessionaire s)all pro%i e re #ire n#m"er of Toll Plazas for collection of toll

as per t)e oncession Agreement. T)e fee collection system s)all "e spee y5 efficient

Page 11: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 11/47

an #ser frien ly. T)e esign of t)e Toll Plazas s)o#l "e s#c) t)at t)ey are

aest)etically pleasing an efficient an t)e fee collection staff s)o#l "e #ic'5

co#rteo#s an a e #ately traine "efore eployment.

GENE1AL LA O4T - T)e general toll plaza geometry of a 2I2 lane toll plaza.*nitially5 t)e n#m"ers of lanes "ecome e #al to t)e n#m"er of toll"oot)s5 &)ic) is

e #al to t)ree in t)e #e#ing area. After t)e %e)icle crosses t)e toll"oot)5 t)e n#m"er

of lanes merges "ac' to t)e original &i t) of t)e )ig)&ay5 i.e. t&o:lane. A lane for t)e

e tra &i e an t)e e empte %e)icles is pro%i e at t)e left )an si e of t)e )ig)&ay.

Some e tra space is also maintaine for t)e scope of f#t#re plaza e pansion. T)e

esign specifications for t)e esign of t)e flare portions are as liste "elo&B

ane &i t) J 3.2 m in general an 4.1 m for o%ersize %e)icles.0e ian 8a9 (i t) J 1. m 8"9 engt) J += mTransition : 1 in 1= may "e pro%i e from t&o:lane section to t)e &i ene &i t)

at Toll Plaza on eit)er si e.

N47BE1 OF TOLL LANES - As isc#sse pre%io#sly5 toll"oot)s are erecte to

collect t)e ta from t)e roa #sers. T)e n#m"er of toll"oot)s epen s on t)e flo& of

%e)icles on t)e facility. Follo&ing g#i elines are generally follo&e &)ile eci ing

t)e n#m"er of toll lanes in a toll plazaB

Pea' Ho#r FactorB Percentage of %e)icles tra%elling #ring t)e pea' )o#r to t)e

a%erage aily traffic. ,#m"er of toll lanes s)o#l "e correspon ing to t)e forecast traffic for at least +

years.Forecast traffic in terms of %e)icle< ay for all t)e toll a"le categories. ,on:toll

a"le %e)icles 8e.g. *P %e)icles5 am"#lances5 etc9 are e empte from t)e toll ta

an flo& t)ro#g) a separate lane.

*f t)e #e#e "ecomes so long t)at t)e &aiting time e cee s t)ree min#tes t)en t)en#m"er of toll"oot)s nee to "e increase .

Page 12: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 12/47

Page 13: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 13/47

$a%a )istory is interesting to 'no&. T)e )istory of ja%a starts from Green Team. $a%a

team mem"ers 8also 'no&n as Green Team95 initiate a re%ol#tionary tas' to e%elop

a lang#age for igital e%ices s#c) as set:top "o es5 tele%isions etc.

For t)e green team mem"ers5 it &as an a %ance concept at t)at time. /#t5 it &as s#itefor internet programming. ater5 $a%a tec)nology as incorporate "y ,etscape.

#rrently5 $a%a is #se in internet programming5 mo"ile e%ices5 games5 e:"#siness

sol#tions etc. T)ere are gi%en t)e major points t)at escri"es t)e )istory of ja%a.

$ames Gosling5 0i'e S)eri an5 an Patric' ,a#g)t on initiate t)e $a%a lang#age

project in $#ne 1KK1. T)e small team of s#n engineers calle Green Team.

6riginally esigne for small5 em"e e systems in electronic appliances li'e set:

top "o es.

Firstly5 it &as calle LGreental'L "y $ames Gosling an file e tension.

After t)at5 it &as calle 6a' an &as e%elope as a part of t)e Green project.

.,: OA= NA7E FO1 5A>A LANG4AGE

6a' is a sym"ol of strengt) an c)osen as a national tree of many co#ntries li'e

?.S.A.5 France5 Germany5 omania etc. *n 1KK+5 6a' &as rename as L$a%aL "eca#se

it &as alrea y a tra emar' "y 6a' Tec)nologies.

,: 5A>A NA7E FO1 5A>A LANG4AGE

()y t)ey c)ooses ja%a name for ja%a lang#ageM T)e team gat)ere to c)oose a ne&

name. T)e s#ggeste &or s &ere L ynamicL5 Lre%ol#tionaryL5 LSil'L5 LjoltL5 L!,AL

etc. T)ey &ante somet)ing t)at reflecte t)e essence of t)e tec)nologyB

re%ol#tionary5 ynamic5 li%ely5 cool5 #ni #e5 an easy to spell an f#n to say.

Accor ing to $ames Gosling L$a%a &as one of t)e top c)oices along &it) Sil'L. Since

ja%a &as so #ni #e5 most of t)e team mem"ers preferre ja%a.

$a%a is an islan of *n onesia &)ere first coffee &as pro #ce 8calle ja%a coffee9.

,otice t)at $a%a is j#st a name not an acronym. 6riginally e%elope "y $ames

Page 14: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 14/47

Page 15: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 15/47

Front en part is more important. * )a%e c)osen ,otepa as a front en . /eca#se it

gi%es goo an more &or'space for esigning Project an it is more sec#re t)an

ot)ers. T)e res#lting filesOtypically sa%e &it) t)e t t e tensionO)a%e no format

tags or styles5 ma'ing t)e program s#ita"le for e iting system files to #se in

a !6S en%ironment an 5 occasionally5 so#rce co e for later compilation or e ec#tion5

#s#ally t)ro#g) a comman prompt. *t is also #sef#l for its negligi"le #se of system

reso#rces; ma'ing for #ic' loa time an processing time5 especially on #n er:

po&ere )ar &are. ,otepa s#pports "ot) left:to:rig)t an rig)t:to:left "ase

lang#ages. ?nli'e ,otepa offers only t)e most "asic te t manip#lation f#nctions5

s#c) as fin ing te t. 6nly ne&er %ersions of (in o&s incl# e an #p ate %ersion of

,otepa &it) a searc) an replace f#nction. Ho&e%er5 it )as m#c) less f#nctionality

in comparison to f#ll:scale e itors.

+.+. ABO4T 5A>A

$a%a is a set of se%eral comp#ter soft&are an specifications e%elope "y S#n

0icrosystems5 later ac #ire "y 6racle orporation5 t)at pro%i es a system for

e%eloping application soft&are an eploying it in a cross:platform comp#ting

en%ironment. $a%a is #se in a &i e %ariety of comp#ting platforms from em"e ee%ices an mo"ile p)ones to enterprise ser%ers an s#percomp#ters. ()ile less

common5 $a%a applets r#n in sec#re5 san "o e en%ironments to pro%i e many

feat#res of nati%e applications an can "e em"e e in HT0 pages.

(riting in t)e $a%a programming lang#age is t)e primary &ay to pro #ce co e t)at

&ill "e eploye as "yte co e in a $a%a irt#al 0ac)ine 8$ 09; "yte

co e compilers are also a%aila"le feat)er lang#ages5 incl# ing $a%aScript5 Pyt)on5

an #"y. *n a ition5 se%eral lang#ages )a%e "een esigne to r#n nati%ely on t)e

$ 05 incl# ing Scale5 onj#re an Groo%y. $a%a synta "orro&s )ea%ily

from an II5 "#t o"ject:oriente feat#res are mo elle t)ere are also a%aila"le in

after Smalltal' an 6"jecti%e: . $a%a esc)e&s certain lo&:le%el constr#cts s#c)

as pointers an )as a %ery simple memory mo el &)ere e%ery o"ject is allocate on

t)e )eap an all %aria"les of o"ject types are references. 0emory management is

)an le t)ro#g) integrate a#tomatic gar"age collection performe "y t)e $ 0. 6n

,o%em"er 135 2==-5 S#n 0icrosystems ma e t)e "#l' of its implementation of

Page 16: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 16/47

$a%a is #se in a &i e %ariety of comp#ting platforms from em"e e

e%ices an mo"ile p)ones to enterprise ser%ers an s#percomp#ters. ()ile less

common5 $a%a applets r#n in sec#re5 san "o e en%ironments.

Fi) +.+ 5a#a Lo)o

5A>A >I1T4AL PLATFO17

T)e )eart of t)e $a%a platform is t)e concept of a L%irt#al mac)ineL t)at e ec#tes $a%a

"yte co e programs. T)is "yte co e is t)e same no matter &)at )ar &are or operating

system t)e program is r#nning #n er. T)ere is a $*T 8$#st *n Time9 compiler &it)in

t)e $a%a irt#al 0ac)ine5 or $ 0. T)e $*T compiler translates t)e $a%a "yte co e into

nati%e processor instr#ctions at r#n:time an cac)es t)e nati%e co e in memory #ring

e ec#tion.

T)e #se of "yte co e as an interme iate lang#age permits $a%a programs to r#n on any

platform t)at )as a %irt#al mac)ine a%aila"le. T)e #se of a $*T compiler means t)at

$a%a applications5 after a s)ort elay #ring loa ing an once t)ey )a%e L&arme #pL "y "eing all or mostly $*T:compile 5 ten to r#n a"o#t as fast as nati%e programs.

Since $ E %ersion 1.25 S#n s $ 0 implementation )as incl# e a j#st:in:time

compiler instea of an interpreter.

Alt)o#g) $a%a programs are cross:platform or platform in epen ent5 t)e co e of t)e

$a%a irt#al 0ac)ines 8$ 09 t)at e ec#te t)ese programs is not. E%ery s#pporte

operating platform )as its o&n $ 0.

Page 17: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 17/47

+.+.+ :O, (OES IT ,O1=

Ha%e yo# e%er &on ere )o& comp#ter programs &or'M Ha%e yo# e%er &ante to

learn )o& to &rite yo#r o&n comp#ter programsM ()et)er yo# are 14 years ol an

)oping to learn )o& to &rite yo#r first game5 or yo# are >= years ol an )a%e "een

c#rio#s a"o#t comp#ter programming for 2= years5 t)is article is for yo#. *n t)is

e ition of Ho& St#ff (or's5 * m going to teac) yo# )o& comp#ter programs &or' "y

teac)ing yo# )o& to program in t)e $a%a programming lang#age. A lo&:

le%el programming lang#age is somet)ing closer to &)at ma'es sense to a comp#ter.

!etails for lo&:le%el lang#ages are #nimportant in t)e intro S co#rses.

*n or er to teac) yo# a"o#t comp#ter programming5 * am going to ma'e se%eral

ass#mptions from t)e startB

* am going to ass#me t)at yo# 'no& not)ing a"o#t comp#ter programming no&. *f

yo# alrea y 'no& somet)ing t)en t)e first part of t)is article &ill seem elementary

to yo#. Please feel free to s'ip for&ar #ntil yo# get to somet)ing yo# on t 'no&.

Ha%ing sai t)ese t)ings5 &e are rea y to go. et s get starte* am going to ass#me yo# do 'no& somet)ing a"o#t t)e comp#ter yo# are #sing.

T)at is5 * am going to ass#me yo# alrea y 'no& )o& to e it a file5 copy an elete

files5 rename files5 fin information on yo#r system5 etc.For simplicity5 * am going to ass#me t)at yo# are #sing a mac)ine r#nning

(in o&s K+5 K 5 2===5 ,T or QP. *t s)o#l "e relati%ely straig)tfor&ar for

people r#nning ot)er operating systems to map t)e concepts o%er to t)ose.* am going to ass#me t)at yo# )a%e a esire to learn.

All of t)e tools yo# nee to start programming in $a%a are &i ely a%aila"le on t)e

(e" for free. T)ere is also a )#ge amo#nt of e #cational material for $a%a a%aila"le

on t)e (e"5 so once yo# finis) t)is article yo# can easily go learn more to a %anceyo#r s'ills. Ro# can learn $a%a programming )ere &it)o#t spen ing any money on

compilers5 e%elopment en%ironments5 rea ing materials5 etc. 6nce yo# learn $a%a it

is easy to learn ot)er lang#ages5 so t)is is a goo place to start.

+.+.0 ,: 5A>A

Simple grammar : $a%a )as a %ery simple grammar familiar to anyone &it) e perience

in an II5 &)ic) m#st "e KK.K of programmers. The BNF for Java has about 50

rules; that for C++, about 140. And C++ also has tem lates and a re! ro"essor #n

Page 18: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 18/47

add#t#on to the $rammar. 5a#a "u&t )ot ?uite a bit more com*le@ in .2 e@cu&e me

5a#a 2 . TDe% Da#en t e#en relea&ed a ne #er&ion o$ tDe lan)ua)e &*ec %et.

Porta"ility : T)ese ays $a%a really oes r#n &ell on all t)e pop#lar platforms

8 in# &as a little "e)in 5 #ntil S#n realize t)ey nee e t)em... no& it s j#st Free/S!5 6pen/s 5 an ,et/s lagging9 8Too "a t)at #"y5 Pyt)on5 Perl5

S #ea' on t &or' &ell on most platforms... 6) &ait5 t)ey o 9Spee : T)e latest $*T compilers for S#ns $ 0 approac) t)e spee of < II

co e5 an in some memory allocation intensi%e circ#mstances5 e cee it. 8Too "a

#"y5 Pyt)on5 Perl5 an S #ea' on t e%en come close9Stan ar AP*s : Ro# can )appily &rite yo#r co e 'no&ing t)at t)e stan ar ja%a.

li"raries &ill "e &aiting on t)e client for it5 ass#ming a recent eno#g) %ersion of

$a%a is installeGar"age ollection: t)e programmer oesn t )a%e to &orry a"o#t memory 8most

of t)e time90 : see ()y Are irt#al 0ac)ines Great.)ec'e E ception8some people )ate t)is5 "#t its optional9 8some ppl lo%e it9

single class in)eritancesingly roote class )ierarc)y 8t)e reason t)at lac' of templates isn t a 'iller9no 6perator 6%erloa ingreflection

*n)erent s#pport for ynamic lin'ing an loa ing.G#arantees of "inary compati"ility &.r.t. c)anges to lin'e co e.fast e it<compile<r#n cycle faster than %hat&

* can only attest t)at t)is ma'es Eclipse egrees. *t is &on erf#l to "e a"le to ma'e

small c)anges to a class an )a%e t)e recompile class lin'e into t)e r#nning

application for imme iate testing. * on t 'no& &)et)er t)is is possi"le in ot)er $a%a

en%ironments.

+.+. INTE1FACE

An interface is a reference type in $a%a5 it is similar to class5 it is a collection of

a"stract met)o s. A class implements an interface5 t)ere"y in)eriting t)e a"stract

met)o s of t)e interface.

Along &it) a"stract met)o s an interface may also contain constants5 efa#lt

met)o s5 static met)o s5 an neste types. 0et)o "o ies e ist only for efa#lt

met)o s an static met)o s.

Page 19: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 19/47

(riting an interface is similar to &riting a class. /#t a class escri"es t)e attri"#tes

an "e)a%io#rs of an o"ject. An an interface contains "e)a%io#rs t)at a class

implements.

?nless t)e class t)at implements t)e interface is a"stract5 all t)e met)o s of t)e

interface nee to "e efine in t)e class.

An interface is similar to a class in t)e follo&ing &aysB

An interface can contain any n#m"er of met)o s.

An interface is &ritten in a file &it) a ."a#a e tension5 &it) t)e name of t)e

interface matc)ing t)e name of t)e file.

T)e "yte co e of an interface appears in a .cla&& file.

*nterfaces appear in pac'ages5 an t)eir correspon ing "yte co e file m#st "e in a

irectory str#ct#re t)at matc)es t)e pac'age name.

Ho&e%er5 an interface is ifferent from a class in se%eral &ays5 incl# ingB

Ro# cannot instantiate an interface.

An interface oes not contain any constr#ctors.

All of t)e met)o s in an interface are a"stract.

An interface cannot contain instance fiel s. T)e only fiel s t)at can appear in an

interface m#st "e eclare "ot) static an final.

An interface is not e ten e "y a class; it is implemente "y a class.

An interface can e ten m#ltiple interfaces.

Page 20: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 20/47

Fi) +.0 5a#a Inter$ace

(riting an interface is similar to &riting a class. /#t a class escri"es t)e attri"#tes

an "e)a%io#rs of an o"ject. An an interface contains "e)a%io#rs t)at a class

implements. A )ome screen may "e ma e #p of se%eral pages t)at t)e #ser can s&ipe

"ac' an fort) "et&een5 t)o#g) An roi s )ome screen interface is )ea%ilyc#stomisa"le5 allo&ing t)e #ser to a j#st t)e loo' an feel of t)e e%ice to t)eir tastes.+.+.2 ,: NOTEPA(

0icrosoft s first ,otepa %ersion pre ates (in o&s. T)ey incl# e it in a set of

#tilities t)ey "#n le &it) t)e 0icrosoft 0o#se as early as 1K 3. i'e s#"se #ent

%ersions5 it &as a plain te t e itor t)at #se t)e mo#se for men# na%igation an te t

manip#lation. Ho&e%er5 #nli'e its (in o&s s#ccessors5 it &as a !6S program

limite to f#ll:screen operation.

*n all %ersions of (in o&s5 ,otepa #ses a "#ilt:in &in o& class name '()T . 6l er

%ersions incl# e &it) (in o&s K+5 (in o&s K 5 (in o&s 0e an (in o&s 3.15

impose a -4 N limit on file size5 &)ic) &as an operating system limit of t)e E!*T

class. ?p to (in o&s K+5 Fi e system &as t)e only a%aila"le isplay font for

,otepa . &in o&s ,T 4.= an K intro #ce t)e a"ility to c)ange t)is font. As

of (in o&s 2===5 t)e efa#lt font &as c)ange to #ci a onsole. T)e font setting5)o&e%er5 only affects )o& t)e te t is s)o&n to t)e #ser an )o& it is printe 5 not )o&

t)e file is sa%e to is'. T)e efa#lt font &as c)ange to onsolas on (in o&s .

?p to (in o&s 0e5 t)ere &ere almost no 'ey"oar s)ortc#ts an no line:co#nting

feat#re. Starting &it) (in o&s 2===5 s)ortc#ts for common tas's li'e ne&5 open an

sa%e &ere a e 5 as &ell as a stat#s:"ar &it) a line co#nter 8a%aila"le only &)en

&or :&rap is isa"le 9. ,otepa also )as a simple "#ilt:in logging f#nction. Eac)

time a file t)at starts &it) .LOG is opene 5 t)e program inserts a te t timestamp on t)e

Page 21: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 21/47

last line of t)e file .,otepa accepts te t from t)e (in o&s clip"oar . ()en

clip"oar ata &it) m#ltiple formats is paste into ,otepa 5 t)e program only accepts

te t in t)e CF_TEXT format. T)is is #sef#l for stripping em"e e font type an style

co es from formatte te t5 s#c) as &)en copying te t from a &e" page an pasting

into an email message or ot)er (RS*(RG te t e itor. Formatte te t can "e

temporarily paste into ,otepa 5 an t)en imme iately copie again in strippe

format to paste into t)e ot)er program. ,otepa accepts te t from t)e

(in o&s clip"oar . ()en clip"oar ata &it) m#ltiple formats is paste into

,otepa 5 t)e program only accepts te t in t)e CF_TEXT format. T)is is #sef#l for

stripping em"e e font type an style co es from formatte te t.

Fi) +. Note*ad

,otepa can print files5 "#t oesn t print correctly if (or (rap is t#rne on.

Hea ers5 footers5 an margins can "e set an a j#ste &)en preparing to print a file

#n er Page Set#p. T)e ate5 file name5 an ot)er information can "e place in t)e

)ea ers an footers &it) %ario#s co es consisting of an ampersan 8 9 follo&e "y a

letter. T)is is #sef#l for stripping em"e e font type an style co es from formatte

te t5 s#c) as &)en copying te t from a &e" page an pasting into an email message or

ot)er (RS*(RG te t e itor. Formatte te t can "e temporarily paste into ,otepa 5

an t)en imme iately copie again in strippe format to paste into t)e ot)er program.

T)e ate5 file name5 an ot)er information can "e place in t)e )ea ers an footers

&it) %ario#s co es.

Page 22: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 22/47

+.+.6 LANG4AGES 4SE( ON NOTEPA(

T)e follo&ing are lin's to ol er Sim#ltaneo#s elease ang#ages istri"#te "y t)e

,otepa Fo#n ation :-

0da 5asp 5 0ssembly 50utoIt

1atch

C5 C 5C3 5 Caml 5Cmake 5 C(1(* 5 Co ee+cript 5C++

5 i

Flash 0ction+cript 5Fortran

G#i4 *

5askell 5 5! *

I66(

7ava 5 7avascript 5 7+8

9i:tart

*I+8 5*ua

ake$le 5 atlab 5 +; (+ 5 I6I $le

6+I+ 56ormal !e<t File

(bjective;C

8ascal 5 8erl 5858 5 8ost+cript 5 8ower+hell 5 Properties5 8ython

= 5 eso#rce file5 =uby

+hell 5 +cheme 5 +malltalk 5 +>*

!C* 5 !e:

?isual 1asic 5 ?5 * 5 ?erilog

: *

-0 *

Page 23: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 23/47

+.0 BAC= EN( (ETAILS

/ac' en part of a system is more important "eca#se it controls all t)e internal

process of a system. * )a%e c)osen 0icrosoft Access as a "ac' en .

+.0. 7IC1OSOFT ACCESS

0icrosoft Access is a !/0S 8also 'no&n as !ata"ase 0anagement System9 from

0icrosoft t)at com"ines t)e relational 0icrosoft $et !ata"ase Engine &it) a

grap)ical #ser interface an soft&are: e%elopment tools. *t is a mem"er of t)e

0icrosoft 6ffice s#ite of applications5 incl# e in t)e Professional an )ig)er

e itions or sol separately. 0icrosoft Access stores ata in its o&n format "aseon t)e Access $et !ata"ase Engine. *t can also import or lin' irectly to ata

store in ot)er applications an ata"ases.

Soft&are e%elopers an ata arc)itects can #se 0icrosoft Access to e%elop

application soft&are5 an Lpo&er #sersL can #se it to "#il soft&are applications.

i'e ot)er 6ffice applications5 Access is s#pporte "y is#al /asic for

Applications 8 /A95 an o"ject:oriente programming lang#age t)at can reference

a %ariety of o"jects incl# ing !A6 8!ata Access 6"jects95 Acti%eQ !ata 6"jects5

an many ot)er Acti%eQ components. is#al o"jects #se in forms an reports

e pose t)eir met)o s an properties in t)e /A programming en%ironment5 an

/A co e mo #les may eclare an call (in o&s operating:system f#nctions.

Page 24: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 24/47

Page 25: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 25/47

$a%a is Easy to &rite an more rea a"le an eye catc)ing.$a%a )as a concise5 co)esi%e set of feat#res t)at ma'es it easy to learn an #se.0ost of t)e concepts are re& from II t)#s ma'ing $a%a learning simpler.$a%a program cannot )arm ot)er system t)#s ma'ing it sec#re.$a%a pro%i es a sec#re means of creating *nternet applications.$a%a pro%i es sec#re &ay to access &e" applications.

+.2 A(>ANTAGE OF 5A>A

$a%a is easy to learn. $a%a &as esigne to "e easy to #se an is t)erefore easy to

&rite5 compile5 e"#g5 an learn t)an ot)er programming lang#ages. $a%a is

o"ject:oriente . T)is allo&s yo# to create mo #lar programs an re#sa"le co e.$a%a is platform:in epen ent. 6ne of t)e most significant a %antages of $a%a is its

a"ility to mo%e easily from one comp#ter system to anot)er. T)e a"ility to r#n t)e

same program on many ifferent systems is cr#cial to (orl (i e (e" soft&are5

an $a%a s#ccee s at t)is "y "eing platform:in epen ent at "ot) t)e so#rce an

"inary le%els.$a%a is istri"#te . $a%a is esigne to ma'e istri"#te comp#ting easy &it) t)e

net&or'ing capa"ility t)at is in)erently integrate into it. (riting net&or'

programs in $a%a is li'e sen ing an recei%ing ata to an from a file.$a%a is sec#re. $a%a consi ers sec#rity as part of its esign. T)e $a%a lang#age5

compiler5 interpreter5 an r#ntime en%ironment &ere eac) e%elope &it) sec#rity

in min .$a%a is ro"#st. o"#st means relia"ility. $a%a p#ts a lot of emp)asis on early

c)ec'ing for possi"le errors5 as $a%a compilers are a"le to etect many pro"lems

t)at &o#l first s)o& #p #ring e ec#tion time in ot)er lang#ages.$a%a is m#ltit)rea e . 0#ltit)rea e is t)e capa"ility for a program to perform

se%eral tas's sim#ltaneo#sly &it)in a program. *n $a%a5 m#ltit)rea e

programming )as "een smoot)ly integrate into it5 &)ile in ot)er lang#ages5

operating system:specific proce #res )a%e to "e calle in or er to ena"le

m#ltit)rea ing./eca#se of $a%a s ro"#stness5 ease of #se5 cross:platform capa"ilities an sec#rity

feat#res5 it )as "ecome a lang#age of c)oice for pro%i ing &orl &i e *nternet

sol#tions.+.6 FEAT41ES AN( SPECIFICATION

T)e majority of ne& feat#res in t)is e ition &ere specifie "y $S 3345 Small

En)ancements to t)e $a%a Programming ang#age5 le "y $oe !arcy &it) an E pert

Page 26: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 26/47

Gro#p of $os)#a /loc)5 /r#ce )apman5 Ale'sey N# ra%tse%5 0ar' 0at)ie#5 Tim

Peierls5 an 6li%ier Tomean. T)e origins of t)ese feat#res lie in Project oin5 an 6pen

$!N project starte in 2==K &it) t)e goal of L0a'ing t)ings programmers o e%ery

ay easierL. T)e project solicite proposals from t)e $a%a comm#nity for "roa ly

#sef#l lang#age feat#res t)at &ere5 in comparison &it) LlargeL feat#res li'e generics5

relati%ely LsmallL in t)eir specification5 implementation5 an testing. T)o#san s of

emails an si ozen proposals later5 proposals &ere accepte from $os)#a /loc) 8t)e

try:&it):reso#rces statement95 !ere' Foster</r#ce )apman.

Page 27: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 27/47

S STE7 (ESIGN

0. 7ET:O( TO (ESIGN

T)e "asic en%ironment re #ire to start t)e project is t)e $a%a !e%elopment Nit t)at is

"eing #se for r#nning t)e application on $a%a platform. After getting familiar &it)

t)at5 t)e ne t process is &)at 'in of lang#age &e are &or'ing #pon to eal &it) t)e

"asic core $a%a5 t)e %ario#s controls controlle "y t)e $!N i.e. t)e $a%a !e%elopment

Nit.

After t)at yo# start &it) yo#r application5 first of all5 t)e layo#ts of yo#r application

are esigne &)ic) "asically eals &it) t)e type of Grap)ical ?ser *nterface yo# aregoing to pro%i e to ma'e it loo' simple an attracti%e for t)e #ser &)o is #sing yo#r

application.

()en t)e &)ole o ing an t)e layo#t is complete 5 t)e e%eloper &)o is

e%eloping t)e project5 r#ns it on any operating system so as to 'no& )o& t)e

e%elope ja%a project r#ns. To ma'e t)is project notepa is #se &)ere t)e ja%a co e

is &ritten an to compile t)is comman prompt is #se .

,o& t)e "asic core lang#age i.e. $a%a5 is #se to ma'e t)ose layo#ts &or' properly

an to s)ift from one class to t)e ot)er an setting #p all t)e 'ey actions performe "y

t)e #ser &)ile #sing t)e application or &)en t)e project is in t)e r#nning state.

T)is fiel )ol s t)e "asic co ing lang#age &ritten "y t)e #ser to ma'e t)e project r#n

properly. ()en t)e &)ole o ing an t)e layo#t is complete 5 t)e e%eloper &)o is

e%eloping t)e project5 r#ns it on $ ! 8$a%a irt#al !e%ice9 so as to 'no& )o& t)e

e%elope project r#ns. To ma'e t)is project * firstly prepare t)e layo#ts for t)e

screens on t)e notepa files an t)en * p#t t)e co e in t)e $A A file an after t)at *

compile it on comman prompt. 6nce t)e e%eloper is satisfie 5 t)e project can "e

poste on t)e play store so t)at %ario#s #sers can #se it.

/y #sing t)is met)o &e can manage t)e ata"ase for Toll Plaza. Here ifferent type

of t)e met)o an t)e flo&c)art are present to s)o& it &or'ing.

et #s consi er t)e &ay of trac'ing5 firstly &e start from t)e c)oice &)ic) is gi%en in

t)ree options.

A min ogin

Page 28: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 28/47

?ser ogin

Fi) 0. Toll Pla'a $lo cDart

A(7IN LOGIN - Firstly &e logge in &it) a min page5 if t)e con ition is tr#e5 t)en

&e get all t)e etails5 ot)er&ise if t)e con ition is false t)en &e get registere .

4SE1 LOGIN : Firstly &e logge in &it) #ser page5 if t)e con ition is tr#e5 t)en &e

get all t)e etails5 ot)er&ise if t)e con ition is false t)en &e get registere .

T)ro#g) t)is project &e manage t)e toll plaza system.

0.+ 5A>A F1A7E,O1=

T)ere are plenty of $a%a frame&or's a%aila"le on t)e &e"5 an e%elopers #se t)em

#ite fre #ently to "#il &e"sites. T)ese frame&or's offer lots of f#nctions an

re #ce t)e &or'ing )o#rs "y leaps an "o#n s. T)ese frame&or's ma'e t)e co ing

process faster5 t)an's to t)eir in"#ilt mo #les an f#nctions.

Sometimes too many options can conf#se yo# an t)at is e actly t)e case &it) $a%a

frame&or's. *f yo# as' for s#ggestions in &e" e%elopment an programming

for#ms5 e%ery e%eloper &ill gi%e yo# ifferent s#ggestions "ase on )is personal

li'es an isli'es. As a res#lt5 it "ecomes %ery iffic#lt to select t)e one frame&or'

t)at &ill fit all yo#r re #irements.

Page 29: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 29/47

Page 30: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 30/47

main feat#res of yo#r project. 6ne of t)e #ni #e a %antages of spring is t)at it lets

yo# connect %ario#s components an as a res#lt5 yo# can create a sol#tion for

intricate pro"lems. Some of t)e ot)er feat#res it offers are clo# s#pport5 s#pport

to tra itional ata"ase r "ms as &ell as ne& no s l5 "etter sec#rity an

compati"ility to mo"ile..5A>A 14NTI7E - T)e an roi r#ntime consists of t)e ! 0. *t is "asically a

%irt#al mac)ine for em"e e e%ices; &)ile li'e any ot)er %irt#al mac)ine is a

"yte co e interpreter.

&e say it is for em"e e e%ices5 it means it is lo& on memory5 comparati%ely

slo&er an r#ns on "attery po&er. /esi e t)e ! 05 it is also consists of t)e core

li"rary5 &)ic) are ja%a li"raries5 &)ic) are ja%a li"raries an are a%aila"le for all

e%ice.

0.0 5A>A A1C:ITECT41E

At t)e )eart of $a%a tec)nology lies t)e $a%a %irt#al mac)ine::t)e a"stract comp#ter

on &)ic) all $a%a programs r#n. Alt)o#g) t)e name L$a%aL is generally #se to refer

to t)e $a%a programming lang#age5 t)ere is more to $a%a t)an t)e lang#age. T)e $a%a

%irt#al mac)ine5 $a%a AP*5 an $a%a class file &or' toget)er &it) t)e lang#age to

ma'e $a%a programs r#n.

T)e first fo#r c)apters of t)is "oo' 8Part *. L$a%a s Arc)itect#reL9 s)o& )o& t)e $a%a

%irt#al mac)ine fits into t)e "ig pict#re. T)ey s)o& )o& t)e %irt#al mac)ine relates to

t)e ot)er components of $a%a s arc)itect#reB t)e class file5 AP*5 an lang#age. T)ey

escri"e t)e moti%ation "e)in ::an t)e implications of: :t)e o%erall esign of $a%a

tec)nology.

T)is c)apter gi%es an intro #ction to $a%a as a tec)nology. *t gi%es an o%er%ie& of

$a%a s arc)itect#re5 isc#sses &)y $a%a is important5 an loo's at $a%a s pros an cons.

6ne c)allenge presente to soft&are e%elopers "y t)e increasingly net&or': centric

)ar &are en%ironment is t)e &i e range of e%ices t)at net&or's interconnect. A

typical net&or' #s#ally )as many ifferent 'in s of attac)e e%ices5 &it) i%erse

)ar &are arc)itect#res5 operating systems5 an p#rposes. $a%a a resses t)is

c)allenge "y ena"ling t)e creation of platform:in epen ent programs. A single $a%a

program can r#n #nc)ange on a &i e range of comp#ters an e%ices. ompare

&it) programs compile for a specific )ar &are an operating system5 platform:

Page 31: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 31/47

in epen ent programs &ritten in $a%a can "e easier an c)eaper to e%elop5

a minister5 an maintain.

Anot)er c)allenge t)e net&or' presents to soft&are e%elopers is sec#rity. *n a ition

to t)eir potential for goo 5 net&or's represent an a%en#e for malicio#s programmersto steal or estroy information5 steal comp#ting reso#rces5 or simply "e a n#isance.

ir#s &riters5 for e ample5 can place t)eir &ares on t)e net&or' for #ns#specting

#sers to o&nloa . $a%a a resses t)e sec#rity c)allenge "y pro%i ing an en%ironment

in &)ic) programs o&nloa e across a net&or' can "e r#n &it) c#stomiza"le

egrees of sec#rity.

6ne aspect of sec#rity is simple program ro"#stness. i'e e%io#s co e &ritten "y

malicio#s programmers5 "#ggy co e &ritten "y &ell:meaning programmers can potentially estroy information5 monopolize comp#te cycles5 or ca#se systems to

cras). $a%a s arc)itect#re g#arantees a certain le%el of program ro"#stness "y

pre%enting certain types of pernicio#s "#gs5 s#c) as memory corr#ption5 from e%er

occ#rring in $a%a programs. T)is esta"lis)es tr#st t)at o&nloa e co e &ill not

ina %ertently 8or intentionally9 cras)5 "#t it also )as an important "enefit #nrelate to

net&or'sB it ma'es programmers more pro #cti%e. /eca#se $a%a pre%ents many types

of "#gs from e%er occ#rring5 $a%a programmers nee not spen time trying to fin anfi t)em.

6ne opport#nity create "y an omnipresent net&or' is online soft&are istri"#tion.

$a%a ta'es a %antage of t)is opport#nity "y ena"ling t)e transmission of "inary co e

in small pieces across net&or's. T)is capa"ility can ma'e $a%a programs easier an

c)eaper to eli%er t)an programs t)at are not net&or': mo"ile. *t can also simplify

%ersion control. /eca#se t)e most recent %ersion of a $a%a program can "e eli%ere

on: eman across a net&or'5 yo# nee n t &orry a"o#t &)at %ersion yo#r en :#sersare r#nning. T)ey &ill al&ays get t)e most recent %ersion eac) time t)ey #se yo#r

program.

0. (ESIGN(rite t)e co e in ja%a lang#age on notepa an compile an r#n it onto comman

prompt. T)e co e for t)e main page is s)o&n "ello&B:

0. . SO41CE CO(E FO1 T:E 7AIN PAGEimport ja%a .s&ing. ;import ja%a.a&t. ;import ja%a.a&t.e%ent. ;

Page 32: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 32/47

import ja%a.s l. ; p#"lic class mi src e ten s $Frame implements Action istener U*mage*con c15c25c35c45c+5c-5c 5cK5c1=5c11;$ a"el le"15le"25le"35le"45le" 5le"K5le"1=5le"11;

$Pass&or Fiel pas1;$/#tton "#ser5"a min5"e it;c)ar c);

p#"lic mi src89U set ayo#t8n#ll9; c1Jne& *mage*con8Lpoi#yt.jpgL9; le"1Jne& $ a"el8c19; le"1.set/o#n s8=5=514==5>3=9; c Jne& *mage*con8Ltoll1.pngL9; le" Jne& $ a"el8c 9; le" .set/o#n s81==54=5-+=51==9;

c2Jne& *mage*con8Lioo.jpgL9; le"2Jne& $ a"el8c29; le"2.set/o#n s842=52 =52==511+9; pas1Jne& $Pass&or Fiel 89; pas1.set/o#n s8432544=52+=52 9; pas1.set isi"le8false9; c3Jne& *mage*con8Lpo'.jpgL9; le"3Jne& $ a"el8c39; le"3.set/o#n s8>+=52 =52==511+9; c4Jne& *mage*con8La m.jpgL9; "a minJne& $/#tton8c49; "a min.set/o#n s84+3541=513=53=9; "a min.a Action istener8t)is9; c+Jne& *mage*con8Ls)etal.jpgL9; "#serJne& $/#tton8c+9; "#ser.set/o#n s8> 541=513=53=9; "#ser.a Action istener8t)is9; c-Jne& *mage*con8L">.jpgL9; "e itJne& $/#tton8c-9;

"e it.set/o#n s8123=5 511=52K9; "e it.a Action istener8t)is9; cKJne& *mage*con8Lcar4.pngL9; le"KJne& $ a"el8cK9; le"K.set/o#n s813=5-==511-+5KK9; a 8pas19; a 8le"39; a 8le"29; a 8le" 9; a 8"a min9; a 8"#ser9;

a 8"e it9; a 8le"K9;

Page 33: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 33/47

a 8le"19; V p#"lic %oi actionPerforme 8ActionE%ent ae9 U String sJae.getAction omman 89;

"a min.setAction omman 8LA minL9; "#ser.setAction omman 8L?serL9; "e it.setAction omman 8LE itL9; if8s.e #als8LA minL99U pas1.set isi"le8tr#e9; if8pas1.getTe t89.e #als8L1234+->L99U

ispose89;a minsrc a miJne& a minsrc89;a mi.set!efa#lt lose6peration8$Frame.!*SP6SEW6,W 6SE9;a mi.setTitle8LA min ScreenL9;a mi.setSize814==5>3=9;a mi.set isi"le8tr#e9VVelse if8s.e #als8L?serL99U

ispose89;signin inJne& signin89;T)rea t)rea Jne& T)rea 8in9;t)rea .start89;in.set!efa#lt lose6peration8$Frame.!*SP6SEW6,W 6SE9;in.setTitle8L?ser oginL9;in.setSize814==5>3=9;in.set isi"le8tr#e9;Velse if8s.e #als8LE itL99Uint J$6ptionPane.s)o& onfirm!ialog8n#ll5LAre Ro# S#reMML9;if8 JJ$6ptionPane.RESW6PT*6,9U

System.e it8=9;VVV

p#"lic static %oi main8String argsCD9Umi src mJne& mi src89; m.set!efa#lt lose6peration8$Frame.!*SP6SEW6,W 6SE9; m.setSize814==5>3=9; m.set isi"le8tr#e9;VV0.2 5A>A >E1SIONS

Page 34: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 34/47

Page 35: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 35/47

Page 36: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 36/47

Fi) .0 1e)i&tration $orm

Fi) . Create Ne 4&er

Page 37: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 37/47

Fi) .2 7odi$% 4&er

Fi) .6 CDan)e Pa&& ord

Page 38: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 38/47

Fi) ./ SDo Pa&& ord

Fi) .3 1ate In&ertion

Page 39: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 39/47

Fi) .9 4&er lo)in

Fi) . ! Pa%ment T%*e

Page 40: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 40/47

Fi) . Generate &li*

Fi) . + CDec &li* #alidit%

Page 41: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 41/47

Fi) . 0 CDec *a&& #alidit%

Fi) . SDo u&er *a&& ord

Page 42: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 42/47

Fi) . 2 Lo)in &toc re*ort

Fi) . 6 Sli* &toc re*ort

.+ S477A1 OF 1ES4LT

6n an open toll system5 all %e)icles stop at %ario#s locations along t)e )ig)&ay to pay

a toll. 8,ot to "e conf#se &it) Lopen roa tollingL5 &)ere no %e)icles stop to pay

toll.9 ()ile t)is may sa%e money from t)e lac' of nee to constr#ct toll "oot)s at

Page 43: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 43/47

e%ery e it5 it can ca#se traffic congestion &)ile traffic #e#es at t)e mainline toll

plazas 8toll "arriers9. *t is also possi"le for motorists to enter an open toll roa after

one toll "arrier an e it "efore t)e ne t one5 t)#s tra%elling on t)e toll roa toll:free.

0ost open toll roa s )a%e ramp tolls or partial access j#nctions to pre%ent t)is

practice5 'no&n as L s)#npi'ing L.

(it) a close system5 %e)icles collect a tic'et &)en entering t)e )ig)&ay. *n some

cases5 t)e tic'et isplays t)e toll to "e pai on e it. ?pon e it5 t)e ri%er m#st pay t)e

amo#nt liste for t)e gi%en e it. S)o#l t)e tic'et "e lost5 a ri%er m#st typically pay

t)e ma im#m amo#nt possi"le for tra%el on t)at )ig)&ay. S)ort toll roa s &it) no

interme iate entries or e its may )a%e only one toll plaza at one en 5 &it) motorists

tra%elling in eit)er irection paying a flat fee eit)er &)en t)ey enter or &)en t)ey e it

t)e toll roa . *n a %ariant of t)e close toll system5 mainline "arriers are present at t)e

t&o en points of t)e toll roa 5 an eac) interc)ange )as a ramp toll t)at is pai #pon

e it or entry. *n t)is case5 a motorist pays a flat fee at t)e ramp toll an anot)er flat fee

at t)e en of t)e toll roa ; no tic'et is necessary. *n a ition5 &it) most systems5

motorists may only pay tolls &it) cas) an <or c)ange; e"it an cre it car s are not

accepte . Ho&e%er5 some toll roa s may )a%e tra%el plazas &it) AT0s so motorists

can stop an &it) ra& cas) for t)e tolls.

T)e toll is calc#late "y t)e istance tra%elle on t)e toll roa or t)e specific e it

c)osen. *n t)e ?nite States5 for instance5 t)e Nansas T#rnpi'e5 6)io

T#rnpi'e5 Pennsyl%ania T#rnpi'e5 ,e& $ersey T#rnpi'e5 most of t)e *n iana Toll

oa 5 an portions of t)e 0assac)#setts T#rnpi'e5 ,e& Ror' T)r#&ay5 an Flori a s

T#rnpi'e c#rrently implement close systems.

T)e ?nion Toll Plaza on t)e Gar en State Par'&ay &as t)e first e%er to #se an

a#tomate toll collection mac)ine. A pla #e commemorating t)e e%ent incl# es t)e

first #arter collecte at its toll "oot)s .

CONCL4SION/y oing of toll plaza &e can )a%e t)e "est sol#tion o%er money loss at toll plaza "y

re #cing t)e man po&er re #ire for collection of money an also can re #ce t)e

Page 44: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 44/47

traffic in irectly res#lting in re #ction of time at toll plaza. From t)e a"o%e

isc#ssions &e can concl# e t)at toll ta is a fee &)ic) is #se for t)e #se of a ne&ly

constr#cte facility to reco#p t)e total capital o#tlay. T)e pri%ate organization "#il s5

operates an t)en transfers t)e facility after a projecte perio of time. T)e Electronic

Toll ollection 8ET 9 system is t)e most efficient met)o of toll collection &it)

minim#m elays. /#t #e to its )ig) installation cost it7s not t)at pre%alent in *n ia.

(e can fin t)e optim#m n#m"er of toll"oot)s "y applying #e#ing t)eory to

ascertain t)e elays in "ot) #e#ing an merging areas. T)e optim#m n#m"er of

toll"oot)s s)o#l minimize t)e o%erall elay time. T)e toll plaza esign s)o#l "e

one in accor ance &it) t)e *n ian Stan ar o es a%aila"le. Toll prices are set in a

&ay t)at t)ey attract ma im#m n#m"er of #sers an t)e agency s)o#l "e a"le to

reco%er t)e cost &it)in specifie perio of time.As mentione a"o%e t)e toll rates s)o#l not "e more t)an sa%ings eri%e "y t)e roa

#ser "y #sing t)e facility. T)e sa%ings &ill "e percei%e ifferently "y people of

ifferent category an people #sing ifferent mo es. For p#"lic transport #ser5 )e<s)e

is not concerne &it) %e)icle operating cost. *nstea 5 )e<s)e is concerne &it) t)e

fare to "e pai for t)e #nit istance tra%elle . /#t for pri%ate mo e5 t)e #ser is

concerne &it) t)e %e)icle operating cost an tra%el time sa%e . Tra%el istance5

tra%el time an toll are ta'en as eterrence meas#re. 0a im#m limit of toll as aeterrence is fo#n 5 "eyon &)ic) t)e s#ggeste s)ortest pat) "ecomes

#neconomical. Toll is a fee collecte for t)e #se of t)e roa 5 "ri ge5 t#nnel5 etc. to

reco%er t)e total capital o#tlay &)ic) incl# es interest on o#tlay5 cost of repairs5

maintenance an also e penses on collection of toll. Hence t)e amo#nt of toll s)o#l

not e cee t)e "enefits &)ic) t)e #ser recei%e &)ile #sing t)e toll roa . T)e "enefits

are #e to sa%ings in tra%el time5 tra%el cost5 increase in comfort an con%enience. T)e

toll str#ct#re s)o#l "e fi e in s#c) a &ay t)at in%estments an e penses arereco%ere &it)in a reasona"le perio of time. T)e pro #ct of optim#m toll rate an

traffic %ol#me finally etermines t)e gross toll re%en#e.T)e entire toll plaza area can "e i%i e into t&o areas namely #e#ing an t)e

merging area. T)e %e)icles line #p to pay t)e toll in t)e #e#ing area. T)e %e)icles

&ait for t)eir t#rn to pay t)e toll at t)e toll "oot). T)e elay is calle as t)e #e#eing

elay. Similarly5 once t)e %e)icle crosses t)e toll "oot)5 t)e n#m"er of lanes re #ces

from n#m"er of toll"oot)s to t)e original &i t) of t)e )ig)&ay. A %e)icle tra%elling in

a lane )as to &ait or slo& o&n to allo& anot)er %e)icle in t)e a jacent lane to pass.

Page 45: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 45/47

T)ese 'in of elays are terme as merging elays. 0an#al toll collection is most

&i ely #se collection met)o in *n ia. *t re #ires a toll collector or atten ant. /ase

on t)e %e)icle classification5 cas) toll is recei%e "y t)e collector. T)e collector5 &)o

also ispenses c)ange5 may accept an sell scrip5 tic'ets5 co#pons5 ma'ing an entry of

t)e %e)icle in t)e system an iss#ing receipt to t)e patron !#e to man#al inter%ention5

t)e processing time is )ig)est.

F4T41E SCOPEET lane < F*! "ase tolling system &ill "e #se at almost e%ery toll plaza in *n ia

in t)e near f#t#re. ET tolling systems )a%e "een recommen e in a report "y t)e

Ape ommittee constit#te "y t)e Go%ernment of *n ia #n er t)e c)airmans)ip of ,an an ,il'eni. Toll collection systems "ase on GPS tec)nology &ill "e

implemente in t)e near f#t#re. T)e free:flo& system can manage se%eral lanes5

electronically collecting tolls from %e)icles as t)ey pass "eneat) an o%er)ea gantry.

T)is system is c#rrently "eing #se in co#ntries s#c) as t)e ?nite States5 A#stralia5

ana a5 )ile an *srael. *n a free:flo& system5 t)ere are no lane i%i ers an

t)erefore no a#tomatic "arrier gates. ()en %e)icles pass t)ro#g) a gantry5 ata gets

e c)ange "et&een tags installe on %e)icles an rea ers installe on gantry. T)is

e c)ange )appens sim#ltaneo#sly on all lanes at once. e)icles on7t e%en )a%e to

Page 46: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 46/47

slo& o&n. *f a %e)icle oes not )a%e a %ali tag5 t)e system recor s t)e transaction

as a %iolation5 recognises its licence plate a#tomatically5 an t)e toll is collecte later.

Total cost of t)at roa .T)e #ration of toll plaza.

An t)e remaining "alances after eac) transaction.

*mplementation of a#tomatic money e"it system

*mplementation of image processing for centralize ata recor ing

!esigne a system to gi%e complete sol#tion for traffic an transport relate pro"lems

s#c) as Toll gate control5 traffic signal control5 traffic r#les %iolation control5 par'ingmanagement an special zone alert #sing t)e latest F*! tec)nology. *t is propose as

a lo& cost optimize sol#tion #sing F*! an GS0 mo"ile tec)nology.

1EFE1ENCES

,EBSITES@eb link AsedB; www.tollpla asystem.com@eb link AsedB; www.wikipedia.comDjava @eb link AsedB; httpBDDwww. eegmo.comDtollpla asystem.php

Page 47: Toll plaza system

8/19/2019 Toll plaza system

http://slidepdf.com/reader/full/toll-plaza-system 47/47