catch (Throwable th) {
Exception addMe = new IllegalArgumentException("While attempting to create a Proxy for " + proxyClass.getName() +
" in proxiable scope " + root.getScope() + " an error occured while creating the proxy");
if (th instanceof MultiException) {
MultiException me = (MultiException) th;
me.addError(addMe);
throw me;
}
MultiException me = new MultiException(th);
me.addError(addMe);
throw me;
}
return proxy;
}
Context<?> context;
try {
context = locator.resolveContext(root.getScopeAnnotation());
}
catch (Throwable th) {
Exception addMe = new IllegalStateException("While attempting to create a service for " + root +
" in scope " + root.getScope() + " an error occured while locating the context");
if (th instanceof MultiException) {
MultiException me = (MultiException) th;
me.addError(addMe);
throw me;
}
MultiException me = new MultiException(th);
me.addError(addMe);
throw me;
}
try {
service = context.findOrCreate(root, handle);
}
catch (MultiException me) {
throw me;
}
catch (Throwable th) {
throw new MultiException(th);
}
if (service == null && !context.supportsNullCreation()) {
throw new MultiException(new IllegalStateException("Context " +
context + " findOrCreate returned a null for descriptor " + root +
" and handle " + handle));
}
return service;