public static boolean checkJavaException(final Throwable ex, IRubyObject catchable, ThreadContext context) { return checkJavaException(wrapJavaException(context.runtime, ex), ex, catchable, context); }
public static boolean checkJavaException(final Throwable ex, IRubyObject catchable, ThreadContext context) { return checkJavaException(wrapJavaException(context.runtime, ex), ex, catchable, context); }
@Deprecated // due deprecated checkJavaException public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable0, IRubyObject throwable1, IRubyObject throwable2, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwable0, throwable1, throwable2, context); } else { if (checkJavaException(currentThrowable, throwable0, context)) { return context.tru; } if (checkJavaException(currentThrowable, throwable1, context)) { return context.tru; } if (checkJavaException(currentThrowable, throwable2, context)) { return context.tru; } return context.fals; } }
@Deprecated // due deprecated checkJavaException public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable0, IRubyObject throwable1, IRubyObject throwable2, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwable0, throwable1, throwable2, context); } else { if (checkJavaException(currentThrowable, throwable0, context)) { return context.tru; } if (checkJavaException(currentThrowable, throwable1, context)) { return context.tru; } if (checkJavaException(currentThrowable, throwable2, context)) { return context.tru; } return context.fals; } }
@Deprecated // due deprecated checkJavaException public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable0, IRubyObject throwable1, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwable0, throwable1, context); } else { if (checkJavaException(currentThrowable, throwable0, context)) { return context.tru; } if (checkJavaException(currentThrowable, throwable1, context)) { return context.tru; } return context.fals; } }
@Deprecated // due deprecated checkJavaException public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable0, IRubyObject throwable1, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwable0, throwable1, context); } else { if (checkJavaException(currentThrowable, throwable0, context)) { return context.tru; } if (checkJavaException(currentThrowable, throwable1, context)) { return context.tru; } return context.fals; } }
@Deprecated // due deprecated checkJavaException public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException) currentThrowable).getException(), throwable, context); } else { if (checkJavaException(currentThrowable, throwable, context)) { return context.tru; } return context.fals; } }
@Deprecated // due deprecated checkJavaException public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException) currentThrowable).getException(), throwable, context); } else { if (checkJavaException(currentThrowable, throwable, context)) { return context.tru; } return context.fals; } }
public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable0, IRubyObject throwable1, IRubyObject throwable2, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwable0, throwable1, throwable2, context); } else { if (checkJavaException(currentThrowable, throwable0, context)) { return context.runtime.getTrue(); } if (checkJavaException(currentThrowable, throwable1, context)) { return context.runtime.getTrue(); } if (checkJavaException(currentThrowable, throwable2, context)) { return context.runtime.getTrue(); } return context.runtime.getFalse(); } }
public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable0, IRubyObject throwable1, IRubyObject throwable2, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwable0, throwable1, throwable2, context); } else { if (checkJavaException(currentThrowable, throwable0, context)) { return context.runtime.getTrue(); } if (checkJavaException(currentThrowable, throwable1, context)) { return context.runtime.getTrue(); } if (checkJavaException(currentThrowable, throwable2, context)) { return context.runtime.getTrue(); } return context.runtime.getFalse(); } }
@Deprecated // due deprecated checkJavaException public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject[] throwables, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException) currentThrowable).getException(), throwables, context); } else { if (throwables.length == 0) { // no rescue means StandardError, which rescues Java exceptions return context.tru; } else { for (int i = 0; i < throwables.length; i++) { if (checkJavaException(currentThrowable, throwables[i], context)) { return context.tru; } } } return context.fals; } }
@Deprecated // due deprecated checkJavaException public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject[] throwables, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException) currentThrowable).getException(), throwables, context); } else { if (throwables.length == 0) { // no rescue means StandardError, which rescues Java exceptions return context.tru; } else { for (int i = 0; i < throwables.length; i++) { if (checkJavaException(currentThrowable, throwables[i], context)) { return context.tru; } } } return context.fals; } }
public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable0, IRubyObject throwable1, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwable0, throwable1, context); } else { if (checkJavaException(currentThrowable, throwable0, context)) { return context.runtime.getTrue(); } if (checkJavaException(currentThrowable, throwable1, context)) { return context.runtime.getTrue(); } return context.runtime.getFalse(); } }
public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable0, IRubyObject throwable1, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwable0, throwable1, context); } else { if (checkJavaException(currentThrowable, throwable0, context)) { return context.runtime.getTrue(); } if (checkJavaException(currentThrowable, throwable1, context)) { return context.runtime.getTrue(); } return context.runtime.getFalse(); } }
public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwable, context); } else { if (checkJavaException(currentThrowable, throwable, context)) { return context.runtime.getTrue(); } return context.runtime.getFalse(); } }
public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject throwable, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwable, context); } else { if (checkJavaException(currentThrowable, throwable, context)) { return context.runtime.getTrue(); } return context.runtime.getFalse(); } }
public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject[] throwables, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwables, context); } else { if (throwables.length == 0) { // no rescue means StandardError, which rescues Java exceptions return context.runtime.getTrue(); } else { for (int i = 0; i < throwables.length; i++) { if (checkJavaException(currentThrowable, throwables[i], context)) { return context.runtime.getTrue(); } } } return context.runtime.getFalse(); } }
public static IRubyObject isJavaExceptionHandled(Throwable currentThrowable, IRubyObject[] throwables, ThreadContext context) { if (currentThrowable instanceof Unrescuable) { throwException(currentThrowable); } if (currentThrowable instanceof RaiseException) { return isExceptionHandled(((RaiseException)currentThrowable).getException(), throwables, context); } else { if (throwables.length == 0) { // no rescue means StandardError, which rescues Java exceptions return context.runtime.getTrue(); } else { for (int i = 0; i < throwables.length; i++) { if (checkJavaException(currentThrowable, throwables[i], context)) { return context.runtime.getTrue(); } } } return context.runtime.getFalse(); } }
if (Helpers.checkJavaException(exception, ex, excType, context)) { runtime.getGlobalVariables().set("$!", exception); return true;
if (Helpers.checkJavaException(exception, ex, excType, context)) { runtime.getGlobalVariables().set("$!", exception); return true;