public Collection findStatusChangesForNodeForUniqueMonitorAndInterface(int nodeId) { List l = getHibernateTemplate().find( "select distinct status.locationMonitor, status.monitoredService.ipInterface from OnmsLocationSpecificStatus as status " + "where status.monitoredService.ipInterface.node.id = ?", nodeId ); HashSet ret = new HashSet(); for (Object o : l) { OnmsLocationMonitor mon = (OnmsLocationMonitor) ((Object[]) o)[0]; OnmsIpInterface ip = (OnmsIpInterface) ((Object[]) o)[1]; ret.add(new LocationMonitorIpInterface(mon, ip)); } return ret; }