private static void reportErrorMessage(
    @NotNull String modelName,
    @NotNull Project project,
    @NotNull ModelBuilderContext context,
    @NotNull ModelBuilderService service,
    @NotNull Exception exception
  ) {
    @SuppressWarnings("deprecation")
    ErrorMessageBuilder builder = service.getErrorMessageBuilder(project, exception);
    if (builder != null) {
      context.getMessageReporter().reportMessage(project, builder.buildMessage());
    }
    else {
      service.reportErrorMessage(modelName, project, context, exception);
    }
  }
private static void reportErrorMessage(
    @NotNull String modelName,
    @NotNull Project project,
    @NotNull ModelBuilderContext context,
    @NotNull ModelBuilderService service,
    @NotNull Exception exception
  )