Matias
unread,Apr 18, 2011, 9:18:43 AM4/18/11Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Symfony Components
Hi,
I read a few posts about optional dependencies, but couldn't find
anything conclusive.
I have a pretty big app, and want some objects to be optional
(including loggers, and profilers).
Now in production, I want to avoid creating loggers and profilers,
pass them around, and simply disable them, because I want to avoid the
overhead of creating objects I don't intend to use.
I'm looking for a solution that would be like:
addOptionalArgument('serviceNameImDependingOn', [...]);
or
addOptionalMethodCall('serviceNameImDependingOn', [...]);
Is there something like this?
Thanks in advance.