identifier ::= letter ('_' | letter | digit)\stern .
letter ::= 'a' | 'A' | 'b' | 'B' | 'c' | 'C' | 'd' | 'D' |
'e' | 'E' | 'f' | 'F' | 'g' | 'G' | 'h' | 'H' |
'i' | 'I' | 'j' | 'J' | 'k' | 'K' | 'l' | 'L' |
'm' | 'M' | 'n' | 'N' | 'o' | 'O' | 'p' | 'P' |
'q' | 'Q' | 'r' | 'R' | 's' | 'S' | 't' | 'T' |
'u' | 'U' | 'v' | 'V' | 'w' | 'W' | 'x' | 'X' |
'y' | 'Y' | 'z' | 'Z' | special_letter .
digit ::= '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' .
An identifier is a freely chosen representation for an entity,
i.e. a class, a feature of a class or a local entity within
a method. The meaning of an identifier within a program is prescribed
by defining occurrences of the identifier. All other appearances
of the identifier are called applied occurrences.
Example: MAIN_CLASS attribute_name method_name local
Hint: Implementations may require that identifiers used as class names
do not contain lower case letters.
Hint: Within an external class the syntax may be adapted to suit the
conventions of other programming languages.
Hint: Which characters are considered special letters is
implementation dependent. E.g., when using ISO 8859-1
encoding then the sedecimal values 0xC0-0xD6, 0xD8-0xF6, 0xF8-0xFF
print as letters of certain European alphabets and are considered
special letters. Special letters should not occur in portable
classes.
Letters are case sensitive: constant is a reserved keyword whereas
CONST is a freely chosen identifier.