private static boolean isCompatible(@NotNull ReflectiveType requiredType, @NotNull PsiType actualType, boolean isExact) {
    if (isExact) {
      return requiredType.isEqualTo(actualType);
    }
    return requiredType.isAssignableFrom(actualType) || actualType.isAssignableFrom(requiredType.getType());
  }
private static boolean isCompatible(@NotNull ReflectiveType requiredType, @NotNull PsiType actualType, boolean isExact)