About Question enthuware.ocpjp.v17.2.3706 :

Help and support on OCA OCP Java Programmer Certification Questions
1Z0-808, 1Z0-809, 1Z0-815, 1Z0-816, 1Z0-817

Moderator: admin

Post Reply
Badem48
Posts: 29
Joined: Thu Aug 24, 2023 4:33 pm
Contact:

About Question enthuware.ocpjp.v17.2.3706 :

Post by Badem48 »

Hi,

I think this is a good question, but I am curious: Do we need to memorize which I/O Stream class method throws which exception?

admin
Site Admin
Posts: 10388
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.ocpjp.v17.2.3706 :

Post by admin »

Not for all classes but for serialization, yes, you need to know that it may throw a ClassCastException. This is actually quite relevant to deserialization. ClassCastException needs to be handled separately because it doesn't extend IOException.

Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 5 guests