/** * This method does the work of creating an instance of the class given the URL of the wsdl * provided in the constructor. This is actually type-safe, so the fact that "abort" if anything * goes wrong should never happen. */ protected void init() { try { URL url = WSDLService.getURLForWSDL(wsdl); Constructor<S> constructor = clazzS.getConstructor(URL.class); service = constructor.newInstance(url); } catch (SecurityException e) { throw new RuntimeException( "You supplied a bad *service*/port pair (Security):" + e.getMessage()); } catch (NoSuchMethodException e) { throw new RuntimeException( "You supplied a bad *service*/port pair (NoSuchMethod):" + e.getMessage()); } catch (IllegalArgumentException e) { throw new RuntimeException( "You supplied a bad *service*/port pair (IllegalArgument):" + e.getMessage()); } catch (IllegalAccessException e) { throw new RuntimeException( "You supplied a bad *service*/port pair (IllegalAccess):" + e.getMessage()); } catch (InvocationTargetException e) { throw new RuntimeException( "You supplied a bad *service*/port pair (InvocationTarget):" + e.getMessage()); } catch (InstantiationException e) { throw new RuntimeException( "You supplied a bad *service*/port pair (Instantiation):" + e.getMessage()); } }