I have two classes, a Parent, and a Child. Parent has two methods, one of which is overloaded by Child.
Okay, this is very simplified. Here's my question. If later in the code, Child.initializeGUI is called, will initializeGUI call the Parent getPanel method or the Child getPanel method? I think (and hope) it's the latter, but I wanted to verify. [ April 23, 2008: Message edited by: Jess Dancel ]
Why don't you just give it a try, maybe identifying which of the getPanel() methods the panel comes from, eg by setting it's color before returning it? This is the best way of learning how things work ...
Academically, the getPanel() method of the Child class should be the one to be invoked. The only way of accessing Parent.getPanel() on a Child object is from within the Child object using super.getPanel().