PascalCasing - Pascal Case

Return to CamelCase, Hungarian notation, Programming topics

The practice of marking all word boundaries in long identifiers (such asThisIsASampleVariable)(including the first letter of the identifier) with uppercase. Constrasts with camelCasing, in which the firstcharacteroftheidentifierisleftin lowercase (thisIsASampleVariable), and with the traditional C style of short all-lower-casenameswith internal word breaks marked by an underscore (sample_var).

Where these terms are used, they usually go with advice to use PascalCasing for public interfaces and camelCasing for private ones. They may have originated at Microsoft, but are in more general use in ECMA standards, among Java programmers, and elsewhere.

Fair Use Source: This article is based, in whole or in part, on entry or entries in the Jargon File.

Snippet from Wikipedia: Camel case

Camel case (sometimes stylized autologically as camelCase or CamelCase, also known as camel caps or more formally as medial capitals) is the practice of writing phrases without spaces or punctuation and with capitalized words. The format indicates the first word starting with either case, then the following words having an initial uppercase letter. Common examples include YouTube, PowerPoint, HarperCollins, FedEx, iPhone, eBay, and LaGuardia. Camel case is often used as a naming convention in computer programming. It is also sometimes used in online usernames such as JohnSmith, and to make multi-word domain names more legible, for example in promoting EasyWidgetCompany.com. In fact, WikiWikiWeb, an ancestor of Wikipedia, is written in camel case.

The more specific terms Pascal case and upper camel case refer to a joined phrase where the first letter of each word is capitalized, including the initial letter of the first word. Similarly, lower camel case (also known as dromedary case) requires an initial lowercase letter. Some people and organizations, notably Microsoft, use the term camel case only for lower camel case, designating Pascal case for the upper camel case. Some programming styles prefer camel case with the first letter capitalized, others not. For clarity, this article leaves the definition of camel case ambiguous with respect to capitalization, and uses the more specific terms when necessary.

Camel case is distinct from several other styles: title case, which capitalizes all words but retains the spaces between them; Tall Man lettering, which uses capitals to emphasize the differences between similar-looking product names such as predniSONE and predniSOLONE; and snake case, which uses underscores interspersed with lowercase letters (sometimes with the first letter capitalized). A combination of snake and camel case (identifiers Written_Like_This) is recommended in the Ada 95 style guide.