Exam 12: Object-Oriented Design

arrow
  • Select Tags
search iconSearch Question
flashcardsStudy Flashcards
  • Select Tags

Why is it generally considered good practice to minimize coupling between classes?

(Multiple Choice)
4.8/5
(33)

Suppose that the invoice-printing application from section 12.3 needs to be enhanced by including the computation and printing of sales taxes as needed. Since some vendors charge no sales taxes, the original Invoice class needs to be preserved. Select the code segment that best illustrates reuse of the existing Invoice class. public class TaxableInvoice ___________________________

(Multiple Choice)
4.7/5
(35)

UML means____.

(Multiple Choice)
4.9/5
(34)

Which of the following code snippets denotes that the Rose class inherits from the Flower class?

(Multiple Choice)
4.7/5
(44)

The final step of the design phase recommended by the textbook is to ____.

(Multiple Choice)
4.8/5
(34)

You have determined a need for an Employee class and a TemporaryEmployee class in your program. Which relationship is most appropriate between these classes?

(Multiple Choice)
4.7/5
(45)

Select a code segment to complete the Player class, so that it reflects an inheritance relationship between Player and Person. public class Player ___________________________

(Multiple Choice)
4.8/5
(45)

You are designing a software solution for a veterinary clinic. The clinic provides various services for each pet on each visit. You have decided that the following classes are needed: Customer, Address, Pet, and Visit. Which of these should be represented as aggregation?

(Multiple Choice)
4.7/5
(44)

Which of the following code snippets denotes that the Lime class inherits from the Citrus class?

(Multiple Choice)
4.8/5
(28)

When designing classes, if you find classes with common behavior you should ____.

(Multiple Choice)
4.7/5
(39)

You are designing a software solution for an automobile rental company. You have decided that the following nouns apply to the requirements: Auto, Customer, Address, Rental Contract, Mileage, Rental Date, Daily Rate, Total. Which of these should be represented as classes?

(Multiple Choice)
5.0/5
(37)

Which of the following questions should you ask yourself in order to determine if you have named your class properly?

(Multiple Choice)
4.9/5
(35)

In a UML diagram, the relationship symbol shown below denotes ____. In a UML diagram, the relationship symbol shown below denotes ____.

(Multiple Choice)
4.8/5
(33)

Select a code segment to complete the Team class, so that it reflects an aggregation relationship between Team and Player. public class Team ___________________________

(Multiple Choice)
4.8/5
(31)

Suppose you are developing a payroll application that computes and displays weekly paycheck amounts for various employees. As a result of the design phase, the partial Employee class below is developed. Select the method header that best completes the class, according to the method comments. public class Employee { Private int hoursWorked; /** Computes the weekly salary for this employee. @param hourlyRate the rate per hour earned by the employee @return the weekly salary */ _________________________________________ { // method body } }

(Multiple Choice)
4.9/5
(34)

A CashRegister class contains an array list of Coin objects. This is best described as an example of ____.

(Multiple Choice)
4.9/5
(34)

Which of the following can be used to record the behavior of classes?

(Multiple Choice)
4.8/5
(39)

Select a code segment to complete the SmartPhone class, so that it reflects an interface implementation relationship between SmartPhone and MP3Player. public class SmartPhone ___________________________

(Multiple Choice)
4.9/5
(38)

How does a UML diagram denote a multiplicity of one or more in an aggregation relationship?

(Multiple Choice)
4.9/5
(35)

In a UML diagram, the relationship symbol shown below denotes ____. In a UML diagram, the relationship symbol shown below denotes ____.

(Multiple Choice)
4.9/5
(36)
Showing 61 - 80 of 104
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)