• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Abstract method local inner classes help

 
Terry Rickson
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Take a look at this code.



I know the code won't compile because the method local inner class has been marked abstract but how would i be able to the inner class. Please somebody help!

Thanks in advance
 
Terry Rickson
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the above question was mean't to say how would i be able to use the inner class?

code example would be great
 
vidya sagar
Ranch Hand
Posts: 580
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Terry

If you want to create object for Inner class, it should be created only within that outermethod()(iff it should not be abstract)
 
vidya sagar
Ranch Hand
Posts: 580
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here ur wishes

 
Terry Rickson
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Vidya,

I knew that anyway but was'nt sure why method local inner classes could be marked abstract.

Thanks again!
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic