PsiReference @NotNull [] getDefaultReferences(@NotNull PsiReferenceService.Hints hints) {
    if (hints.offsetInElement != null) {
      XmlElement nameElement = myAttribute.getNameElement();
      if (nameElement == null || hints.offsetInElement > nameElement.getStartOffsetInParent() + nameElement.getTextLength()) {
        return PsiReference.EMPTY_ARRAY;
      }
    }

    PsiReference[] referencesFromProviders = ReferenceProvidersRegistry.getReferencesFromProviders(myAttribute, hints);
    PsiReference[] refs;
    if (myAttribute.isNamespaceDeclaration()) {
      refs = new PsiReference[referencesFromProviders.length + 1];
      final String localName = myAttribute.getLocalName();
      final String prefix = XmlUtil.findPrefixByQualifiedName(myAttribute.getName());
      final TextRange range =
        prefix.isEmpty() ? TextRange.from(myAttribute.getName().length(), 0) : TextRange.from(prefix.length() + 1, localName.length());
      refs[0] = new SchemaPrefixReference(myAttribute, range, localName, null);
    }
    else {
      final String prefix = myAttribute.getNamespacePrefix();
      if (!prefix.isEmpty() && !myAttribute.getLocalName().isEmpty()) {
        refs = new PsiReference[referencesFromProviders.length + 2];
        XmlElement nameElement = myAttribute.getNameElement();
        TextRange prefixRange = TextRange.from(nameElement == null ? 0 : nameElement.getStartOffsetInParent(), prefix.length());
        refs[0] = new SchemaPrefixReference(myAttribute, prefixRange, prefix, null);
        refs[1] = new XmlAttributeReference(myAttribute);
      }
      else {
        refs = new PsiReference[referencesFromProviders.length + 1];
        refs[0] = new XmlAttributeReference(myAttribute);
      }
    }
    System.arraycopy(referencesFromProviders, 0, refs, refs.length - referencesFromProviders.length, referencesFromProviders.length);
    return refs;
  }
PsiReference @NotNull [] getDefaultReferences(@NotNull PsiReferenceService.Hints hints)