Ada_Case

Ada_Case

Ada case is the capital pattern with underscore delimiter.

Known Literature

This php case conversion library calls this case “Ada”. 1

Ada’s style guide acturally describes this case as follows: 2

Use mixed case for all other identifiers, a capital letter beginning every word separated by underscores.

Example

Ada uses this case for most variables.

type Second_Of_Day      is range 0 .. 86_400;
type Noon_Relative_Time is (Before_Noon, After_Noon, High_Noon);

subtype Morning   is Second_Of_Day range 0 .. 86_400 / 2 - 1;
subtype Afternoon is Second_Of_Day range Morning'Last + 2 .. 86_400;

Current_Time := Second_Of_Day(Calendar.Seconds(Calendar.Clock));
if Current_Time in Morning then
   Time_Of_Day := Before_Noon;
elsif Current_Time in Afternoon then
   Time_Of_Day := After_Noon;
else
   Time_Of_Day := High_Noon;
end if;

2