Final (Java): Difference between revisions

Content deleted Content added
Line 32:
 
Unlike the value of a [[constant (computer science)|constant]], the value of a final variable is not necessarily known at compile time.
 
Instances of inner classes can access fields of the enclosing instance only if they are final.
 
Example: