libhext: C++ Library Documentation
1.0.12-3ea013c
|
Curiously recurring template pattern that extends a base class to provide a virtual method Cloneable::clone(). More...
Public Member Functions | |
virtual std::unique_ptr< Base > | clone () const override |
Clones objects of template type Derived and returns an owning pointer to the newly allocated Base. More... | |
Curiously recurring template pattern that extends a base class to provide a virtual method Cloneable::clone().
Derived | A subclass of Cloneable that is copy constructible. |
Base | The base class that shall be extended. |
Definition at line 36 of file Cloneable.h.
|
inlineoverridevirtual |
Clones objects of template type Derived and returns an owning pointer to the newly allocated Base.
Fails at compile time if template parameter Base is not a base of template parameter Derived or if template parameter Derived is not copy constructible.
Definition at line 45 of file Cloneable.h.