Exceptions Handling / conditional catch (try catch if)
by Mohan[ Edit ] 2012-09-20 23:50:47
Exceptions Handling / conditional catch (try catch if)
function Toto(){}
function Titi(){}
try {
throw new Titi()
} catch ( err if err instanceof Toto ) {
Print('toto')
} catch ( err if err instanceof Titi ) {
Print('titi')
} catch(ex) {
throw(ex);
}
________________________________________