At the highest level of an exception we have the notorious Exception class..beneath that we have a wide array of classes such as IOException, IndexOutOf..Exception, etc etc.

What is the best way to find out what the first exception an object may throw, for instance is it just best to use the help documents and read on what the object might throw.

Meaning avoiding to have a try / catch / finally block with all the catches being of type Exception e...I would like to be able to throw the particular exception that my code has thrown. For instance, when dealing with File I/O
instead of the General Exception one can throw IOExceptions...

So how does one tell what exceptions specific objects throw that way we can handle them more appropriately ?

Thanks