M
Mize-ze
I have an immutable object that needs to hold (Among the rest) two
"Object" objects
for all the mutable objects my object holds I create a "defensive
copy" but what can I do with the "Object" objects? can I somehow clone
them so they can't be changed from outside the object?
BTW: I can't know what is the type of the Object before run-time...
(that's way it is an "Object")
Thanks.
"Object" objects
for all the mutable objects my object holds I create a "defensive
copy" but what can I do with the "Object" objects? can I somehow clone
them so they can't be changed from outside the object?
BTW: I can't know what is the type of the Object before run-time...
(that's way it is an "Object")
Thanks.