Originally posted by Jan Groth:
hi stuart,
since i know that it's you who normaly posts the answers, not the questions, i was warned ;-)
Thanks Jan, sounds like a compliment.
Originally posted by Jan Groth:
i discussed it with some colleagues. we'd say that it's not possible. my naive approach was to check
- if "this" holds a reference to B
- what is "super" holding then?
well, "this" is an object reference (can for example be passed into methods), while "super" is a way to reference a field in a superclass, and cannot be passed as an argument.
long talk, short sense:
it's not possible in my opinion.
curious about other answers,
jan
I tried all ways too, and came to the same conclusion. And then I thought, maybe I have missed something somewhere, so I posted it here.
And, Adne, in response to your suggestion of getSuperClass(), what if A is abstract??
[ November 16, 2005: Message edited by: Stuart Ash ]