package org.intellij.ibatis.provider;

import com.intellij.psi.PsiElement;
import com.intellij.psi.PsiReference;
import com.intellij.psi.impl.source.resolve.reference.PsiReferenceProvider;
import com.intellij.psi.impl.source.resolve.reference.ReferenceType;
import com.intellij.psi.scope.PsiScopeProcessor;
import org.jetbrains.annotations.NotNull;

/**
 * base reference
 */
public class BaseReferenceProvider implements PsiReferenceProvider {
    @NotNull public PsiReference[] getReferencesByElement(PsiElement psiElement) {
        return PsiReference.EMPTY_ARRAY;
    }

    @Deprecated
    @NotNull public PsiReference[] getReferencesByElement(PsiElement psiElement, ReferenceType referenceType) {
        return new PsiReference[0];
    }

    @NotNull
    @Deprecated
    public PsiReference[] getReferencesByString(String s, PsiElement psiElement, ReferenceType referenceType, int i) {
        return new PsiReference[0];  
    }

    public void handleEmptyContext(PsiScopeProcessor psiScopeProcessor, PsiElement psiElement) {

    }
}

@@ -138,38 +138,8 @@
 psi.
-impl.source.resolve.reference.
 PsiR
@@ -181,105 +181,30 @@
 lij.
-psi.impl.source.resolve.reference.ReferenceType;%0D%0Aimport com.intellij.psi.scope.PsiScopeProcessor
+util.ProcessingContext
 ;%0D%0Ai
@@ -269,16 +269,26 @@
 eference
+  provider
 %0D%0A */%0D%0Ap
@@ -325,17 +325,14 @@
 der 
-implement
+extend
 s Ps
@@ -357,32 +357,37 @@
  %7B%0D%0A    @NotNull
+%0D%0A   
  public PsiRefer
@@ -408,32 +408,41 @@
 rencesByElement(
+@NotNull 
 PsiElement psiEl
@@ -450,228 +450,108 @@
 ment
-) %7B%0D%0A        return PsiReference.EMPTY_ARRAY;%0D%0A    %7D%0D%0A%0D%0A    @Deprecated%0D%0A    @NotNull public PsiReference%5B%5D getReferencesByElement(PsiElement psiElement, ReferenceType referenceType) %7B%0D%0A        return new PsiReference%5B0%5D
+, @NotNull ProcessingContext processingContext) %7B%0D%0A        return getReferencesByElement(psiElement)
 ;%0D%0A 
@@ -576,25 +576,8 @@
 ll%0D%0A
-    @Deprecated%0D%0A
     
@@ -617,25 +617,16 @@
 esBy
-String(String s, 
+Element(
 PsiE
@@ -646,44 +646,8 @@
 ment
-, ReferenceType referenceType, int i
 ) %7B%0D
@@ -666,12 +666,8 @@
 urn 
-new 
 PsiR
@@ -678,130 +678,30 @@
 ence
-%5B0%5D;  %0D%0A    %7D%0D%0A%0D%0A    public void handleEmptyContext(PsiScopeProcessor psiScopeProcessor, PsiElement psiElement) %7B%0D%0A%0D%0A    %7D
+.EMPTY_ARRAY;%0D%0A    %7D%0D%0A
 %0D%0A%7D%0D

use new PsiReferenceProvider