Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

K&B Doubt Inner Classes  RSS feed

 
Sasha Ruehmkorf
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
page 668
An anonymous inner class can extend exactly one class or implement exactly one interface

From JLS:
A class necessarily implements all the interfaces that its direct superclasses and direct superinterfaces do.

[ May 30, 2007: Message edited by: Sasha Ruehmkorf ]
 
John Stone
Ranch Hand
Posts: 332
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

this is meant as: extends or implements _directly_ only one class or interface
 
Sasha Ruehmkorf
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yep, I think so. But as it is the answer to a question in the selftest, where "can implement multiple interfaces" was considered wrong, I thought I should report it.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!