according to the book a method local inner class object cannot use local variable of the method unless they are marked final.
but in the code above I can access the local variable from both the places 1&2.
Local means the variables which belongs to outer class and are local to that particular method.
Think : - If you are not allowed to access the local members of your own local class then what is the use of variables in that context?
pie. tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop