Chapter 12 True/False Indicate whether the statement is true or false. ____ 1. Design class diagrams and sequence diagrams should be developed independent of each other. ____ 2. Design classes always have foreign keys. ____ 3. Dependency relationships cannot exist between classes within packages. ____ 4. The activation lifeline is depicted by a vertical dashed line under an object. ____ 5. The perfect memory assumption means that there is always adequate memory to execute the program. ____ 6. The perfect solution assumption means that we do not worry about exception conditions. ____ 7. The first-cut DCD includes method signatures. ____ 8. A loop or repeating message in a sequence diagram is depicted by a rectangle box. ____ 9. Separation of responsibilities is a design principle to segregate classes into separate components based on the primary focus of the classes. ____ 10. Since updating a design class diagram is done after the use case realization is complete, visibility information is no longer necessary. ____ 11. Usually editing and validating the input data is done as part of the business logic layer. ____ 12. Preparing persistent classes for storage to the database is done by the data access layer. ____ 13. The factory method pattern is used to create classes that can be used to instantiate objects from utility classes. ____ 14. The Observer pattern is also called the listener pattern. ____ 15. In the observer pattern, the object being observed must have a method to register listeners. Multiple Choice Identify the choice that best completes the statement or answers the question. ____ 16. Which of the following is an example of an interaction diagram? a. Design class diagram c. Package diagram b. Data access diagram d. Communication diagram ____ 17. The primary OO design models are ____ diagrams. a. design class and statechart c. package and deployment b. package and statechart d. design class and interaction ____ 18. The realization of a use case—determining what objects collaborate and the messages they send to each other to carry out the use case—is done through the development of a(n) ____. a. deployment diagram c. statechart diagram b. interaction diagram d. package diagram ____ 19. The domain layer of a multilayer design can also be referred to as the ____ layer. a. business logic c. user interface b. database access d. program logic ____ 20. The database access object corresponds to the ____ layer in the multilayer design. a. first c. third b. second d. None of the above ____ 21. What is the least cohesive approach in creating use case controllers in a system? a. Define a single use case controller for all use cases. b. Define several use case controllers, each with a specific set of responsibilities. c. Create a single use case controller for all the use case controllers in a single subsystem. d. Create one use case controllers per use case. ____ 22. The output message in a sequence diagram usually contains ____. a. a lifeline reference c. loop frames b. return variables d. a data object reference ____ 23. What is the first step in constructing a first-cut sequence diagram from the elements of the system sequence diagram (SSD)? a. Determine which other messages must be sent. b. Add all objects that must collaborate. c. Replace the :System object with all of the internal objects and messages within the system. d. Select an input message from the use case. ____ 24. User interface objects in a sequence diagram often are labeled with the stereotype ____. a. entity c. control b. view d. persistent ____ 25. Which of the following symbols is used in a communication diagram, but not in a sequence diagram? a. Message arrow c. Activation lifeline b. Object d. Link ____ 26. Communication diagrams indicate the order of the messages with ____. a. sequential numbers c. arrows b. activation lifelines d. links ____ 27. ____ methods must be included in a design class diagram. a. Constructor c. Get b. Use case specific d. Set ____ 28. The basic package notation is a ____. a. circle with an iconic symbol b. tabbed rectangle c. three component rectangle d. rectangle with an iconic symbol ____ 29. System sequence diagrams may contain ____ frames. a. Loop c. Opt b. Alt d. All of the above ____ 30. Which is the correct syntax for an input message on a sequence diagram? a. * [true/false condition] return-value := message-name (parameter-list) b. [true/false condition] return-value == message name (parameter list) c. [true/false condition] sequence# return-value := message name (parameter list) d. * [true/false condition] sequence# return-value := message name (parameter list) ____ 31. In a sequence, when one assumes that the objects are already available to receive messages, that is considered to be the ____. a. perfect technology assumption. c. perfect solution assumption b. perfect memory assumption d. perfect design assumption ____ 32. View layer classes should do all of the following EXCEPT ____. a. capture clicks and data entry c. create problem domain classes b. start and shut down the system d. display data fields ____ 33. The customer relationship system needs to instantiate a new customer object. How should this be done? a. Let the factory object do it. c. Let the controller object do it. b. Let a view layer object do it. d. Let another business object do it. ____ 34. Given the observer pattern,. and the method “onActionPerformed( ),” which class/interface contains the above method? a. The Listener interface b. The Listener class c. The Listenable class d. Both the Listener interface and the Listener class ____ 35. The following notation “anOrd:Order” can be interpreted as which of the following? a. Order is a class. anOrd is the identifier of an object in the class b. Order is an object. anOrd is the controller for that object c. Order is a class. anOrd is an object in that class d. Order is an object. anOrd is the reference to that object Completion Complete each statement. 36. A detailed sequence diagram uses all the same elements as a system sequence diagram (SSD), except that the ____________________ object is replaced by all of the internal objects and messages within the system. 37. ____________________ are vertical rectangles in a sequence diagram that indicate when an object is executing a method. 38. In a communication diagram, a(n) ____________________ is used to show that two items share a message. 39. Standard design techniques and templates that are recognized as good practice are called ____________________. 40. Use case ____________________ is the process of detail design for a particular use case by determining what objects collaborate and the messages they send to each other to carry out the use case. 41. The ____________________ layer contains the user interface classes. 42. A type of interaction diagram that does not have activation lifelines is called a(n) ____________________ diagram. 43. The ____________________ pattern can be used to connect two disparate systems. 44. The ____________________ pattern is used to instantiate objects as a service. 45. The layer used to read the database is called the ____________________ layer. Essay 46. How have the differences between programming languages and database languages driven the trend to a multilayer design? 47. What considerations should be taken into account when choosing the type of interaction diagram for a system design model? 48. Discuss some guidelines to follow when performing preliminary sequence diagram development.