C# 构造函数命名约定

C# constructors naming convention

我是 C# 的新手,我见过使用构造函数的不同风格。但是有些教程已经有一年多的历史了。今天的最佳做法是什么?

class Book
{
    //Class properties
    private string title;
    private int pages;

变体 1:

    public Book(string title, int pages)
    {
        this.title = title;
        this.pages = pages;
    }

变体 2:

    public Book(string _title, int _pages)
    {
        title = _title;
        pages = _pages;
    }

变体 3:

    public Book(string bookTitle, int numberOfPages)
    {
        title = bookTitle;
        pages = numberOfPages;
    }
}

这是最流行的方式

class Book
{
    //Class properties
    private string _title;
    private int _pages;

    public Book(string title, int pages)
    {
        _title = title;
        _pages = pages;
    }
}