public function __invoke($object) { if (!is_object($object)) { return false; } foreach ($this->methods as $method) { if (!method_exists($object, $method)) { return false; } } return true; }