I had came across in a java2 book which i am reading, which covers casting objects. However, I do not quite understand one of its examples.
For example, consider a method that takes two arguments, one of type objects and another of type window. You can pass an instance of any class for the object argument because all java classes are subclasses of object. for the window argument, you can pass in its subclasses, such as Dialog, FileDialog and Frame.
What exactly is a window and on what occations does casting of objects come into hand? Thanks.. =D