PHPMD\Node\MethodNode::isDeclaration PHP Метод

isDeclaration() публичный Метод

Otherwise this method will return false.
С версии: 1.2.1
public isDeclaration ( ) : boolean
Результат boolean
    public function isDeclaration()
    {
        if ($this->isPrivate()) {
            return true;
        }
        $methodName = strtolower($this->getName());
        $parentNode = $this->getNode()->getParent();
        foreach ($parentNode->getInterfaces() as $parentType) {
            $methods = $parentType->getAllMethods();
            if (isset($methods[$methodName])) {
                return false;
            }
        }
        if (is_object($parentType = $parentNode->getParentClass())) {
            $methods = $parentType->getAllMethods();
            if (isset($methods[$methodName])) {
                return false;
            }
        }
        return true;
    }