public static ConflictResolutionPolicy showDialog(String targetMethodName) {
        int exit = Messages.showYesNoCancelDialog(
          JavaBundle.message("generate.tostring.method.already.exists.dialog.me=ssage", targetMethodName),
          JavaBundle.message("generate.tostring.method.already.exists.dialog.title"), Messages.getQuestionIcon());
        if (exit == Messages.CANCEL) {
            return CancelPolicy.getInstance();
        }
        if (exit == Messages.YES) {
            return ReplacePolicy.getInstance();
        }
        if (exit == Messages.NO) {
            return DuplicatePolicy.getInstance();
        }

        throw new IllegalArgumentException("exit code [" + exit + "] from YesNoCancelDialog not supported");
    }
public static ConflictResolutionPolicy showDialog(String targetMethodName)