private static boolean CheckServiceAndParentForSignature(String serviceKey, UDDIInquiryPortType uddiInquiryService, String token) throws UnexpectedResponseException { GetServiceDetail gsd = new GetServiceDetail(); gsd.setAuthInfo(token); gsd.getServiceKey().add(serviceKey); String bizkey = null;
req.setAuthInfo(token); ServiceDetail response = null; try {
try { req = new GetServiceDetail(); req.setAuthInfo(LoginWrapper());
ServiceList list1=inquiryService.findService(findservice); GetServiceDetail gsd=new GetServiceDetail(); for(ServiceInfo serviceInfo :list1.getServiceInfos().getServiceInfo()){ gsd.getServiceKey().add(serviceInfo.getServiceKey()); System.out.println(serviceInfo.getServiceKey()); String servicekey=serviceInfo.getServiceKey(); GetServiceDetail getServiceDetail=new GetServiceDetail(); getServiceDetail.setAuthInfo(authinfo); getServiceDetail.getServiceKey().add(servicekey); ServiceDetail serviceDetail=inquiryService.getServiceDetail(getServiceDetail); BusinessService businessservice=serviceDetail.getBusinessService().get(0); System.out.println("fetched service name:"+businessservice.getName().get(0).getValue()); String bindingkey = businessservice.getBindingTemplates().getBindingTemplate().get(0).getBindingKey(); System.out.println(bindingkey); GetBindingDetail gbd = new GetBindingDetail(); gbd.setAuthInfo(authinfo); gbd.getBindingKey().add(bindingkey); BindingDetail bindingdetail=inquiryService.getBindingDetail(gbd); BindingTemplate bindingtemplate=bindingdetail.getBindingTemplate().get(0); String accesspoint=bindingtemplate.getAccessPoint().getValue(); System.out.println(accesspoint); }
GetServiceDetail getServiceDetail = new GetServiceDetail(); getServiceDetail.getServiceKey().add(serviceKey); getServiceDetail.setAuthInfo(getAuthToken(node.getSecurityUrl())); try { ServiceDetail sd = getUDDINode(node).getTransport().getUDDIInquiryService(node.getInquiryUrl()).getServiceDetail(getServiceDetail);
sreq.setAuthInfo(token);
/** * Gets service details or NULL if it doesn't exist or an error occurred * * @param getDetail * @param node * @return null if not found * @throws RemoteException * @throws TransportException * @throws ConfigurationException */ public ServiceDetail getServiceDetail(GetServiceDetail getDetail, Node node) throws RemoteException, TransportException, ConfigurationException { getDetail.setAuthInfo(getAuthToken(node.getSecurityUrl())); try { ServiceDetail tModelDetail = getUDDINode(node).getTransport().getUDDIInquiryService(node.getInquiryUrl()).getServiceDetail(getDetail); return tModelDetail; } catch (DispositionReportFaultMessage dr) { DispositionReport report = DispositionReportFaultMessage.getDispositionReport(dr); checkForErrorInDispositionReport(report, null, null); } catch (SOAPFaultException sfe) { DispositionReport report = DispositionReportFaultMessage.getDispositionReport(sfe); checkForErrorInDispositionReport(report, null, null); } catch (UndeclaredThrowableException ute) { DispositionReport report = DispositionReportFaultMessage.getDispositionReport(ute); checkForErrorInDispositionReport(report, null, null); } catch (Throwable t){ throw new RemoteException("Unhandled exception", t); } return null; }