Question: Need this answered within an hour, Programming Language is JAVA. Output is provided, but it shouldn't just print out the output. It should prompt me,

Need this answered within an hour, Programming Language is JAVA. Output is provided, but it shouldn't just print out the output. It should prompt me, and then I enter what's in the Output. Ship.java is now provided.

Need this answered within an hour, Programming Language is JAVA. Output is

provided, but it shouldn't just print out the output. It should prompt

me, and then I enter what's in the Output. Ship.java is now

provided. Purpose: To review inheritance in java by defining a superclass and

two subclasses, instantiating objects of those classes, and calling methods of the

Purpose: To review inheritance in java by defining a superclass and two subclasses, instantiating objects of those classes, and calling methods of the instantiated objects Instructions: Modify class Ship to meet the revised requirements described in the following UML Class Diagram Ship Attributes private name: String private year: int private builder: String Name of the ship Year of build Builder company Operations cconstructor Ship): Ship Ship(name: String, Default or null constructor Constructor accepting three (3) parameters. Returns a fully formed and fully functional Ship object reference year: int, builder: String): Ship public setName(aName: String): void public setYear(aYear: int): void public setBuilder(aBuilder: String): void Accepts a String object(local name:aBuilder) and assigns public getName(): String Accepts a String object(local name:aName) and assigns it to the instance variable name Accepts an int value(local name:aYear) and assigns it to the instance variable year it to the instance variable builder Returns the current value of instance variable name Returns the current value of instance variable year Returns the current value of instance variable builder ublic getYear): int public getBuilder): String Returns a formatted String containing a 'state report', that is, the current values of each of the object's instance variable public toString): String

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 Databases Questions!