-
Notifications
You must be signed in to change notification settings - Fork 11.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[5.3] Added Container::getFactory()
method
#15414
Conversation
bea3565
to
d819bb5
Compare
Container::getFactory()
methodContainer::getFactory()
method
Adding a method to an interface is a major breaking change. Please send to 5.4. |
@GrahamCampbell I can drop the interface change here and add the BC in 5.4. |
@GrahamCampbell dude, can't you wait 2 minutes before closing, so I can respond? |
This doesn't avoid the fact that this interface would really need to be added to the contract. It's a bit naught to add something and not add it to the interface. There's also an issue with the phpdoc which I didn't mention originally because it would have been even more inflammatory. |
|
||
/** | ||
* Get a closure to resolve the given type from the container. | ||
* The given closure will have an optional [array $parameters] parameter |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add the missing newline here.
I seem unable to re-open this PR. |
It's a duplicate of #15415 |
This would allow
Closure
factories to be easily made at entry point level, without having to injectContainer
where only a single factory method is required.