I have a simple question:
In Java Compiler, Which type of method or variables can be defined as identifier (ID) or Keyword (reserved word)?
For following example, ID
The Java keywords are part of the language, and are documented in the Java Language. You cannot use a keyword as an identifier . const
and goto
are reserved keywords, but not implemented. true
, false
, and null
are literals; you still cannot use them as identifiers but they are not keywords.
From the linked Java tutorial, the keywords are
1not used
2added in 1.2
3added in 1.4
4added in 5.0