Why there is a need to throw IOException ? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
- 1

Why there is a need to throw IOException ?

20th Mar 2017, 5:16 PM
Prashant Singh
Prashant Singh - avatar
2 Answers
+ 5
https://www.sololearn.com/Discuss/268158/?ref=app your question has already been answered... šŸ˜
20th Mar 2017, 6:19 PM
Mario L.
Mario L. - avatar
+ 3
Basically it is "thrown", whenever it is needed or not. It means error occourance while doing some input/output process. As the process cannot be done - because of some issues, like file not found and not existing file cannot be read, for example - it must be communicated back to the process caller, the IOException is for that. We do not need errors, but there are errors anyway :)
20th Mar 2017, 6:21 PM
Magyar DƔvid
Magyar DƔvid - avatar