Prototype
Copy an existing instance instead of constructing a new one. data class and copy() cover the shallow case outright, so the interesting question is what happens when the copy has to be deep.
Structure
classDiagram
class Prototype {
<<interface>>
+clone() Prototype
}
class ConcreteA {
-field
+clone() Prototype
}
class ConcreteB {
-field
+clone() Prototype
}
Prototype <|.. ConcreteA
Prototype <|.. ConcreteB