Is there a way in PHP to find out what object called what method in another object.
Exmaple:
class Foo { public function __construct() { $bar
You can probably achieve this with a debug backtrace, though this seems kind of hackish.
Your alternative option is to pass a parameter to that class and tell it where it is being called from, when you instantiate the class from within another.