> EOFException and FileNofFoundException are not in the same hierarchy
> structure. Well, they are, but they are sisters (or brothers??) So it
> doens't matter which one you throw, the other one will be unreachable.
So you mean there's no way to use one try/catch block to catch either
of these exceptions using one method ? :)
> Hope it helps.
>
[quoted text clipped - 56 lines]
>
> > }
Thomas Schodt - 30 Nov 2003 08:10 GMT
>> EOFException and FileNofFoundException are not in the same hierarchy
>> structure. Well, they are, but they are sisters (or brothers??) So it
[quoted text clipped - 3 lines]
> So you mean there's no way to use one try/catch block to catch either
> of these exceptions using one method ? :)
There is.
Something like
if () throw new FileNotFoundException();
else throw new EOFException();
lonelyplanet999 - 30 Nov 2003 17:48 GMT
> >> EOFException and FileNofFoundException are not in the same hierarchy
> >> structure. Well, they are, but they are sisters (or brothers??) So it
[quoted text clipped - 8 lines]
> if () throw new FileNotFoundException();
> else throw new EOFException();
Tks;)