× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.


  • Subject: Re: Understanding Implements
  • From: jamesl@xxxxxxxxxxx
  • Date: Wed, 21 Mar 2001 13:24:08 AST

Fellow programmers:

Please forgive the funky formatting; I'm using my ISP's
somewhat flaky web-mail 
interface again.

Interfaces represent a
compromise in the design of the Java language, between 
those who insist that
a true object-oriented language MUST have multiple 
inheritance, and those
who insist that a true object-oriented language MUST 
NEVER have multiple
inheritance.

They provide a form of purely abstract secondary inheritance:
purely abstract 
because in interface cannot contain any implemented methods,
any class 
implementing the interface is required to implement any methods
defined in the 
interface, and any instance of an implementing class is not
only considered an 
instance of the class and all its superclasses, but also
of the interface. It 
is strictly secondary inheritance because an interface
cannot be instantiated 
or subclassed (though it can be
sub-interfaced).

Thus a parameter can be typed to an interface, and a
variable can be both 
checked for whether it's an instance of the interface
and cast to that 
interface, with complete independence of what class the
object happens to be, 
so long as it implements the interface.

--
James
H. H. Lampert
Professional_Dilettante
http://www.hb.quik.com/jamesl



As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.