adplus-dvertising
frame-decoration

Question

Which of the following is true about factory method?

a.

A factory method is a non-constructor operation that creates and returns class instances

b.

Factory methods are widely used in mid-level design patterns and in object-oriented programming in general

c.

Factory methods create new instances using constructors or cloning, so they do not rely on any special technique for class instantiation

d.

All of the mentioned

Answer: (d).All of the mentioned

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. Which of the following is true about factory method?

Similar Questions

Discover Related MCQs

Q. When a generator assumes responsibility for product object creation in a factory method,which of the following capabilities become available?

Q. Which are the several reasons for using generator patterns?

Q. The Factory patterns decouple clients from products by taking advantage of interfaces in two ways?

Q. What are the types of factory pattern?

Q. Which class that can have only one instance?

Q. What are the drawbacks for singleton class?

Q. Which of the following are true for the singleton class?

Q. Which of the following are true for prototype pattern?

Q. Any class using the built-in cloning mechanism is supposed to do which of the following?

Q. Which of the following are correct for copy constructor?

Q. Which of the following pattern has Step up phase as its activity?

Q. What happen in the operational phase of Reactor pattern?

Q. The reactor patterns provide a good model for event-driven portions of a program for which of the following reasons?

Q. Which of the following are consequences for command pattern?

Q. Which among these are advantages for Function Class?

Q. Which of the several aspects of the Command pattern may be varied or elaborated to help achieve particular design goals

Q. Which of the following are the consequences for Command pattern?

Q. Which of the following is incorrect?

Q. Which of the following are true?

Q. Which of the following is incorrect?