public function hasMethodByName($name)
    {
        foreach ($this->methods as $method) {
            if ($method->getName() == $name) {
                return true;
            }
        }

        return false;
    }
public function hasMethodByName($name)
    {
        foreach ($this->methods as $method) {
            if ($method->getName() == $name) {
                return true;
            }
        }

        return false;
    }
public function hasMethodByName ( $ name ) { foreach ( $ this -> methods as $ method ) { if ( $ method -> getName ( ) == $ name ) { return true ; } } return false ; }
Returns if exists a method by name.

@param string $name The method name.

@return bool If the method exists.

@api
Returns if exists a method by name .