[ACCEPTED]-Naming conventions: Guidelines for verbs/nouns and english grammar usage-naming-conventions

Accepted answer
Score: 22

Look at the MSDN articles for naming guidelines. In short:

  • Use nouns for class names and property names (it's obvious)
  • For interface names, start with I and use nouns and/or adjectives to describe behavior
  • Use verbs for method names to describe action

For 1 your example - IGroupableItem.

Score: 9

Interfaces are things a class is capable 5 of doing. Not what it is, but what it can 4 do.


Other names describe what things are or 3 are too vague to be useful.

Specifically, "IDataEntity" is 2 largely meaningless. After all, everything's 1 a data entity.

Score: 4

MSDN has an article just on Interface Naming Guidelines that may help 4 you out. If you want the naming conventions 3 of stuff other than interfaces, along with 2 many other naming and design guidelines, you 1 can find that all on MSDN, too.

Score: 1

This is the same material as Spodi's answer, but 2 MSDN's Design Guidelines for Class Library Developers are mostly excellent, covering naming and 1 much, much more.

Score: 1

There is nice article Making Wrong Code Look Wrong by Joel Spolsky. It 2 tells about not so popular, but very handy 1 naming convention.

Score: 1

As well as the MSDN Guidelines, there is 3 a C# Coding Standards document from IDesign by 2 Juval Lowy that is quite helpful (don't 1 know if/how much this differs from MSDN).

C# Coding Standards

Score: 0

For verbs in function (and etc.) names, it's 3 common to use the original form of the verb, like 2 Handle, ExecuteQuery, or IsAny, ...

Some less common usage of verbs 1 makes it singular with s/es, like ProducesResponseType (MS Docs).

More Related questions