public class Bindings extends Object
| Constructor and Description |
|---|
Bindings() |
| Modifier and Type | Method and Description |
|---|---|
Bindings |
add(Bindings other)
Adds the results from an other binding.
|
Bindings |
addAddress(InetAddress address)
Adds an address that we want to listen to.
|
Bindings |
addInterface(String interfaceHint)
Adds an interface that will be searched for.
|
Bindings |
addProtocol(StandardProtocolFamily protocolFamily) |
List<InetAddress> |
addresses() |
boolean |
anyAddresses() |
boolean |
anyInterfaces() |
boolean |
anyProtocols() |
List<InetAddress> |
broadcastAddresses() |
void |
clear()
Clears all lists: listenInterfaceHints, listenAddresses,
broadcastAddresses.
|
boolean |
containsInterface(String name)
Checks if the user provided an interface hint.
|
InetAddress |
foundAddress() |
List<InetAddress> |
foundAddresses()
Returns a list of InetAddresses to listen to.
|
List<String> |
interfaceHints() |
boolean |
isIPv4() |
boolean |
isIPv6() |
boolean |
isListenAll() |
List<StandardProtocolFamily> |
protocolHint() |
SocketAddress |
wildCardSocket() |
public List<InetAddress> foundAddresses()
public InetAddress foundAddress()
public List<InetAddress> broadcastAddresses()
public Bindings addAddress(InetAddress address)
address - The current classpublic List<InetAddress> addresses()
public Bindings addInterface(String interfaceHint)
interfaceHint - The interface, e.g. eth0public Bindings addProtocol(StandardProtocolFamily protocolFamily)
public List<StandardProtocolFamily> protocolHint()
public void clear()
public boolean anyAddresses()
public boolean anyInterfaces()
public boolean anyProtocols()
public boolean isIPv4()
public boolean isIPv6()
public boolean isListenAll()
public boolean containsInterface(String name)
name - The name of the interface reported by the systempublic Bindings add(Bindings other)
other - The other instance to get the results frompublic SocketAddress wildCardSocket()
Copyright © 2014. All rights reserved.