List of usage examples for org.springframework.batch.item.adapter DynamicMethodInvocationException DynamicMethodInvocationException
public DynamicMethodInvocationException(Throwable cause)
From source file:org.springframework.batch.item.data.RepositoryItemReader.java
private Object doInvoke(MethodInvoker invoker) throws Exception { try {//from ww w. j av a2s. co m invoker.prepare(); } catch (ClassNotFoundException e) { throw new DynamicMethodInvocationException(e); } catch (NoSuchMethodException e) { throw new DynamicMethodInvocationException(e); } try { return invoker.invoke(); } catch (InvocationTargetException e) { if (e.getCause() instanceof Exception) { throw (Exception) e.getCause(); } else { throw new InvocationTargetThrowableWrapper(e.getCause()); } } catch (IllegalAccessException e) { throw new DynamicMethodInvocationException(e); } }