Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / October 2006

Tip: Looking for answers? Try searching our database.

Difference between Abstract class and interface

Thread view: 
vishist - 23 Oct 2006 14:54 GMT
Hi,
  Can you let me know the difference between Abstract class and
interface. I did research on the topic and found it helpful. Well, the
refined question I have is
1. Is there any difference between abstract class for which all the
methods are declared abstract and then an interface. I know that with
interface, multiple inhertiance can be achieved.
Can you please tell me in object tree/method invocation view.

thanks in advance
Raanan - 23 Oct 2006 16:26 GMT
Well,

I'm not an expert but if I remmber correctly..

the interface is only definitions of functions..
a new class can implements mulitiple interfaces...

an abstract class is like an unfinnished class... :) lets you implement
some of the functions by your self but some of the functions might be
already implemented and even private.
and I think you can use only abstarct class to father your new class.

Raanan,
http://www.infoservicesonline.com

> Hi,
>    Can you let me know the difference between Abstract class and
[quoted text clipped - 6 lines]
>
> thanks in advance
Tor Iver Wilhelmsen - 23 Oct 2006 16:40 GMT
>    Can you let me know the difference between Abstract class and
> interface.

An abstract class can contain method implementation, instance fields,
constructors and static methods. An interface cannot. An abstract
class is part of the single-inheritance chain, an interface is not.
impaler - 23 Oct 2006 16:44 GMT
> Hi,
>    Can you let me know the difference between Abstract class and
> interface.

http://mindprod.com/jgloss/interfacevsabstract.html


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.