Home
last modified time | relevance | path

Searched refs:NetworkInterface (Results 1 – 25 of 42) sorted by relevance

12

/libcore/ojluni/src/main/java/java/net/
DNetworkInterface.java67 public final class NetworkInterface { class
75 private List<NetworkInterface> childs;
76 private NetworkInterface parent = null;
78 private static final NetworkInterface defaultInterface;
111 NetworkInterface() { in NetworkInterface() method in NetworkInterface
114 NetworkInterface(String name, int index, InetAddress[] addrs) { in NetworkInterface() method in NetworkInterface
230 public Enumeration<NetworkInterface> getSubInterfaces() { in getSubInterfaces()
243 public NetworkInterface getParent() { in getParent()
293 public static NetworkInterface getByName(String name) throws SocketException { in getByName()
298 NetworkInterface[] nis = getAll(); in getByName()
[all …]
DMulticastSocket.java319 NetworkInterface defaultInterface = NetworkInterface.getDefault(); in joinGroup()
387 public void joinGroup(SocketAddress mcastaddr, NetworkInterface netIf) in joinGroup()
434 public void leaveGroup(SocketAddress mcastaddr, NetworkInterface netIf) in leaveGroup()
521 NetworkInterface ni = NetworkInterface.getByInetAddress(ia); in getInterface()
552 public void setNetworkInterface(NetworkInterface netIf) in setNetworkInterface()
571 public NetworkInterface getNetworkInterface() throws SocketException { in getNetworkInterface()
578 return new NetworkInterface(addrs[0].getHostName(), 0, addrs); in getNetworkInterface()
580 return NetworkInterface.getByIndex(niIndex); in getNetworkInterface()
DInet6Address.java207 NetworkInterface ifname, boolean scope_ifname_set) in Inet6AddressHolder()
238 NetworkInterface scope_ifname; // null
262 void init(byte addr[], NetworkInterface nif) in init()
421 Inet6Address (String hostName, byte addr[], NetworkInterface nif) in Inet6Address()
456 NetworkInterface nif) in getByAddress()
509 NetworkInterface nif = NetworkInterface.getByName (ifname); in initstr()
519 private void initif(String hostName, byte addr[], NetworkInterface nif) in initif()
551 …private static int deriveNumericScope (byte[] thisAddr, NetworkInterface ifc) throws UnknownHostEx… in deriveNumericScope()
571 Enumeration<NetworkInterface> en; in deriveNumericScope()
573 en = NetworkInterface.getNetworkInterfaces(); in deriveNumericScope()
[all …]
DAbstractPlainDatagramSocketImpl.java219 protected void joinGroup(SocketAddress mcastaddr, NetworkInterface netIf) in joinGroup()
226 protected abstract void join(InetAddress inetaddr, NetworkInterface netIf) in join()
237 protected void leaveGroup(SocketAddress mcastaddr, NetworkInterface netIf) in leaveGroup()
244 protected abstract void leave(InetAddress inetaddr, NetworkInterface netIf) in leave()
330 if (o == null || !(o instanceof Integer || o instanceof NetworkInterface)) in setOption()
332 if (o instanceof NetworkInterface) { in setOption()
333 o = new Integer(((NetworkInterface)o).getIndex()); in setOption()
402 NetworkInterface networkInterface = NetworkInterface.getByIndex(niIndex); in getNIFirstAddress()
DStandardSocketOptions.java273 public static final SocketOption<NetworkInterface> IP_MULTICAST_IF =
274 new StdSocketOption<NetworkInterface>("IP_MULTICAST_IF", NetworkInterface.class);
DDefaultInterface.java38 static NetworkInterface getDefault() { in getDefault()
DInetAddressImpl.java76 boolean isReachable(InetAddress addr, int timeout, NetworkInterface netif, in isReachable()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/net/
DNetworkInterfaceTest.java22 import java.net.NetworkInterface;
31 Enumeration<NetworkInterface> theInterfaces = null;
37 private NetworkInterface networkInterface1 = null;
39 private NetworkInterface sameAsNetworkInterface1 = null;
41 private NetworkInterface networkInterface2 = null;
161 NetworkInterface in test_getInetAddresses()
171 NetworkInterface in test_getInetAddresses()
203 NetworkInterface.getByName(null)); in test_getByNameLjava_lang_String()
209 NetworkInterface.getByName("8not a name4")); in test_getByNameLjava_lang_String()
218 networkInterface1, NetworkInterface.getByName(theName)); in test_getByNameLjava_lang_String()
[all …]
DInterfaceAddressTest.java24 import java.net.NetworkInterface;
126 Enumeration<NetworkInterface> netifs = NetworkInterface in setUp()
128 NetworkInterface theInterface = null; in setUp()
149 NetworkInterface anotherNetworkInter = NetworkInterface in setUp()
DMulticastSocketTest.java35 import java.net.NetworkInterface;
72 private NetworkInterface loopbackInterface;
73 private NetworkInterface ipv4NetworkInterface;
74 private NetworkInterface ipv6NetworkInterface;
81 loopbackInterface = NetworkInterface.getByInetAddress(InetAddress.getLoopbackAddress()); in setUp()
86 Enumeration<NetworkInterface> interfaces = NetworkInterface.getNetworkInterfaces(); in setUp()
97 NetworkInterface nextInterface = interfaces.nextElement(); in setUp()
160 ipv4NetworkInterface, NetworkInterface.getByInetAddress(mss.getInterface())); in getInterface()
171 NetworkInterface theInterface = mss.getNetworkInterface(); in getNetworkInterface()
327 NetworkInterface networkInterface, InetAddress group, InetAddress group2) in check_joinGroupLjava_net_SocketAddressLjava_net_NetworkInterface()
[all …]
DInetAddressTest.java25 import java.net.NetworkInterface;
337 Enumeration<NetworkInterface> nif = NetworkInterface.getNetworkInterfaces(); in test_isReachableLjava_net_NetworkInterfaceII()
338 NetworkInterface netif; in test_isReachableLjava_net_NetworkInterfaceII()
367 NetworkInterface loopbackInterface = null; in test_isReachableLjava_net_NetworkInterfaceII_loopbackInterface()
369 Enumeration<NetworkInterface> networkInterfaces = NetworkInterface.getNetworkInterfaces(); in test_isReachableLjava_net_NetworkInterfaceII_loopbackInterface()
372 NetworkInterface networkInterface = networkInterfaces.nextElement(); in test_isReachableLjava_net_NetworkInterfaceII_loopbackInterface()
DDatagramSocketImplTest.java25 import java.net.NetworkInterface;
101 protected void joinGroup(SocketAddress addr, NetworkInterface netInterface) in joinGroup()
112 protected void leaveGroup(SocketAddress addr, NetworkInterface netInterface) in leaveGroup()
/libcore/luni/src/test/java/libcore/java/net/
DNetworkInterfaceTest.java31 import java.net.NetworkInterface;
50 import static java.net.NetworkInterface.getNetworkInterfaces;
56 NetworkInterface lo = NetworkInterface.getByName("lo"); in testIPv6()
97 for (NetworkInterface nif : Collections.list(getNetworkInterfaces())) { in testInterfaceProperties()
98 assertEquals(nif, NetworkInterface.getByName(nif.getName())); in testInterfaceProperties()
116 for (NetworkInterface nif : Collections.list(getNetworkInterfaces())) { in testGetHardwareAddress_returnsNull()
122 NetworkInterface lo = NetworkInterface.getByName("lo"); in testLoopback()
132 for (NetworkInterface nif : Collections.list(getNetworkInterfaces())) { in testDumpAll()
172 NetworkInterface lo = NetworkInterface.getByName("lo"); in testInterfaceRemoval()
177 Field nameField = NetworkInterface.class.getDeclaredField("name"); in testInterfaceRemoval()
[all …]
DOldDatagramSocketImplFactoryTest.java26 import java.net.NetworkInterface;
161 protected void joinGroup(SocketAddress arg0, NetworkInterface arg1) throws IOException { in joinGroup()
169 protected void leaveGroup(SocketAddress arg0, NetworkInterface arg1) throws IOException { in leaveGroup()
/libcore/ojluni/annotations/hiddenapi/java/net/
DInet6Address.java47 Inet6Address(java.lang.String hostName, byte[] addr, java.net.NetworkInterface nif) in Inet6Address()
58 java.lang.String host, byte[] addr, java.net.NetworkInterface nif) in getByAddress()
73 private void initif(java.lang.String hostName, byte[] addr, java.net.NetworkInterface nif) in initif()
82 private static int deriveNumericScope(byte[] thisAddr, java.net.NetworkInterface ifc) in deriveNumericScope()
156 public java.net.NetworkInterface getScopedInterface() { in getScopedInterface()
235 java.net.NetworkInterface ifname, in Inet6AddressHolder()
248 void init(byte[] addr, java.net.NetworkInterface nif) throws java.net.UnknownHostException { in init()
314 java.net.NetworkInterface scope_ifname;
/libcore/ojluni/src/main/java/sun/nio/ch/
DMembershipKeyImpl.java30 import java.net.NetworkInterface;
43 private final NetworkInterface interf;
57 NetworkInterface interf, in MembershipKeyImpl()
76 NetworkInterface interf, in Type4()
111 NetworkInterface interf, in Type6()
161 public NetworkInterface networkInterface() { in networkInterface()
DMembershipRegistry.java30 import java.net.NetworkInterface;
51 MembershipKey checkMembership(InetAddress group, NetworkInterface interf, in checkMembership()
/libcore/ojluni/src/main/java/java/nio/channels/
DMulticastChannel.java29 import java.net.NetworkInterface;
180 MembershipKey join(InetAddress group, NetworkInterface interf) in join()
228 MembershipKey join(InetAddress group, NetworkInterface interf, InetAddress source) in join()
DMembershipKey.java29 import java.net.NetworkInterface;
167 public abstract NetworkInterface networkInterface(); in networkInterface()
/libcore/luni/src/test/java/libcore/java/nio/channels/
DDatagramChannelMulticastTest.java27 import java.net.NetworkInterface;
77 private NetworkInterface ipv4NetworkInterface;
78 private NetworkInterface ipv6NetworkInterface;
79 private NetworkInterface loopbackInterface;
87 loopbackInterface = NetworkInterface.getByInetAddress(InetAddress.getLoopbackAddress()); in setUp()
92 Enumeration<NetworkInterface> interfaces = NetworkInterface.getNetworkInterfaces(); in setUp()
104 NetworkInterface nextInterface = interfaces.nextElement(); in setUp()
230 NetworkInterface networkInterface) throws Exception { in check_joinAnySource()
320 ArrayList<NetworkInterface> realInterfaces = new ArrayList<NetworkInterface>(); in test_joinAnySource_networkInterfaces()
321 Enumeration<NetworkInterface> theInterfaces = NetworkInterface.getNetworkInterfaces(); in test_joinAnySource_networkInterfaces()
[all …]
DServerSocketChannelTest.java30 import java.net.NetworkInterface;
108 Enumeration<NetworkInterface> interfaces = NetworkInterface.getNetworkInterfaces(); in bind_nullBindsToAll()
110 NetworkInterface nic = interfaces.nextElement(); in bind_nullBindsToAll()
191 Enumeration<NetworkInterface> interfaces = NetworkInterface.getNetworkInterfaces(); in bind_loopback()
194 NetworkInterface nic = interfaces.nextElement(); in bind_loopback()
DMembershipKeyTest.java26 import java.net.NetworkInterface;
42 private final static NetworkInterface NETWORK_INTERFACE = getNetworkInterface();
262 private static NetworkInterface getNetworkInterface() { in getNetworkInterface()
264 return NetworkInterface.getByName("lo"); in getNetworkInterface()
DDatagramChannelTest.java28 import java.net.NetworkInterface;
275 Enumeration<NetworkInterface> networkInterfaces = NetworkInterface.getNetworkInterfaces(); in getNonLoopbackNetworkInterfaceAddress()
277 NetworkInterface networkInterface = networkInterfaces.nextElement(); in getNonLoopbackNetworkInterfaceAddress()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/channels/
DMockDatagramChannel.java23 import java.net.NetworkInterface;
120 public MembershipKey join(InetAddress group, NetworkInterface interf) { in join()
125 public MembershipKey join(InetAddress group, NetworkInterface interf, InetAddress source) in join()
/libcore/ojluni/annotations/mmodule/java/net/
DInet6Address.annotated.java36 …t6Address getByAddress(java.lang.String host, byte[] addr, java.net.NetworkInterface nif) throws j… in getByAddress()
64 public java.net.NetworkInterface getScopedInterface() { throw new RuntimeException("Stub!"); } in getScopedInterface()

12