private static @Nullable PsiType getSetterArgumentType(@NotNull PsiMethod method) {
    return CachedValuesManager.getCachedValue(method, () -> {
      final PsiParameter[] parameters = method.getParameterList().getParameters();
      final boolean isStatic = method.hasModifierProperty(PsiModifier.STATIC);
      if (isStatic && parameters.length == 2 || !isStatic && parameters.length == 1) {
        final PsiType argumentType = eraseFreeTypeParameters(parameters[parameters.length - 1].getType(), method);
        return CachedValueProvider.Result.create(argumentType, PsiModificationTracker.MODIFICATION_COUNT);
      }
      return CachedValueProvider.Result.create(null, PsiModificationTracker.MODIFICATION_COUNT);
    });
  }
private static @Nullable PsiType getSetterArgumentType(@NotNull PsiMethod method)