I would like to create in mixin classthat would pass the classfactory method to the final class of a particular type through several levels of inheritance. More specifically, I would like the factory method to create a new instance of the actual object, which it is called as a member.
So, the class "factory" is inherited by the class A, the class is Ainherited by the class B, I would like to find a way to make B::create()and create an instance B. As far as I can tell, this eliminates the use of a template with a type in the class A, as it B::create()will then create an instance A.
source
share