• Post Reply Bookmark Topic Watch Topic
  • New Topic

Why a final variable should be inside a class which declared inside a method ?.can you please share  RSS feed

 
jacob deiter
Ranch Hand
Posts: 587
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why a variable should be final to use inside a class which declared inside a method ?.
can you please share the reason why it is so?

If a class declared inside a method as follow



 
Stephan van Hulst
Saloon Keeper
Posts: 7817
142
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Take a look here:
http://www.coderanch.com/t/524522/java-programmer-SCJP/certification/Special-treatment-final-vaiables-method
 
jacob deiter
Ranch Hand
Posts: 587
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HI Stephan van Hulst

thanks ,i got the idea


I want to know all stuff in java like this ,is there any books or website ? ,i do not want programming idea like inheritance ,polymorphism,....etc.

I want to know beyond usual programming .
 
Buddhika Mawella
Ranch Hand
Posts: 40
Eclipse IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks friends. I also had the same problem. Now that was solved.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!