The `__call` method in the `yii\base\Component` class in PHP is a magic method that gets called when an inaccessible method is called on an object. It allows objects to dynamically handle method calls that are not explicitly defined in the class. The `__call` method accepts two parameters: the name of the method being called and an array of arguments passed to the method. By overriding this method in a subclass of `Component`, developers can customize the behavior of the object when an unknown method is invoked. This can be useful for implementing dynamic methods or delegating method calls to other objects within the class hierarchy.
PHP yii\base Component::__call - 22 examples found. These are the top rated real world PHP examples of yii\base\Component::__call extracted from open source projects. You can rate examples to help us improve the quality of examples.
This method will check if any attached behavior has
the named method and will execute it if available.
Do not call this method directly as it is a PHP magic method that
will be implicitly called when an unknown method is being invoked.