Question: Problem-9 Write the classes as shown in the following class diagram. Mark all the overridden methods with annotation @Override. Person -name : String -address :

Problem-9 Write the classes as shown in the
Problem-9 Write the classes as shown in the following class diagram. Mark all the overridden methods with annotation @Override. Person -name : String -address : String +Person (name : String, address : String) +getName () : String +getAddress ( ) : String +setAddress (address: String) : void +toString() :String . --- "Person [ name=?, address=?]" extends 4 Student Staff -program: String -school : String -year : int -pay : double - fee : double +Staff(name : String, address : String, +Student (name : String, address : String, school : String, pay : double) program : String, year : int, fee : double) +getSchool() : String +getProgram() : String +setSchool(school : String) : void +setProgram(program: String) : void +getPay( ) : double +getYear ( ) : int +setPay(pay : double) : void +setYear (year : int) : void +toString() : String . +getFee() : double +setFee( fee : double) : void +toString() : String . "Staff [Person [ name=? , address=? ], school=?, pay=?]" "Student [Person [ name=?, address=? ], program-? , year-?, fee=?]"

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!