public static interface MulticastMessageChannel.Key
extends java.io.Closeable
Modifier and Type | Method and Description |
---|---|
MulticastMessageChannel.Key |
block(java.net.InetAddress source)
Block multicast packets from the given source address.
|
MulticastMessageChannel |
getChannel()
Return the channel associated with this key.
|
java.net.InetAddress |
getGroup()
Return the multicast group for which this key was created.
|
java.net.NetworkInterface |
getNetworkInterface()
Return the network interface for which this key was created.
|
java.net.InetAddress |
getSourceAddress()
Return the source address if this membership key is source specific, or
null if this membership is not
source specific. |
boolean |
isOpen()
Determine if this membership is active.
|
MulticastMessageChannel.Key |
unblock(java.net.InetAddress source)
Unblock multicast packets from the given source address that was previously blocked using the
block(InetAddress) method. |
MulticastMessageChannel.Key block(java.net.InetAddress source) throws java.io.IOException, java.lang.UnsupportedOperationException, java.lang.IllegalStateException, java.lang.IllegalArgumentException
source
- the source address to blockjava.io.IOException
- if an I/O error occursjava.lang.UnsupportedOperationException
- if the implementation does not support source filteringjava.lang.IllegalStateException
- if this key is source-specific or is no longer validjava.lang.IllegalArgumentException
- if the source
parameter is not a unicast address or is not the same address type as the multicast groupMulticastMessageChannel.Key unblock(java.net.InetAddress source) throws java.io.IOException, java.lang.IllegalStateException, java.lang.UnsupportedOperationException
block(InetAddress)
method.source
- the source address to unblockjava.io.IOException
- if an I/O error occursjava.lang.IllegalStateException
- if the given source address is not currently blocked or the key is no longer validjava.lang.UnsupportedOperationException
- if the implementation does not support source filteringMulticastMessageChannel getChannel()
java.net.InetAddress getGroup()
java.net.NetworkInterface getNetworkInterface()
java.net.InetAddress getSourceAddress()
null
if this membership is not
source specific.boolean isOpen()
true
if the membership is still activeCopyright © 2016 JBoss, a division of Red Hat, Inc.