fup fabric
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
#pragma once
|
||||
#include <memory>
|
||||
|
||||
template <typename T>
|
||||
class FabricMixin {
|
||||
public:
|
||||
template <typename... Args>
|
||||
static std::shared_ptr<T> create(Args&&... args) {
|
||||
return std::shared_ptr<T>(new T(std::forward<Args>(args)...));
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user