/** Convert HTTP status codes to exceptions */ static protected void exec(Runnable action) { try { action.run(); } catch (HttpException ex) { handleHttpException(ex, false); } }
/** Convert HTTP status codes to exceptions */ static protected void exec(Runnable action) { try { action.run(); } catch (HttpException ex) { handleHttpException(ex, false); } }
/** Convert HTTP status codes to exceptions */ static protected <X> X exec(Supplier<X> action) { try { return action.get(); } catch (HttpException ex) { handleHttpException(ex, true); return null;} }
/** Convert HTTP status codes to exceptions */ static protected <X> X exec(Supplier<X> action) { try { return action.get(); } catch (HttpException ex) { handleHttpException(ex, true); return null;} }