/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
/** * Drops non-source specific membership in a multicast group. * If this connection doesn't have non-source specific membership in the group * on the given interface to receive datagrams then this method call * has no effect. Otherwise this connection drops the group membership. * * @param group The multicast address to join * @param networkInterface The network interface on which to join the group * * @throws IOException */ public void drop(final InetAddress group, final NetworkInterface networkInterface) throws IOException { drop(group, networkInterface, null); }
@Override public void run(final UDPNIOConnection connection) throws Exception { // Drop the multicast group membership connection.drop(groupAddr, ni, source); try { // construct destination multicast address to send the message to final InetSocketAddress peerAddr = new InetSocketAddress(groupAddr, ((InetSocketAddress) connection.getLocalAddress()).getPort()); // Create Future to be able to block until the message is sent final FutureImpl<WriteResult<String, SocketAddress>> writeFuture = Futures.createSafeFuture(); // Send the leave message to the group connection.write(peerAddr, "left the group " + groupAddr, Futures.toCompletionHandler(writeFuture)); // Block until the message is sent writeFuture.get(10, TimeUnit.SECONDS); } catch (Exception e) { } } }