7879808182838485868788
if (routeBuilders != null) { for (RoutesBuilder builder : routeBuilders) { try { camelContext.addRoutes(builder); } catch (Exception e) { throw new ProvisionException("Failed to add the router. Reason: " + e, e); } } } updateRegistry(camelContext); return camelContext;
6667686970717273747576
{ initialisable.initialise(); } catch (Exception e) { throw new ProvisionException("Failed to invoke initialise(): " + e, e); } } } });
387388389390391392393
public void throwProvisionExceptionIfErrorsExist() { if (!hasErrors()) { return; } throw new ProvisionException(getMessages()); }
4445464748495051
} }); errors.throwIfNewErrors(0); return t; } catch (ErrorsException e) { throw new ProvisionException(errors.merge(e.getErrors()).getMessages()); } }
744745746747748749750751752753754
} }); errors.throwIfNewErrors(0); return t; } catch (ErrorsException e) { throw new ProvisionException(errors.merge(e.getErrors()).getMessages()); } } @Override public String toString() { return factory.toString();
8384858687888990
public void afterInjection(I injectee) { try { field.setAccessible(true); field.set(injectee, logger); } catch (IllegalAccessException e) { throw new ProvisionException(e.getMessage(), e); } }
596061626364656667
RuntimeInstance ri = new RuntimeInstance(); try { ri.init(p); } catch (Exception err) { throw new ProvisionException("Cannot configure Velocity templates", err); } return ri; }
3637383940414243
@Override public Database<ReviewDb> get() { try { return new Database<ReviewDb>(datasource, ReviewDb.class); } catch (OrmException e) { throw new ProvisionException("Cannot create ReviewDb", e); } }
201202203204205206207208209
if (password != null) { p.setProperty("password", password); } return new SimpleDataSource(p); } catch (SQLException se) { throw new ProvisionException("Database unavailable", se); } } }
242526272829303132
public class Schema_52 extends SchemaVersion { @Inject Schema_52() { super(new Provider<SchemaVersion>() { public SchemaVersion get() { throw new ProvisionException("Cannot upgrade from 51"); } }); }