List of usage examples for java.lang Exception Exception
public Exception(String message, Throwable cause)
From source file:com.ut.healthelink.jobs.processOutputRecords.java
@Override public void execute(JobExecutionContext context) throws JobExecutionException { try {/*from w w w . j av a2s . com*/ SpringBeanAutowiringSupport.processInjectionBasedOnCurrentContext(this); transactionOutManager.selectOutputRecordsForProcess(0); } catch (Exception ex) { try { throw new Exception("Error occurred trying to process output records from schedule task", ex); } catch (Exception ex1) { Logger.getLogger(processOutputRecords.class.getName()).log(Level.SEVERE, null, ex1); } } }
From source file:org.blanco.techmun.android.misc.XmlParser.java
public static synchronized Document parseHttpEntity(HttpEntity entity) throws Exception { Document doc = null;// w w w . j a v a 2s. c o m String xmlString = null; try { xmlString = EntityUtils.toString(entity); DocumentBuilder docBuilder = DocumentBuilderFactory.newInstance().newDocumentBuilder(); doc = docBuilder.parse(new InputSource(new StringReader(xmlString))); return doc; } catch (ParseException e1) { throw new Exception("Error parsing the entity.", e1); } catch (IOException e1) { throw new Exception("Error while reading the entity.", e1); } catch (ParserConfigurationException e) { throw new Exception("Error in the parser configuration.", e); } catch (SAXException e) { throw new Exception("Error parsing the entity.", e); } }
From source file:com.rr.wabshs.ui.jobs.runReports.java
@Override public void execute(JobExecutionContext context) throws JobExecutionException { try {/* w ww . java2s .co m*/ SpringBeanAutowiringSupport.processInjectionBasedOnCurrentContext(this); reportmanager.runReports(programId); } catch (Exception ex) { try { throw new Exception("Error occurredfor runReports job - new type schedule task", ex); } catch (Exception ex1) { Logger.getLogger(runReports.class.getName()).log(Level.SEVERE, null, ex1); } } }
From source file:com.rr.generic.ui.jobs.checkForumNotifications.java
@Override public void execute(JobExecutionContext context) throws JobExecutionException { try {/*from w w w. ja v a 2s . c o m*/ SpringBeanAutowiringSupport.processInjectionBasedOnCurrentContext(this); forumManager.sendNotificationsJob(programId); } catch (Exception ex) { try { throw new Exception("Error occurredfor sendNotificationsJob - new type schedule task", ex); } catch (Exception ex1) { Logger.getLogger(checkForumNotifications.class.getName()).log(Level.SEVERE, null, ex1); } } }
From source file:ee.ria.xroad.proxy.clientproxy.HandlerLoader.java
private static Handler instantiate(Class<? extends Handler> handlerClass, HttpClient client) throws Exception { try {//from ww w . j a va 2 s. c o m Constructor<? extends Handler> constructor = handlerClass.getConstructor(HttpClient.class); return constructor.newInstance(client); } catch (NoSuchMethodException e) { throw new Exception("Handler must have constructor taking " + "1 parameter (" + HttpClient.class + ")", e); } }
From source file:com.rr.generic.ui.jobs.sendDocumentEmailNotifications.java
@Override public void execute(JobExecutionContext context) throws JobExecutionException { try {//from w w w . jav a 2s. co m SpringBeanAutowiringSupport.processInjectionBasedOnCurrentContext(this); documentManager.sendNotificationsJob(programId); } catch (Exception ex) { try { throw new Exception("Error occurred send document notifications job from schedule task", ex); } catch (Exception ex1) { Logger.getLogger(sendDocumentEmailNotifications.class.getName()).log(Level.SEVERE, null, ex1); } } }
From source file:com.rr.generic.ui.jobs.sendCalendarEmailNotifications.java
@Override public void execute(JobExecutionContext context) throws JobExecutionException { try {/*from w w w . j a v a 2 s . com*/ SpringBeanAutowiringSupport.processInjectionBasedOnCurrentContext(this); calendarManager.sendEventNotificationsJob(programId); } catch (Exception ex) { try { throw new Exception("Error occurred sendEventNotificationsJob from schedule task", ex); } catch (Exception ex1) { Logger.getLogger(sendCalendarEmailNotifications.class.getName()).log(Level.SEVERE, null, ex1); } } }
From source file:com.rr.wabshs.ui.jobs.sendAnnouncementEmailNotifications.java
@Override public void execute(JobExecutionContext context) throws JobExecutionException { try {/*from www. j av a 2s . c o m*/ SpringBeanAutowiringSupport.processInjectionBasedOnCurrentContext(this); announcementManager.sendNotificationsJob(programId); } catch (Exception ex) { try { throw new Exception("Error occurred send announcement notifications job from schedule task", ex); } catch (Exception ex1) { Logger.getLogger(sendAnnouncementEmailNotifications.class.getName()).log(Level.SEVERE, null, ex1); } } }
From source file:com.rr.generic.ui.jobs.checkCalendarNotifications.java
@Override public void execute(JobExecutionContext context) throws JobExecutionException { try {//from w w w . j av a2s . com SpringBeanAutowiringSupport.processInjectionBasedOnCurrentContext(this); calendarManager.checkCalendarNotifications(programId); } catch (Exception ex) { try { throw new Exception("Error occurred checkCalendarNotifications from schedule task", ex); } catch (Exception ex1) { Logger.getLogger(checkCalendarNotifications.class.getName()).log(Level.SEVERE, null, ex1); } } }