MayaFlux 0.4.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ make_persistent_shared()

template<typename T , typename... Args>
std::shared_ptr< T > MayaFlux::make_persistent_shared ( Args &&...  args)

Construct a T in place, retain it for process lifetime, and return a shared handle.

Template Parameters
TType to construct.
ArgsConstructor argument types.
Parameters
argsForwarded to std::make_shared<T>.
Returns
Shared pointer to the newly constructed object.

Definition at line 75 of file Persist.hpp.

76{
77 auto obj = store(std::make_shared<T>(std::forward<Args>(args)...));
79 return obj;
80}
#define MF_LIVE_EXPOSE_AUTO(ptr)
Auto-expose variant that deduces the key prefix from the shared_ptr element type.
std::shared_ptr< T > store(std::shared_ptr< T > obj)
Transfer ownership of an existing object to the persistent store for process lifetime.
Definition Persist.hpp:28

References MF_LIVE_EXPOSE_AUTO, and store().

+ Here is the call graph for this function: