Copy-Constructor

Prototype

A diagram editor has to duplicate shapes it only knows as Shape. Learn how Prototype lets each shape copy itself, why a shallow copy of a group shares its children, and when not to copy at all.

November 26, 20269 minutes