Originally posted by Shiva Shankar:
what is synthetic field (of the inner class)?
A synthetic field is a field that is introduced by the compiler and only exists in the byte code, not in the source code. I think there even is a synthetic flag in the byte code that is set for those fields, but I'm not sure about the details.
Synthetic members are necessary because at the byte code level, there are only top level classes - the JVM doesn't know about inner, nested or anonymous classes. The compiler has to use some tricks to implement the special access rules that apply to those concepts at the source code level.
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus