{
}
protected Object getTargetBean(Endpoint ep, Invocation epInv) throws Exception
{
InvocationContext invCtx = epInv.getInvocationContext();
Object targetBean = invCtx.getTargetBean();
if (targetBean == null)
{
try
{
Class<?> epImpl = ep.getTargetBeanClass();
targetBean = epImpl.newInstance();
invCtx.setTargetBean(targetBean);
}
catch (Exception ex)
{
throw new IllegalStateException("Cannot get target bean instance", ex);
}