void (@NonNls final String methodName, String className, final PsiType migrationType) { final RulesProvider provider = new RulesProvider() { @Override public PsiType migrationType(PsiElement context) { return migrationType; } @Override public PsiElement victim(PsiClass aClass) { return aClass.findMethodsByName(methodName, false)[0].getParameterList().getParameters()[0]; } }; start(provider, className); }