Java identifiers [JLS14:3.8].
Java identifiers are sequences of characters that, among other things, must differ from Java keywords. Since, as discussed in the topic on keywords, there are non-restricted and restricted Java keywords, correspondingly there are two kinds of Java identifiers. One kind excludes only non-restricted keywords: these identifiers are usable in most contexts. The other kind excludes restricted keywords as well (with a slight exception; see midentifier): these identifiers are usable in certain module-related contexts.
Here we also formalize Java type identifiers [JLS14:3.8], which are slightly more restricted identifiers.