Naming conventions

The following table summarizes the capitalization rules and provides examples for the different types of identifiers.

Identifier Case Example
Class Pascal AppDomain
Enum type Pascal ErrorLevel
Enum values Pascal FatalError
Event Pascal ValueChange
Exception class Pascal WebException
Note   Always ends with the suffix Exception.
Read-only Static field Pascal RedValue
Interface Pascal IDisposable
Note   Always begins with the prefix I.
Method Pascal ToString
Namespace Pascal System.Drawing
Parameter Camel typeName
Property Pascal BackColor
Protected instance field Camel redValue
Note   Rarely used. A property is preferable to using a protected instance field.
Public instance field Pascal RedValue

 

Last edited May 29, 2014 at 2:00 PM by Ra3aHa5nain, version 7