Skip to content
Aaron edited this page Jan 21, 2018 · 5 revisions

Documentation issues

ReSharper will tell you to document everything. However, if you are properly naming and designing your objects and members, such comment blocks will often be nothing but redundant, especially if you stick with the ones it generates automatically. E.g.

    /// <summary>
    /// The Account Id.
    /// </summary>
    public long AccountId { get; set; }

Really?

I'd recommend going into your ReSharper/StyleCop settings and turning off the most of the items in the Documentation area. This is also consistent with the recommendations provided by Robert C. Martin In Clean Code.

Parameter can be of type 'IEnumerable'

ReSharper's suggestion that a List or IList can be an IEnumerable instead may be a good idea to implement. Or it might not be. With objects that implement deferred execution (such as LinqToSql), you might end up with your database connections opened and closed at unexpected times if you refactor an entire code flow to keep a result set as IEnumerable until the very last minute. Explicitly using IList or ICollection to pass a result set around can help you enforce query execution in the data layer, but make sure your team members know about this, or they might break things when they refactor.