← BYTES
Design Patterns·Starter·Ref: 17.1.14

What does the Prototype pattern let you do?

Have a question about this video? Mention reference 17.1.14 when you contact us.

a.Permanently prevent an object from ever being modified
b.Create a new object by copying ('cloning') an existing object, rather than constructing it from scratch
c.Automatically delete unused objects from memory
d.Convert one object's data type into another's
Prototype creates new objects by cloning an existing, pre-configured 'prototype' instance instead of constructing a fresh one via its constructor each time -- useful when creating an object from scratch is expensive, or when you want new objects to start pre-configured similarly to an existing one.

Find this on YouTube & Instagram

Every BYTES video is tagged with its reference number and topic — search any of these on YouTube or Instagram to find this one:

#BYTES#BYTES17114#DesignPatterns