[ajug-members] correct interface programming

mcdaniel 521 at ofig.org
Thu Jul 24 18:15:56 EDT 2008


one of my questions is:

if i program to an interface, i do not have to worry about the number of 
interfaces that are implemented and methods used in those interfaces, do i?

barclay

Gabsaga Tata wrote:
> Not clear what your question is about but are you trying to say that 
> if you extend some class you don't have a contract to implement the 
> methods of the super class but if you implement some class you have a 
> contract to implement the methods of that class? Well, if you extend 
> an abstract class that has all abstract methods then you have a 
> contract to implement all the methods of that abstract class.
>  
> Gabsaga
>
>     -----Original Message-----
>     *From:* 521 [mailto:521 at ofig.org]
>     *Sent:* Thursday, July 24, 2008 03:43 PM
>     *To:* ajug-members at ajug.org
>     *Subject:* [ajug-members] correct interface programming
>
>     am i saying this correctly?, that which is below...  -barclay {{{
>     if i program to an interface, i do not have to worry about the
>     number of interfaces that are implemented, do i?  but do i not
>     have to use all methods in an implemented interface?  i do have
>     to- it's a contract. correct? and because you can only extend one
>     class, you have no contract there. correct?  can someone see what
>     my question is? a tree; a tree can grow, a tree can provide shade;
>     and a tree can provide lumber for table-tennis. so my tree class
>     is designed... then if i am implementing a 'tree'- it depends on
>     which implementation i use thus have a contract to use certain
>     methods }}} _______________________________________________
>     ajug-members mailing list ajug-members at ajug.org
>     http://www.ajug.org/mailman/listinfo/ajug-members 
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> ajug-members mailing list
> ajug-members at ajug.org
> http://www.ajug.org/mailman/listinfo/ajug-members
>   



More information about the ajug-members mailing list