Checks if this node has a suppressed annotation for the given rule
instance.
public hasSuppressWarningsAnnotationFor ( PHPMD\Rule $rule ) : boolean | ||
$rule | PHPMD\Rule | |
return | boolean |
/** * Returns <b>true</b> when the given method should be used for this rule's * analysis. * * @param \PHPMD\Node\ClassNode $class * @param \PHPMD\Node\MethodNode $method * @return boolean */ private function acceptMethod(ClassNode $class, MethodNode $method) { return $method->isPrivate() && false === $method->hasSuppressWarningsAnnotationFor($this) && strcasecmp($method->getImage(), $class->getImage()) !== 0 && strcasecmp($method->getImage(), '__construct') !== 0 && strcasecmp($method->getImage(), '__destruct') !== 0 && strcasecmp($method->getImage(), '__clone') !== 0; }