I found a bunch of questions involving __call
and things you can do with it, but nothing about what __call
actually is.
PHP objects have a number of Magic Methods. The most well-known being __construct
.
__call
is a magic method which gets called whenever you try and call a method that doesn't exist. It's sort of a "catch-all" for methods.
The technical term is "Method Overloading".
So when $cb->statuses_homeTimeline()
is called, if that method does not exist, it will instead call
$cb->__call("statuses_homeTimeline",array())