I have a program that reads lines from csv file. I want to get number of errors (number of all corrupted columns). The program works as:
For each line : try { checkColumn1 method () --> May Throw myException checkColumn2 method () --> May Throw myException checkColumn3 method () --> May Throw myException .... .... checkLastColumnCSV method () --> May Throw myException }catch (myException object){ countErrors ++; } My program stops at the first exception thrown by a check method, but I want the program to continue executing until the last Checkcolumn method in order to calculate the number of errors on all columns.
I'm working with Java 6 (in an old project), so I cannot use the functional interface.
Thank you for your suggestions.