Rosetta
|
A vector1 which does a deep copy of its contents. More...
Classes | |
class | utility::deep_copy_vector1< T > |
Namespaces | |
utility | |
unresizable vector whose size is known at compile time, which may be allocated on the stack, and which indexes from 0. | |
A vector1 which does a deep copy of its contents.
See utility/pointer/deep_copy.hh for more information about the deep copy framwork.
One limitation of the DeepCopyOP framework is that it doesn't work well in containers. Which means if you have a vector1< MyClassOP > that you want to deep copy, well, things don't work so well. This class attempts to fix that issue, by providing a vector1 class which is deep copied by default when the containing class is default copied.
Like the DeepCopyOP, this class should only be used for member variables. Don't pass it around. It should freely convert into a vector1 reference if you need to pass around a reference to it.
The other thing to note is that this class only really makes sense for OP contents. If you're containing by value (instead of by OP), the default semantics of vector1 is what you want.