// @TODO: namespace not supported
@Override
        public boolean isReferenceTo(PsiElement psiElement) {
            if(!(psiElement instanceof PhpNamedElement)) {
                return false;
            }
            String text = getElement().getText();
            if(StringUtils.isBlank(text)) {
                return false;
            }
            PsiElement namespace = element.getPrevSibling();
            if(PhpPsiUtil.isOfType(namespace, PhpDocTokenTypes.DOC_NAMESPACE)) {
                // @TODO: namespace not supported
                return false;
            }
            String classByContext = PhpElementsUtil.getFqnForClassNameByContext(element, text);
            if(classByContext != null) {
                return StringUtils.stripStart(((PhpNamedElement) psiElement).getFQN(), "\\")
                    .equalsIgnoreCase(StringUtils.stripStart(fqn, "\\"));
            }
            return false;
        }
PsiElement namespace = element.getPrevSibling();
if(PhpPsiUtil.isOfType(namespace, PhpDocTokenTypes.DOC_NAMESPACE)) {
// @TODO: namespace not supported
return false;
}
public boolean isReferenceTo(PsiElement psiElement) {
if(!(psiElement instanceof PhpNamedElement)) {
return false;
}
String text = getElement().getText();
if(StringUtils.isBlank(text)) {
return false;
}
PsiElement namespace = element.getPrevSibling();
if(PhpPsiUtil.isOfType(namespace, PhpDocTokenTypes.DOC_NAMESPACE)) {
// @TODO: namespace not supported
return false;
}
String classByContext = PhpElementsUtil.getFqnForClassNameByContext(element, text);
if(classByContext != null) {
return StringUtils.stripStart(((PhpNamedElement) psiElement).getFQN(), "\\")
.equalsIgnoreCase(StringUtils.stripStart(fqn, "\\"));
}
return false;
}
@Override
public boolean isReferenceTo(PsiElement psiElement) {
if(!(psiElement instanceof PhpNamedElement)) {
return false;
}
String text = getElement().getText();
if(StringUtils.isBlank(text)) {
return false;
}
PsiElement namespace = element.getPrevSibling();
if(PhpPsiUtil.isOfType(namespace, PhpDocTokenTypes.DOC_NAMESPACE)) {
// @TODO: namespace not supported
return false;
}
String classByContext = PhpElementsUtil.getFqnForClassNameByContext(element, text);
if(classByContext != null) {
return StringUtils.stripStart(((PhpNamedElement) psiElement).getFQN(), "\\")
.equalsIgnoreCase(StringUtils.stripStart(fqn, "\\"));
}
return false;
}