Re: [ljc] Re: Defender Methods

From: Abraham Marín P.
Sent on: Monday, August 20, 2012 2:51 PM
Doesn't that defeat the very purpose of single class inheritance? It sounds like a hack to have multiple class inheritance: If I do interfaces where all methods are defender methods then I can mock multiple class inheritance.

I'm just trying to find a scenario where this could be useful.

Thanks,

On 20 Aug 2012, at 19:58, Kevin Wright <[address removed]> wrote:



On 20 August[masked]:45, Abraham Marín Pérez <[address removed]> wrote:
This might be a silly question but... What's the difference between an interface with a default method and an abstract class with an implementation for that method?


Java has multiple interface inheritance, but single class inheritance.  You could, potentially, inherit defender methods from multiple parents.




--
Please Note: If you hit "REPLY", your message will be sent to everyone on this mailing list ([address removed])
This message was sent by Kevin Wright ([address removed]) from LJC - London Java Community.
To learn more about Kevin Wright, visit his/her member profile
Set my mailing list to email me As they are sent | In one daily email | Don't send me mailing list messages

Meetup, PO Box 4668 #37895 New York, New York[masked] | [address removed]

Our Sponsors

  • Our Blog

    Read the latest news from the LJC

  • RecWorks Ltd

    Fixing Tech Recruitment using the Power of Community

  • jClarity

    Java/JVM Performance Analysis Tools & mentoring for Java related matters

  • LJC Aggrity

    Our LJC Aggrity site contains blog posts from our members

  • LJC Book Club

    Our Book club with book reviews from our members

  • Devoxx UK

    Java Community Conference, in collaboration with the LJC 12/13 Jun 14

  • SkillsMatter

    "Host, help organise, promote, film many of our meetings."

  • Packt Publishing

    A publishing company specializing on specific technologies and solutions

  • Java.Net

    We are an official Java User Group recognised by Oracle's JUG program

  • JRebel

    Free 3 month J-Rebel license.

  • O'Reilly

    40% discount on printed books and 50% on e-books.

People in this
Meetup are also in:

Sign up

Meetup members, Log in

By clicking "Sign up" or "Sign up using Facebook", you confirm that you accept our Terms of Service & Privacy Policy