Vous êtes sur la page 1sur 42

Practical 3 Aim : Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts.

And add at least 5-7 attributes and 3-5 operations for particular class [A] Page, Shape, Point, Line, Arc, Ellipse, Rectangle, Circle

-page Page 1..*

-shapes Shape 0..*

0-Dimensional

1-Dimensional

2-Dimensional

Point

Line

Arc

Ellipse

Rectangle

Circle

Practical 3 Aim : Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts. And add at least 5-7 attributes and 3-5 operations for particular class [A] Page, Shape, Point, Line, Arc, Ellipse, Rectangle, Circle
Shape #color : string(idl) #position : any(idl) #dimension : fixed(idl)

Page +pageno : any(idl)

0 Dimensional

1 Dimensional #orientation : float(idl)

Point

Line #length : fixed(idl)

Arc #diameter : fixed(idl) #arcAngle : float(idl)

2 Dimensional #width : fixed(idl) #height : fixed(idl)

Ellipse #orientation : float(idl)

Rectangle #orientation : float(idl)

Circle #orientation : float(idl) #radius : fixed(idl)

Practical 4 Aim : Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts. And add at least 5-7 attributes and 3-5 operations for particular class [A] City, Airport, Airline, Pilot, Flight, Plane, Seat, Passenger

-Airline
City Airline

-Pilots
Pilot

1
AvailAirports

#City
companyflights

1 -Airline

recruits

* 2..* -Pilot

navigates

0..1

#Airport #Airport 1 1

#Departure

-Flights
Flight

1 -Flights
allocated

Ar r

leavingflights

iv al

Airport

# rp Ai or t

1..* 1..*

-Flight 1

1..*

-Flight

Arrivingflights

0..*
travels

-Plane

Plane

-Passenger

-Plane

Passenger

capacity

*
Seat

-Seat

Practical 4 Aim : Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts. And add at least 5-7 attributes and 3-5 operations for particular class [A] City, Airport, Airline, Pilot, Flight, Plane, Seat, Passenger

City #name : string(idl)

Airline #name : string(idl)

Pilot #name : string(idl)

Airport #name : string(idl)

Flight #date : fixed(idl) #flightnumber : string(idl)

Plane #model : string(idl) #serialnumber : string(idl) #hoursflown : float(idl)

Passenger #name : string(idl)

Seat #location : fixed(idl)

Practical 5 Aim : Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [A] School, Playground, Principal, School board, Classroom, Book, Student, Teacher, Restroom, Computer, Desk, Chair, Door, Swing

Persons

* Principal Student Teachers

Swing 0..*

-Principal

-students

1..*

-teachers
1 Playground

0..*

-playground

1 1 -School -school 1
1 School

Books

+School *
Door 1..2 1 1

1 1 1..*

Computer Schoolboard 1..*

+Room
Desk 1 0..* Chair 0..*

Room

Restroom

Staffroom

Cafeteria

Classroom

Practical 5 Aim : Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [A] School, Playground, Principal, School board, Classroom, Book, Student, Teacher, Restroom, Computer, Desk, Chair, Door, Swing

Persons

Principal #name : string(idl) #dob : any(idl) #contact : string(idl) #qualifications : string(idl) #timeperiod : any(idl)

Student #name : string(idl) #std : fixed(idl) #rollno : string(idl) #dob : any(idl) #contact : string(idl)

Teachers #name : string(idl) #dob : any(idl) #contact : string(idl) +qualifications : string(idl)

Books #name : string(idl) #author : string(idl) #type : string(idl) #version : string(idl) #category : string(idl)

School +name : string(idl) +id : string(idl) +location : string(idl) +type : string(idl) +contact : long double(idl) +medium : string(idl) +level : string(idl) +admission() : boolean(idl) +maintenance() : string(idl)

Room

Classroom Restroom +doors : fixed(idl) +windows : fixed(idl) +chairs : fixed(idl) +fans : fixed(idl) Staffroom +desk : fixed(idl) +chairs : fixed(idl) +window : fixed(idl) +fans : fixed(idl) +ac : fixed(idl) -lights : fixed(idl) Cafeteria +tables : fixed(idl) +chairs : fixed(idl) +doors : fixed(idl) +window : fixed(idl) +fans : fixed(idl) -lights : fixed(idl) +desks : fixed(idl) +chairs : fixed(idl) +window : fixed(idl) +fans : fixed(idl) +lights : fixed(idl) +doors : fixed(idl)

Practical 5 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [B] Automobile, Engine, Wheel, Brake, Brake light, Door, Battery, Muffler, Tail pipe

1 Automobile #Auto 1 #Engine

-Vehical

-wheels Wheels

2..*

Engine -LMV 1 Two wheeler -TW 1 -TW 1 -TW 1 -LMV 1 1 -lmv -LMV 1 1 -LMV-LMV -TW 1 Light motor vehical -HMV 1 1-HMV-HMV-HMV 1 1 1 Heavy motor vehical

-BRKL -BRKL

2..5 1 -Muffer Door

-Doors 2

Breaklight

-Doors Muffer -Brakes

-Brakes 4..*

Brakes 2 -Brakes

2..4

2..4 -Tailpipe

-Tailpipe 1 1..2 -Battery Battery 1 -battery -Battery 1..*

Tail pipe -Tailpipe

Practical 5-b assosiation

Practical 5 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [B] Automobile, Engine, Wheel, Brake, Brake light, Door, Battery, Muffler, Tail pipe

Engine -type : string(idl) -fueltype : string(idl) -turbo : boolean(idl) -rpm : float(idl) -displacement : string(idl) -radiotors : fixed(idl) -cranshafttype : string(idl) -transmissiontype : string(idl) -gearboxsystem : string(idl) -r&d() : string(idl) +repair() : string(idl) +maintainance() : string(idl)

Brakes -type : string(idl) -durability : string(idl) -cost : double(idl) -diameter : float(idl) -brakecallipers : string(idl) -brakeliner : fixed(idl) -r&d() : string(idl) +testing() : string(idl) +fitting() : string(idl) +replacement() : boolean(idl)

Automobile -wheels : fixed(idl) -vehicaltype : string(idl) -cost : double(idl) -manufacturer : string(idl) -bodytype : string(idl) -r&d() : string(idl) +paintjob() : string(idl) +service() : string(idl) +testing() : boolean(idl)

Battery -type : fixed(idl) -capacity : string(idl) -cost : double(idl) -dimension : string(idl) -r&d() : string(idl) +repair() : string(idl) +fitting() : string(idl) +testing() : boolean(idl)

Twowheeler

Lightmotorvehical -vehicaltype : string(idl)

Heavymotorvehical -vehicaltype : string(idl)

Muffer Wheels -alloytype : fixed(idl) -manufacturer : string(idl) -cost : double(idl) -design : string(idl) -size : fixed(idl) -tyretype : string(idl) -r&d() : string(idl) +fitting() : string(idl) +maintainance() : string(idl) +replacement() : boolean(idl) Door -type : fixed(idl) -size : string(idl) -cost : double(idl) -color : string(idl) -windowtint : string(idl) -windowtype : string(idl) -lockingsystem : fixed(idl) -r&d() : string(idl) +fitting() : string(idl) +repair() : string(idl) +testing() : boolean(idl) Brakelights -color : fixed(idl) -type : string(idl) -dimension : fixed(idl) -orientation : fixed(idl) -r&d() : string(idl) +repair() : string(idl) +fitting() : string(idl) +testing() : boolean(idl) Tailpipe -size : fixed(idl) -type : string(idl) -cost : double(idl) -manufacturer : string(idl) -material : fixed(idl) -r&d() : string(idl) +fitting() : string(idl) +repair() : string(idl) +testing() : boolean(idl) -type : fixed(idl) -cost : fixed(idl) -material : string(idl) -size : fixed(idl) -dimension : string(idl) -orientation : fixed(idl) -paint : string(idl) -r&d() : string(idl) +repair() : string(idl) +fitting() : string(idl) +testing() : boolean(idl)

Practical 6 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [C] Castle, Moat, Draw bridge, Tower, Ghost, Stairs, Dungeon, Floor, Corridor, Room, Window, Stone, Lord, Lady, Cook

+ghost +castle +moat Moat 1 1 #castle #moat 1 Castle +castle 1 11 1 1 1 1 1 +castle 1 +castle +castle 0..* +dragon Dragon 0..* +cook Cook +lady * +stone 1..* Lady +tower 1..* 1..* Ghost

+draw bridge

1..*

Drawbridge

Stone 0..* 1..*

Tower

1 Lord * -floor

+lord

+tower

+room

Room 1 Stairs +stairs 1..* +floor Floor 1..* +room

0..*

+coridor 0..* +window

Corridor Window

Practical 6 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [C] Castle, Moat, Draw bridge, Tower, Ghost, Stairs, Dungeon, Floor, Corridor, Room, Window, Stone, Lord, Lady, Cook

Castle +name : string(idl) +location : string(idl) #buildtime : fixed(idl) +king : string(idl) +symbol : any(idl) #maintaince() : boolean(idl) -security() Drawbridge #length : string(idl) #type : string(idl) #material : string(idl) -durability : string(idl) #maintaince() : boolean(idl) -working() : boolean(idl) Tower #height : string(idl) #durability : string(idl) #type : fixed(idl) -material : string(idl) #standing capacity : any(idl) #maintaince() : boolean(idl) -watch() : boolean(idl) Ghost +name : string(idl) +type : string(idl) +identity : string(idl) +frighteingg() : string(idl) Dragon +name : string(idl) +armour : string(idl) +type : string(idl) -wapon : string(idl) #strength() : string(idl) -warfare() : string(idl) Moat -length : float(idl) -depth : float(idl) -filled type : string(idl) -protection() : boolean(idl) #maitanince() : boolean(idl) Stairs +type : string(idl) -material : string(idl) #dimension : string(idl) #durability : string(idl) #maintaince() : boolean(idl)

Room Floor +dimension : string(idl) #type : string(idl) #capacity : string(idl) #material : string(idl) #maintaince() : boolean(idl) Corridor #width : float(idl) #hight : float(idl) #length : float(idl) -material : string(idl) #roof type : string(idl) #maintaince() : boolean(idl) -() +location : string(idl) +walls : any(idl) +doors : any(idl) +windows : any(idl) +type : string(idl) +capacity : any(idl) #entites : any(idl) #maintaince() : boolean(idl) +resting() : string(idl) +leaveing() : string(idl) Window +type : string(idl) +dimension : string(idl) +location : string(idl) #material : string(idl) +frames : string(idl) #maintaince() : boolean(idl) -security()

Stone #type : string(idl) +width : string(idl) +length : float(idl) +shape : string(idl) +colour : string(idl) #fabrication() : string(idl) #fitting() : boolean(idl) Lord +name : string(idl) +hight : any(idl) #physic : string(idl) +qualification : string(idl) #manegment() : string(idl)

Lady +name : string(idl) +hight : any(idl) #physic : string(idl) #qualification : string(idl) +relative : string(idl) #cooking() : boolean(idl) #main() Cook +gender : boolean(idl) +total cooks : string(idl) #working() : boolean(idl) -grocery shopping()

Practical 6 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [D] Expression, Constant, Variable, Function, argument list, Relational operator, Term, Factor,

Arithmetic operator, Statement, computer program.

1 Computer program -CP 1 -CP

-CP

-Statment

0..*

-Indicator

Statement 1..* -Func

Indicator

-Statment

Function -Function 1 Constant Variable

-Args Argument list 0..*

-Args

0..*

1..*

-Expr 1 -Expression Expressiion 1 0..* -Operators Operators

Relational operator

Arithmatical operator

Practical 6 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [D] Expression, Constant, Variable, Function, argument list, Relational operator, Term, Factor,

Arithmetic operator, Statement, computer program.

Expression -type : fixed(idl) -name : fixed(idl) -syntax : fixed(idl) -declaration : any(idl) -necessity : fixed(idl) #declaration() : any(idl) +operations() : any(idl)

Computerprogram -name : fixed(idl) -type : any(idl) -defination : any(idl) -language : fixed(idl) -programmer : fixed(idl) +execution() : any(idl) -compilation() #debug() : string(idl)

Operators +name : string(idl) +syntax : any(idl) +function : any(idl) +type : any(idl) +evaluate() : any(idl)

Indicator +name : fixed(idl) +data type : fixed(idl) +value : fixed(idl) #accessspecifier : any(idl) +memory size : any(idl) +declaration() : any(idl) +retrive() : any(idl) +modification() : fixed(idl) +malloc() : fixed(idl) +dealloc() Relationaloperator Arithmaticoperator

Function -name : fixed(idl) -type : fixed(idl) -returntype : fixed(idl) -accessspecifier : any(idl) -noofarguments : any(idl) #defination() : fixed(idl) +declaration() : fixed(idl) +call() : fixed(idl)

Variable

Constant

Statment -length : fixed(idl) -type : any(idl) +execute() : any(idl) +debug() : string(idl) +compile()

Argumentlist -name : any(idl) -noofparameters : fixed(idl) -type : fixed(idl) -returntype : any(idl) -noofarguments : any(idl) #declaration() : any(idl) +valueassigment() : any(idl) +modification() : any(idl)

Practical 7 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [E] File system, File, ASCII File, Binary File, Directory File, Disk, Drive, Track, Sector
+disk Disk 1 1 +disk 1..* 1 +drive 1 +drive +drive Drive

1..*

+file sys 1 1..* #track #track +file sys Track 1 * #sector Sector

File system

+file sys

#file File *

ASCII file

Binary file

Directory file

Practical 7 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [E] File system, File, ASCII File, Binary File, Directory File, Disk, Drive, Track, Sector

File File system -memory used : any(idl) -efficiancy : string(idl) -bits per file : any(idl) -retrive speed : float(idl) -storing speed : float(idl) -modification speed : float(idl) #storing() : string(idl) #retriving() : string(idl) #modification() : string(idl) #deleting() : string(idl) +file type : string(idl) +file storage type : string(idl) +type of data : string(idl) +size : any(idl) #max size : any(idl) -physical address : string(idl) #storing() : string(idl) #retriving() : string(idl) #modification() : string(idl) #deleting() : string(idl) #shorting() #searching()

Drive +size : float(idl) +capacity : float(idl) +type : string(idl) #storing() #retriving() #searching() #modification() #shorting()

ASCII file

Binary file

Directory file

Disk +size : float(idl) +capacity : float(idl) +type : string(idl) #speed of data transfer : float(idl) #storing() #retriving() #searching() #modification() #shorting() Track -track size : float(idl) -no of sector : any(idl) #storing() #retriving() #searching() #modification() #shorting()

Sector +size : float(idl) -addressing pointer : string(idl) -flags : boolean(idl) #storing() #retriving() #searching() #modification() #shorting()

Practical 7 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [F] Gas Furnance, Blower, Blower motor, Room thermostat, Furnace thermostat, Humidifier,

Humidity sensor, Gas control, Blower control, Hot air Vent

1 Gas furnace -GF 1 1..* -Blower -Blower Blower 1 1 -Blower 1 1

-GF -GF 1

-GC Gascontrol 1..4

-GF

2..*

-HS

Humiditysensor

1 1..* -BM

-BC

Blowercontrol 4..* -FT

Blowermotor Furnancethermostat -HF Humidifire 2..*

1..4

-RT

Roomthermostat

Practical 7 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [F] Gas Furnance, Blower, Blower motor, Room thermostat, Furnace thermostat, Humidifier,

Humidity sensor, Gas control, Blower control, Hot air Vent

Blower -nozzlesize : fixed(idl) -materialtype : fixed(idl) -sourcecapacity : string(idl) +blowup() : fixed(idl) +shutdown() : boolean(idl)

Gasfurnance -size : fixed(idl) -maxtemp : fixed(idl) -mintemp : fixed(idl) -foundation : string(idl) +burning() : any(idl) +cleaning() : any(idl) +maintainance() : any(idl)

Humidifier -hidtype : string(idl) -dimension : fixed(idl) -blower : string(idl) -maxhumidity : float(idl) -voltage : fixed(idl) +startup() : boolean(idl) +shutdown() : boolean(idl) +controlstat() : fixed(idl) +generatehum () : float(idl)

Blowermotor -motortype : fixed(idl) -motorcapacity : fixed(idl) -power : float(idl) +startup() : boolean(idl) +shutdown() : boolean(idl) +blowup() : fixed(idl)

Roomthermostat -lcdpanel : any(idl) -thermotype : string(idl) -maxtemp : float(idl) -mintemp : float(idl) -tolerance : float(idl) -voltage : fixed(idl) +startup() : boolean(idl) +shutdown() : boolean(idl) +reading() : fixed(idl) +controlstat() : fixed(idl)

Furnancethermostat -lcdpanel : any(idl) -thermotype : string(idl) -maxtemp : float(idl) -mintemp : float(idl) -tolerance : float(idl) -voltage : fixed(idl) +startup() : boolean(idl) +shutdown() : boolean(idl) +reading() : fixed(idl) +controlstat() : fixed(idl)

Gascontrol -lcdpanel : any(idl) -valvetype : string(idl) -pipedia : float(idl) -flowcontroller : float(idl) -tolerance : float(idl) +valvestat() : boolean(idl) +reading() : fixed(idl) +controlstat() : fixed(idl) Humiditysensor Blowercontrol -lcdpanel : any(idl) -tolerance : float(idl) -valvesize : string(idl) -voltage : fixed(idl) -power : float(idl) +startup() : boolean(idl) +shutdown() : boolean(idl) +reading() : fixed(idl) +controlstat() : fixed(idl) -sensortype : string(idl) -maxtemp : float(idl) -mintemp : float(idl) -tolerance : float(idl) -voltage : fixed(idl) +startup() : boolean(idl) +shutdown() : boolean(idl) +reading() : fixed(idl) +controlstat() : fixed(idl)

Practical 8 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [G] Chess piece, Rank, File, Square, Board, Move, Tree of moves

board +material : string(idl) +length : any(idl) +width : any(idl)

+chess piece +board 1..32 1

Chess piece +type : string(idl) +colour : string(idl) +material : string(idl) +move() +kill() +check() 1 +chess piece

+board

1..64 squre

-squre

0..* Move

+move

+squre id : string(idl) +colour : string(idl)

+type of piece : string(idl) +kill() +check() 1 * +tree of move +move

rank +player nm : string(idl) +rank : any(idl) +move()

Tree of move +type of piece : string(idl) +move() +kill() +check()

Practical 8 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [G] Chess piece, Rank, File, Square, Board, Move, Tree of moves

board +material : string(idl) +length : any(idl) +width : any(idl)

Chess piece +type : string(idl) +colour : string(idl) +material : string(idl) +move() +kill() +check()

Move +type of piece : string(idl) +kill() +check()

squre +squre id : string(idl) +colour : string(idl) rank +player nm : string(idl) +rank : any(idl) +move()

Tree of move +type of piece : string(idl) +move() +kill() +check()

File +name #type

Practical 8 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [H] Sink, Freezer, Refrigerator, Table light, Switch, Window, Smoke alarm, Burglar alarm,

Cabinet, Bread, Cheese, Ice, Door, Kitchen


Sink 1..* +switch Switch 1..* Kitchen +light Light 0..* 1 1 1 1 1 1 1 +kitchen 0..* 1 1 1 +smoke alarm Smoke alarm +sink +cabinet Cabinate 0..*

0..* Refrigerator +refrigerator 1 1 1..* 1 Freezer +freezer 1 +freezer 1 Windows Door Table +window 1..2 +door 0..* +table

+burglar alarm Burglar alarm 0..*

+table

0..* Ice

+ice

0..*

+cheese 0..* +bread

Cheese

Bread

Practical 8 Aim: Prepare a class diagram for given group of classes using multiplicity, generalization, association concepts and Add at least 5-7 attributes and 3-5 operations for particular class [H] Sink, Freezer, Refrigerator, Table light, Switch, Window, Smoke alarm, Burglar alarm,

Cabinet, Bread, Cheese, Ice, Door, Kitchen

Cabinet Sink +material : string(idl) +width : float(idl) +depth : float(idl) +shape : string(idl) +wash() Freezer +material : string(idl) +width : float(idl) +hight : float(idl) +depth : float(idl) +cooling point : any(idl) +capacity : float(idl) +freezing() +manufacturer : string(idl) +width : float(idl) +depth : float(idl) +length : float(idl) +colour : string(idl)

Refigerator +manufacturer : string(idl) +width : float(idl) +depth : float(idl) +length : float(idl) +colour : string(idl) +size : any(idl) +cooling() +store things()

Smokealarm Table +manufacturer : string(idl) +length : float(idl) +width : float(idl) +hight : string(idl) +material : string(idl) +colour : string(idl) +held things() Light +manufacturer : string(idl) +type of current : any(idl) +colour : string(idl) +on() +off() +manufacturer : string(idl) #sensitivity : any(idl) +colour : string(idl) +alarming()

Burglaralarm +manufacturer : string(idl) +sencers : any(idl) +mcu : any(idl) +alarming()

Switch +manufacturer : string(idl) +width : float(idl) +length : float(idl) +colour : string(idl) +on() +off()

Windows +width : float(idl) +higth : float(idl) +depth : float(idl) +colour : string(idl) +ventilation() +open() +close() +lock() Bread +manufacturer : string(idl) +date of made : any(idl) +weight : float(idl) +cutting() +tosting()

Door +manufacturer : string(idl) +material : any(idl) +width : float(idl) +length : float(idl) +hight : float(idl) +colour : string(idl) +open() +close() +lock()

Cheese +manufacturer : string(idl) +date of manu : any(idl) Ice Kitchen +location : string(idl) +width : float(idl) +length : float(idl) +hight : float(idl) +paint colour : string(idl) +floor type : any(idl) +cooking() +storing() +manufacturer : string(idl) +width : float(idl) +hight : float(idl) +length : float(idl) +shape : any(idl) +cooling()

Practical 9 Aim : To prepare class diagram with links and association, generalization, multiplicity for the following list of classes and also add any required class to the diagrams and add following attributes where ever necessary.

Class name: Competitor, Trial, Event, Score, Judge. Attribute name: Address, Age, Date, Difficulty factor, Score, Name.

Competitor #name : string(idl) #category : string(idl) #dob : string(idl) #age : fixed(idl) #address : string(idl) -contact : fixed(idl) #performance() : fixed(idl) #practice() : fixed(idl)
1 1..* -Competitor

Score #comid : string(idl) #category : string(idl) #nooftrials : fixed(idl) #avg : any(idl) #finalscore : fixed(idl)

1..*

#Score

-Trials

1..*

Trial -comid #nooftrials : string(idl) #events : string(idl) #status : string(idl)

1..*

-Events

-Events -Events

Events #name : string(idl) #category : string(idl) #noofcompetitors : any(idl) #difficultyfactor : any(idl)

-Judge

1 -Events

-Judge

1..*

Judge #name : string(idl) #qualification : fixed(idl) #category : string(idl) #contact : string(idl) #judgment() : fixed(idl) #disqualify() : fixed(idl) -scoring() : fixed(idl)

Practical 10 Aim: Prepare a class diagram without IDs and using association and generalization. Try to assign multiplicities. You may need to add one or more classes of your own.

Owner +name : string(idl) 1 1 1 0..*

Car #model : any(idl) #year : any(idl)

* Loan 0..* Person #birth date : any(idl) #address : string(idl) Company Bank * 1 * * -accountNumber : string(idl) #interast rate : float(idl) #current balance : float(idl)

Practical 11 Aim : Improve the existing class diagram by changing some of the associations to aggregations.

Door

Body

GasTank

Automobile

BreakingSystem PowerTrain SteeringSystem

BreakLight

Engine

Transmission

Wheel

BrakeSwitch

Brakes ExhaustSystem ElectricalSystem

Starter Pipe Muffler Battery

Alternator

Practical 12 Aim: Categorize the following relationships into generalization, aggregation or association.

Country 1 1

Capital city

Dining 1 2..*

Fork

[a] A country has a capital city

[b] A dining philosopher uses a fork

File #file File 1 Ordinary Directory * #Records Records

[d] Files contains records

[c] A file is an ordinary file or a directory file


Drawing object

+Polygon Polygon 1

+points Point 3..* Text Geometrical object Group

[e] A polygon is composed of an ordered set of points

[f] A drawing object is text, a geometrical object, or a group


Input/output device

Poject

Programming Lang

Person Keybord Modem

[g] A person uses a computer language on a object

[h] Modems and keyboards are input/output devices

Year +class Classes * * Player +atteribute Attributes 1 1 Team +Play

[i] Classes may have several attributes

[j] A person plays for a team in a certain year


1..* Citys 1 connected 1..* Route Professor +professor +student 1..* Student

[k] A route connects two cities

[l] A student takes a course from a professor

Practical 13 Aim: Prepare a class diagram for a graphical document editor that supports grouping. Assume that a document consists of several sheets. Each sheet contains drawing objects, including geometrical shapes and groups.

+document Document 1

+sheet Sheet * 1 #sheet

#DO

Drawing object 2..*

0..1 Text Geometrica Object Group #Group

Circle

Ellipse

Rectangle

Line

Squre

Practical 14 Aim: Prepare a portion of a class diagram for a library book checkout system that shows the late charges for an overdue book as a derived attribute.

Library +name : string(idl) #no of books : any(idl) #staff : string(idl) +location : any(idl) -finecharges : float(idl) #/fine : any(idl) +renew() +issue() +return()

Book -library -book +name : string(idl) +author name : string(idl) #book id : string(idl) #issue date : any(idl) #duedate : fixed(idl) +issue() +renew() +return() 0..2 #book

Current date

fine= (currentdate-duedate)*finecharges

#person

Person +name : string(idl) #lib account no : string(idl) #book issued : string(idl) #book no : string(idl) -book issue date +issue() +renew() +return()

Practical 15 Aim: Prepare a state diagram in which a digital watch has a display and two buttons to set it, the A button and the B button. The watch has two modes of operation, display time and set time.

Practical 16 Aim: To a partially completed and simplified state diagram for the control of a telephone answering machine, add the following: call detected, answer call, play announcement, record message, Caller hangs up, announcement complete

Practical 17 Aim: Revise the state diagram for practical 16 so that the machine answers after five rings.

Practical 18 Aim: To a partially and simplified state diagram for the control of the data transfer, Add the following: reset, data available, data read by host, new data ready

Practical 19 Aim: To a partially and simplified state diagram for motor control appliance Add the following: Activities: apply power to run winding, apply power to start winding. Events: motor is overheated, on is asserted, on is no longer asserted, motor is running, reset. Condition: motor is not overheated

Practical 20 Aim: Prepare a state diagram for an interactive diagram editor for selecting and dragging objects

Practical 21 Aim: Revise the state diagram for the exercise in practical 19 and update the same for the commonality of the starting and running states

Practical 22 Aim: A gas-fired, forced hot-air, home heating system maintains room temperature and humidity in winter using distributed controls, such as Furnace, Blower, Humidifier etc. Partition the controls into respective state diagrams

Practical 23 Aim: Prepare a use case diagram for a physical bookstore checkout system

Book checkout system


buy items

Payment

Customer

Check payment

Shope keeper give change

Inventory management

Inventory manager

Practical 23 Aim: Prepare a use case diagram for a physical bookstore checkout system

Customer

Check out system

Shope keeper

Bring purchased items scan item price show price show total payable price show price show total payable price generate bill pay money give change & bill

Practical 24 Aim: Prepare a use case diagram and sequence diagram for a computer email system

E-mail system

registration

visitors login

send mail

recive mail

Registered users

folder management

maintenace administrator

Practical 24 Aim: Prepare a use case diagram and sequence diagram for a computer email system

server database

visitor

E-mail system

registered user

administrator

registration update database assign uid, pwd of user Verify Registered user Display user specific data page send mail show incoming mail log in

verify reciver's mail id & send mail mail send successfully

managing folder update changes for specific user logout session closed display login page log in verify unm, pwd for admin Display admin's specific data page managing server setup update changes successfuly updated

Practical 25 Aim: Prepare a use case diagram for an online airline reservation system

Online Airline reservation System

flight schedule

registeration

visitor

log in

book ticket

modify ticket registered users

cancel ticket

content management

site maintainence

web master

Practical 26 Aim: Prepare a use case diagram for a physical library checkout system

Library checkout system


issuse book

return book registered user fine management

check user's id

add book to user account

remove book from user account librarian

new book entry to system

Practical 27 Aim: Prepare a use case diagram for Windows Explorer

Windows explorer
task bar

start menu

icon

task manager

title bar

User / group of users

menu bar

tool bar

scroll bar
Adminstrator

popup menu

control button

Practical 28 Aim: Prepare an activity diagram for computing a restaurant bill, there should be charge for each delivered item. The total amount should be subject to tax and service charge of 18% for group of six and more. For smaller groups there should be a blank entry. Any coupons or gift certificates submitted by the customer should be subtracted.

total items

add tax

credit coupons and certificates

[less then six]

[six or more]

customer determines gratuly

add 18%

Vous aimerez peut-être aussi