boost::openmethod::make_shared_virtual
Create a new object and return a shared_virtual_ptr to it.
Synopsis
template<
class Class,
class Registry = boost::openmethod::default_registry,
typename... T>
auto
make_shared_virtual(T&&... args);
Description
Create an object using std::make_shared, and return a shared_virtual_ptr pointing to it. Since the exact class of the object is known, the virtual_ptr is created using final_virtual_ptr.
Class is not required to be a polymorphic class.
Return Value
A shared_virtual_ptr<Class, Registry> pointing to a newly created object of type Class.
Template Parameters
| Name | Description |
|---|---|
Class |
The class of the object to create. |
Registry |
A |
T |
Types of the arguments to pass to the constructor of |
Parameters
| Name | Description |
|---|---|
args |
Arguments to pass to the constructor of |
Created with MrDocs