public String[] getConnectedGatewaySenders() { Set<String> uniqueIds = null; AcceptorImpl acceptor = ((CacheServerImpl)rcv.getServer()).getAcceptor(); Set<ServerConnection> serverConnections = acceptor.getAllServerConnections(); if(serverConnections !=null && serverConnections.size() >0){ uniqueIds = new HashSet<String>(); for(ServerConnection conn : serverConnections){ uniqueIds.add(conn.getMembershipID()); } String[] allConnectedClientStr = new String[uniqueIds.size()]; return uniqueIds.toArray(allConnectedClientStr); } return new String[0]; }
public String[] getConnectedGatewaySenders() { Set<String> uniqueIds = null; acceptor = ((BridgeServerImpl)((GatewayReceiverImpl)rcv).getServer()).getAcceptor(); Set<ServerConnection> serverConnections = acceptor.getAllServerConnections(); if(serverConnections !=null && serverConnections.size() >0){ uniqueIds = new HashSet<String>(); for(ServerConnection conn : serverConnections){ uniqueIds.add(conn.getMembershipID()); } String[] allConnectedClientStr = new String[uniqueIds.size()]; return uniqueIds.toArray(allConnectedClientStr); } return new String[0]; }