This topic contains a solution. Click here to go to the answer

Author Question: Apply the concept of polymorphism to Person/ Work or another object/operation of your choice. ... (Read 65 times)

Brittanyd9008

  • Hero Member
  • *****
  • Posts: 500
Apply the concept of polymorphism to Person/ Work or another object/operation of your choice.
 
  What will be an ideal response?

Question 2

Compare and contrast the use case diagram and an activity diagram.
 
  What will be an ideal response?



Related Topics

Need homework help now?

Ask unlimited questions for free

Ask a Question
Marked as best answer by a Subject Expert

rnehls

  • Sr. Member
  • ****
  • Posts: 313
Answer to Question 1

Person is a superclass with a Work responsibility. Person can have numerous subclasses, including Doctor, Mechanic, and Cook. Instances of all subclasses must work, but the work that they actually do is very different from each other: when objects belonging to Person subclasses are told to work, the Doctor treats patients, while the Mechanic fixes cars and the Cook prepares food. In other words, the same message, Work, is implemented differently depending on the nature of the object, not the nature of the message.

Answer to Question 2

A use case diagram is a visual meta-model: it does not model the use case itself, but the associations between actors, use cases, and the system. It also depicts extend and include relationships between use cases and provides us with a visual table of contents. An activity diagram is a general-purpose diagram for visualizing and verifying a logical flow. For a use case with a complicated alternate flow, an activity diagram is a very helpful tool. Its simplicity facilitates communication between development stakeholders.




Brittanyd9008

  • Member
  • Posts: 500
Reply 2 on: Jul 7, 2018
Excellent


strudel15

  • Member
  • Posts: 324
Reply 3 on: Yesterday
Great answer, keep it coming :)

 

Did you know?

Bacteria have been found alive in a lake buried one half mile under ice in Antarctica.

Did you know?

If you could remove all of your skin, it would weigh up to 5 pounds.

Did you know?

Approximately 70% of expectant mothers report experiencing some symptoms of morning sickness during the first trimester of pregnancy.

Did you know?

Excessive alcohol use costs the country approximately $235 billion every year.

Did you know?

The immune system needs 9.5 hours of sleep in total darkness to recharge completely.

For a complete list of videos, visit our video library