EjbInvokerImplpublic class EjbInvokerImpl extends InvokerImpl This extends InvokerImpl - the difference is this creates
a Map of methods from class to proxy class |
Fields Summary |
---|
private HashMap | methodMap | private Class | endpointImplClass |
Methods Summary |
---|
public java.lang.Object | invoke(com.sun.xml.ws.api.message.Packet p, java.lang.reflect.Method m, java.lang.Object args)Here is where we actually call the endpoint method
if(methodMap == null) {
methodMap = new HashMap();
Class proxyClass = invokeObject.getClass();
for(Method x : endpointImplClass.getMethods()) {
try {
Method mappedMethod =
proxyClass.getMethod(x.getName(), x.getParameterTypes());
methodMap.put(x, mappedMethod);
} catch (NoSuchMethodException noex) {
// We do not take any action because these may be excluded @WebMethods
// or EJB business methods that are not @WebMethods etc
continue;
}
}
}
Method mappedMethod =
(Method) methodMap.get(m);
if(mappedMethod != null)
return(super.invoke(p, mappedMethod, args));
throw new IllegalAccessException("Unable to find invocation method");
|
|