[GR-Jug] inheritance ?

Derek Vredevoogd Derek.Vredevoogd at requestfoods.com
Mon Feb 2 13:06:44 EST 2004


Hey thanks.
I don't know if I quite understand you're logic here.
But, I do have an idea what you are saying.
I can ask again at the next meeting.

I was dealing a bit with polymorphism.  
I was hoping to put a private method in my 
subclass and have it still be available in 
its parent class(without declaring it in the parent) after conversion.  But 
somehow I don't think that will work.
But, then I got real confused and this 
question came to mind.
Anyways, no worries. Not a big deal right now.



-----Original Message-----
From: Carlus Henry [mailto:chenry at gfs.com]
Sent: Monday, February 02, 2004 12:50 PM
To: jug at gr-jug.org
Subject: Re: [GR-Jug] inheritance ?


You are a member of the Grand Rapids Java Users Group mailing list.  
Please see the bottom of this message for information on
unsubscription/customizing your preferences.
What are you doing in particular?

If Class A is extending Class B, there are many different ways to share
methods and relationships.  Typically, here are some good rules to follow:

abstract - if Class A is requiring Class B to implement a method, then make
that method abstract
public / private - if Class A has a method that is public / private then
that method is available to Class B as well
protected - if Class A method is protected, then only the subclasses of this
object can override it.

I hope this helps, if not please let us know what it is exactly you are
looking for.

Thanks
Carlus

>>> Derek.Vredevoogd at requestfoods.com 02/02/04 12:44PM >>>
You are a member of the Grand Rapids Java Users Group mailing list.  
Please see the bottom of this message for information on
unsubscription/customizing your preferences.
OK, here is a stumper, at least for me.

Do the modifiers assigned to features in a parent class 
dictate what features will be inherited by its children?
If so, what are the rules, and where is a good document about it?

Modifiers:
public,default,protected,default
final,abstract,static,native,transient,
synchronized,volatile

features:
class, method, or variable



DISCLAIMER: The information in this message is confidential and may be
legally privileged. It is intended solely for the addressee.  Access to this
message by anyone else is unauthorized.  If you are not the intended
recipient, any disclosure, copying, or distribution of the message, or any
action or omission taken by you in reliance on it, is prohibited and may be
unlawful.  Please immediately contact the sender if you have received this
message in error. Thank you.


_______________________________________________
Jug mailing list
Jug at gr-jug.org 
Un/Subscribe/Customize http://gr-jug.org/mailman/listinfo/jug


_______________________________________________
Jug mailing list
Jug at gr-jug.org
Un/Subscribe/Customize http://gr-jug.org/mailman/listinfo/jug



DISCLAIMER: The information in this message is confidential and may be
legally privileged. It is intended solely for the addressee.  Access to this
message by anyone else is unauthorized.  If you are not the intended
recipient, any disclosure, copying, or distribution of the message, or any
action or omission taken by you in reliance on it, is prohibited and may be
unlawful.  Please immediately contact the sender if you have received this
message in error. Thank you.




More information about the Jug mailing list