A directory of Objective Type Questions covering all the Computer Science subjects. Here you can access and discuss Multiple choice questions and answers for various compitative exams and interviews.

91. Which are the drawback for mediator pattern?
a. It may also increase collaborator cohesion
b. Forcing collaborator interaction through the mediator may compromise performance
c. All of the mentioned
d. None of the mentioned
View Answer Report Discuss Too Difficult!
Answer: (b).Forcing collaborator interaction through the mediator may compromise performance

92. Which of the following is consequence of mediator class?
a. They makes a sub-system easier for clients to use
b. Lowers the coupling between the client and the sub-system
c. Increase re-usability by adapting a sub-system’s interface to client needs
d. It encapsulates an interaction, making the interaction easier to change
View Answer Report Discuss Too Difficult!
Answer: (d).It encapsulates an interaction, making the interaction easier to change

93. Which of the following is true for Adapter pattern?
a. An adapter or wrapper is a component that provides a new interface for an existing component
b. An Adapter or Wrapper pattern is a broker pattern that provides a new interface for existing software so that it can be reused
c. Adaptation for reuse is an old technique that has been used since the beginning of software development
d. All of the mentioned
View Answer Report Discuss Too Difficult!
Answer: (d).All of the mentioned

94. The Adapter patterns provide object-oriented adapters in which of theses varieties?
a. One uses inheritance
b. one uses delegation
c. All of the mentioned
d. None of the mentioned
View Answer Report Discuss Too Difficult!
Answer: (c).All of the mentioned

95. A class (the adapter class) may be given a new interface by an adapter class in which of the two ways?
a. The adapter may subclass the adapter. The adapter can inherit adapter operations with appropriate semantics and pragmatics, override those with inappropriate semantics or pragmatics, and add operations needed for the new interface. This is the Class Adapter pattern
b. The adapter may hold a reference to the adapter and delegate must work to the adapter object. This approach is the Object Adapter pattern
c. All of the mentioned
d. None of the mentioned
View Answer Report Discuss Too Difficult!
Answer: (c).All of the mentioned

96. A class (the adapter class) may be given a new interface by an adapter class in which of these ways?
a. Class Adapter pattern
b. Object Adapter pattern
c. All of the mentioned
d. None of the mentioned
View Answer Report Discuss Too Difficult!
Answer: (c).All of the mentioned

97. Which of these states about Object Adapter pattern?
a. The adapter can inherit adapter operations with appropriate semantics and pragmatics, override those with inappropriate semantics or pragmatics, and add operations needed for the new interface
b. The adapter may hold a reference to the adapter and delegate must work to the adapter object
c. All of the mentioned
d. None of the mentioned
View Answer Report Discuss Too Difficult!
Answer: (b).The adapter may hold a reference to the adapter and delegate must work to the adapter object

98. Which of the following is true for proxy pattern?
a. Has exactly the same interface as the real object
b. Handles routine or illegitimate messages without accessing the real object
c. Delegates messages that it cannot handle to the real object
d. All of the mentioned
View Answer Report Discuss Too Difficult!
Answer: (d).All of the mentioned

99. Which of the following is not followed by proxy pattern?
a. virtual proxies
b. remote proxies
c. access proxies
d. none of the mentioned
View Answer Report Discuss Too Difficult!
Answer: (d).none of the mentioned

100. What are stand-ins for objects not yet created are called?
a. virtual proxies
b. remote proxies
c. access proxies
d. none of the mentioned
View Answer Report Discuss Too Difficult!
Answer: (a).virtual proxies