Implementing a configurable factory
- by Decko
I'm having difficulties finding out how to implement a 'configurable' behavior in a factory class in PHP.
I've got at class, which takes another class as an argument in its constructor.
The argument class could take a number of arguments in its constructor. An instance of my main class could look something like this
$instance = new MyClass(new…