my dog learned polymorphism*
The moose likes Beginning Java and the fly likes Abstract classes Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Abstract classes" Watch "Abstract classes" New topic
Author

Abstract classes

Nigel Browne
Ranch Hand

Joined: May 15, 2001
Posts: 673
Is it fair to say that an abstract class should only blueprint the methods that will be public in the classes which inherit from it ?
James Gray
Ranch Hand

Joined: Sep 10, 2001
Posts: 30
I would say yes, mostly. If all you want to do is "blueprint" though, that's more aptly done with an Interface. Abstract classes should be used when you want to provide partial implementation and/or support to those future methods.
Nigel Browne
Ranch Hand

Joined: May 15, 2001
Posts: 673
The reason for blueprinting with an abstract class. Is that I can use the same class regardless of the networking method I chose.
 
jQuery in Action, 2nd edition
 
subject: Abstract classes
 
Similar Threads
WA #1.....word association
modifers
How To Placed variables in Abstract classes
Abstract classes
How To Placed variables in Abstract classes