SOFTWARE ENGINEERING

SOFTWARE DESIGN

DESIGN PATTERNS

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
In the Prototype pattern, an object that supports cloning is called a ____
A
clone
B
prototype
C
client
D
dispose
Explanation: 

Detailed explanation-1: -An object that supports cloning is called a prototype. When your objects have dozens of fields and hundreds of possible configurations, cloning them might serve as an alternative to subclassing. Pre-built prototypes can be an alternative to subclassing.

Detailed explanation-2: -The mitotic division of a cell-resulting in two identical cells-is an example of a prototype that plays an active role in copying itself and thus, demonstrates the Prototype pattern. When a cell splits, two cells of identical genotype result. In other words, the cell clones itself.

Detailed explanation-3: -The prototype pattern belongs to the creational design patterns category and is used to create a clone of an object. Creational design patterns are concerned with object creation and managing the object creation process in your application.

There is 1 question to complete.