for (Jws2Instance svc : services)
{
svcs[ipos] = svc;
- spos[ipos++] = 1000 * svcUrls.indexOf(svc.getHost()) + 1
+ spos[ipos++] = 1000 * svcUrls.indexOf(svc.getHostURL()) + 1
+ svctypes.indexOf(svc.getName());
}
jalview.util.QuickSort.sort(spos, svcs);
// previous service of this type already present
atpoint.addSeparator();
}
- atpoint.add(hitm = new JMenuItem(service.getHost()));
+ atpoint.add(hitm = new JMenuItem(service.getHostURL()));
hitm.setForeground(Color.blue);
hitm.addActionListener(new ActionListener()
{
@Override
public void actionPerformed(ActionEvent e)
{
- Desktop.showUrl(service.getHost());
+ Desktop.showUrl(service.getHostURL());
}
});
hitm.setToolTipText(JvSwingUtils.wrapTooltip(false,
for (final Jws2Instance sv : alternates.get(service.getName()))
{
JMenuItem itm;
- hitm.add(itm = new JMenuItem(sv.getHost()));
+ hitm.add(itm = new JMenuItem(sv.getHostURL()));
itm.setForeground(Color.blue);
itm.addActionListener(new ActionListener()
{
ArrayList<String> hostlist = new ArrayList<>();
for (Jws2Instance service : enumerableServices)
{
- ArrayList<Jws2Instance> hostservices = hosts.get(service.getHost());
+ ArrayList<Jws2Instance> hostservices = hosts
+ .get(service.getHostURL());
if (hostservices == null)
{
- hosts.put(service.getHost(),
+ hosts.put(service.getHostURL(),
hostservices = new ArrayList<>());
- hostlist.add(service.getHost());
+ hostlist.add(service.getHostURL());
}
hostservices.add(service);
}
@Override
public void actionPerformed(ActionEvent e)
{
- Desktop.showUrl(service.getHost());
+ Desktop.showUrl(service.getHostURL());
}
});
hitm.setToolTipText(
for (Jws2Instance instance : getDiscoverer().services)
{
System.out.println("Service " + i++ + " "
- + instance.getClass() + "@" + instance.getHost()
+ + instance.getClass() + "@"
+ + instance.getHostURL()
+ ": " + instance.getActionText());
}
{
if (svc.getName().equals(serviceName))
{
- if (serviceurl == null || serviceurl.equals(svc.getHost()))
+ if (serviceurl == null || serviceurl.equals(svc.getHostURL()))
{
response = svc;
break;
prefmap = new HashMap<>();
preferredServiceMap.put(afid, prefmap);
}
- prefmap.put(serviceName, selectedServer.getHost());
- prefmap.put(serviceAction, selectedServer.getHost());
+ prefmap.put(serviceName, selectedServer.getHostURL());
+ prefmap.put(serviceAction, selectedServer.getHostURL());
}
public void setPreferredServiceFor(String serviceType,