Home
last modified time | relevance | path

Searched refs:StandardSocketOptions (Results 1 – 23 of 23) sorted by relevance

/libcore/ojluni/src/main/java/sun/nio/ch/
DSocketOptionRegistry.java30 import java.net.StandardSocketOptions;
61 … map.put(new RegistryKey(StandardSocketOptions.SO_BROADCAST, Net.UNSPEC), new OptionKey(1, 6)); in options()
62 … map.put(new RegistryKey(StandardSocketOptions.SO_KEEPALIVE, Net.UNSPEC), new OptionKey(1, 9)); in options()
63 … map.put(new RegistryKey(StandardSocketOptions.SO_LINGER, Net.UNSPEC), new OptionKey(1, 13)); in options()
64 … map.put(new RegistryKey(StandardSocketOptions.SO_SNDBUF, Net.UNSPEC), new OptionKey(1, 7)); in options()
65 … map.put(new RegistryKey(StandardSocketOptions.SO_RCVBUF, Net.UNSPEC), new OptionKey(1, 8)); in options()
66 … map.put(new RegistryKey(StandardSocketOptions.SO_REUSEADDR, Net.UNSPEC), new OptionKey(1, 2)); in options()
67 … map.put(new RegistryKey(StandardSocketOptions.TCP_NODELAY, Net.UNSPEC), new OptionKey(6, 1)); in options()
68 …map.put(new RegistryKey(StandardSocketOptions.IP_TOS, StandardProtocolFamily.INET), new OptionKey(… in options()
69 …map.put(new RegistryKey(StandardSocketOptions.IP_MULTICAST_IF, StandardProtocolFamily.INET), new O… in options()
[all …]
DSocketAdaptor.java323 setBooleanOption(StandardSocketOptions.TCP_NODELAY, on); in setTcpNoDelay()
327 return getBooleanOption(StandardSocketOptions.TCP_NODELAY); in getTcpNoDelay()
333 setIntOption(StandardSocketOptions.SO_LINGER, linger); in setSoLinger()
337 return getIntOption(StandardSocketOptions.SO_LINGER); in getSoLinger()
368 setIntOption(StandardSocketOptions.SO_SNDBUF, size); in setSendBufferSize()
372 return getIntOption(StandardSocketOptions.SO_SNDBUF); in getSendBufferSize()
379 setIntOption(StandardSocketOptions.SO_RCVBUF, size); in setReceiveBufferSize()
383 return getIntOption(StandardSocketOptions.SO_RCVBUF); in getReceiveBufferSize()
387 setBooleanOption(StandardSocketOptions.SO_KEEPALIVE, on); in setKeepAlive()
391 return getBooleanOption(StandardSocketOptions.SO_KEEPALIVE); in getKeepAlive()
[all …]
DDatagramSocketAdaptor.java306 setIntOption(StandardSocketOptions.SO_SNDBUF, size); in setSendBufferSize()
310 return getIntOption(StandardSocketOptions.SO_SNDBUF); in getSendBufferSize()
316 setIntOption(StandardSocketOptions.SO_RCVBUF, size); in setReceiveBufferSize()
320 return getIntOption(StandardSocketOptions.SO_RCVBUF); in getReceiveBufferSize()
324 setBooleanOption(StandardSocketOptions.SO_REUSEADDR, on); in setReuseAddress()
328 return getBooleanOption(StandardSocketOptions.SO_REUSEADDR); in getReuseAddress()
333 setBooleanOption(StandardSocketOptions.SO_BROADCAST, on); in setBroadcast()
337 return getBooleanOption(StandardSocketOptions.SO_BROADCAST); in getBroadcast()
341 setIntOption(StandardSocketOptions.IP_TOS, tc); in setTrafficClass()
345 return getIntOption(StandardSocketOptions.IP_TOS); in getTrafficClass()
DServerSocketAdaptor.java162 ssc.setOption(StandardSocketOptions.SO_REUSEADDR, on); in setReuseAddress()
170 return ssc.getOption(StandardSocketOptions.SO_REUSEADDR).booleanValue(); in getReuseAddress()
190 ssc.setOption(StandardSocketOptions.SO_RCVBUF, size); in setReceiveBufferSize()
198 return ssc.getOption(StandardSocketOptions.SO_RCVBUF).intValue(); in getReceiveBufferSize()
DAsynchronousServerSocketChannelImpl.java31 import java.net.StandardSocketOptions;
191 if (name == StandardSocketOptions.SO_REUSEADDR && in setOption()
215 if (name == StandardSocketOptions.SO_REUSEADDR && in getOption()
232 set.add(StandardSocketOptions.SO_RCVBUF); in defaultOptions()
233 set.add(StandardSocketOptions.SO_REUSEADDR); in defaultOptions()
DDatagramChannelImpl.java222 if (name == StandardSocketOptions.IP_TOS || in setOption()
223 name == StandardSocketOptions.IP_MULTICAST_TTL || in setOption()
224 name == StandardSocketOptions.IP_MULTICAST_LOOP) in setOption()
231 if (name == StandardSocketOptions.IP_MULTICAST_IF) { in setOption()
250 if (name == StandardSocketOptions.SO_REUSEADDR && in setOption()
276 if (name == StandardSocketOptions.IP_TOS || in getOption()
277 name == StandardSocketOptions.IP_MULTICAST_TTL || in getOption()
278 name == StandardSocketOptions.IP_MULTICAST_LOOP) in getOption()
283 if (name == StandardSocketOptions.IP_MULTICAST_IF) { in getOption()
306 if (name == StandardSocketOptions.SO_REUSEADDR && in getOption()
[all …]
DSocketChannelImpl.java38 import java.net.StandardSocketOptions;
217 if (name == StandardSocketOptions.IP_TOS) { in setOption()
224 if (name == StandardSocketOptions.SO_REUSEADDR && Net.useExclusiveBind()) { in setOption()
250 if (name == StandardSocketOptions.SO_REUSEADDR && in getOption()
258 if (name == StandardSocketOptions.IP_TOS) { in getOption()
274 set.add(StandardSocketOptions.SO_SNDBUF); in defaultOptions()
275 set.add(StandardSocketOptions.SO_RCVBUF); in defaultOptions()
276 set.add(StandardSocketOptions.SO_KEEPALIVE); in defaultOptions()
277 set.add(StandardSocketOptions.SO_REUSEADDR); in defaultOptions()
278 set.add(StandardSocketOptions.SO_LINGER); in defaultOptions()
[all …]
DServerSocketChannelImpl.java137 if (name == StandardSocketOptions.IP_TOS) { in setOption()
144 if (name == StandardSocketOptions.SO_REUSEADDR && in setOption()
170 if (name == StandardSocketOptions.SO_REUSEADDR && in getOption()
186 set.add(StandardSocketOptions.SO_RCVBUF); in defaultOptions()
187 set.add(StandardSocketOptions.SO_REUSEADDR); in defaultOptions()
188 set.add(StandardSocketOptions.IP_TOS); in defaultOptions()
DAsynchronousSocketChannelImpl.java31 import java.net.StandardSocketOptions;
466 if (name == StandardSocketOptions.SO_REUSEADDR && in setOption()
490 if (name == StandardSocketOptions.SO_REUSEADDR && in getOption()
507 set.add(StandardSocketOptions.SO_SNDBUF); in defaultOptions()
508 set.add(StandardSocketOptions.SO_RCVBUF); in defaultOptions()
509 set.add(StandardSocketOptions.SO_KEEPALIVE); in defaultOptions()
510 set.add(StandardSocketOptions.SO_REUSEADDR); in defaultOptions()
511 set.add(StandardSocketOptions.TCP_NODELAY); in defaultOptions()
DNet.java303 if (name == StandardSocketOptions.SO_RCVBUF ||
304 name == StandardSocketOptions.SO_SNDBUF)
310 if (name == StandardSocketOptions.SO_LINGER) {
317 if (name == StandardSocketOptions.IP_TOS) {
322 if (name == StandardSocketOptions.IP_MULTICAST_TTL) {
/libcore/ojluni/src/main/java/java/net/
DDatagramSocketImpl.java257 if (name == StandardSocketOptions.SO_SNDBUF) { in setOption()
259 } else if (name == StandardSocketOptions.SO_RCVBUF) { in setOption()
261 } else if (name == StandardSocketOptions.SO_REUSEADDR) { in setOption()
263 } else if (name == StandardSocketOptions.IP_TOS) { in setOption()
265 } else if (name == StandardSocketOptions.IP_MULTICAST_IF && in setOption()
268 } else if (name == StandardSocketOptions.IP_MULTICAST_TTL && in setOption()
274 } else if (name == StandardSocketOptions.IP_MULTICAST_LOOP && in setOption()
283 if (name == StandardSocketOptions.SO_SNDBUF) { in getOption()
285 } else if (name == StandardSocketOptions.SO_RCVBUF) { in getOption()
287 } else if (name == StandardSocketOptions.SO_REUSEADDR) { in getOption()
[all …]
DSocketImpl.java369 if (name == StandardSocketOptions.SO_KEEPALIVE) { in setOption()
371 } else if (name == StandardSocketOptions.SO_SNDBUF) { in setOption()
373 } else if (name == StandardSocketOptions.SO_RCVBUF) { in setOption()
375 } else if (name == StandardSocketOptions.SO_REUSEADDR) { in setOption()
377 } else if (name == StandardSocketOptions.SO_LINGER) { in setOption()
379 } else if (name == StandardSocketOptions.IP_TOS) { in setOption()
381 } else if (name == StandardSocketOptions.TCP_NODELAY) { in setOption()
389 if (name == StandardSocketOptions.SO_KEEPALIVE) { in getOption()
391 } else if (name == StandardSocketOptions.SO_SNDBUF) { in getOption()
393 } else if (name == StandardSocketOptions.SO_RCVBUF) { in getOption()
[all …]
DStandardSocketOptions.java41 public final class StandardSocketOptions { class
42 private StandardSocketOptions() { } in StandardSocketOptions() method in StandardSocketOptions
/libcore/ojluni/src/main/java/jdk/net/
DSockets.java357 set.add(StandardSocketOptions.SO_KEEPALIVE); in initOptionSets()
358 set.add(StandardSocketOptions.SO_SNDBUF); in initOptionSets()
359 set.add(StandardSocketOptions.SO_RCVBUF); in initOptionSets()
360 set.add(StandardSocketOptions.SO_REUSEADDR); in initOptionSets()
361 set.add(StandardSocketOptions.SO_LINGER); in initOptionSets()
362 set.add(StandardSocketOptions.IP_TOS); in initOptionSets()
363 set.add(StandardSocketOptions.TCP_NODELAY); in initOptionSets()
373 set.add(StandardSocketOptions.SO_RCVBUF); in initOptionSets()
374 set.add(StandardSocketOptions.SO_REUSEADDR); in initOptionSets()
375 set.add(StandardSocketOptions.IP_TOS); in initOptionSets()
[all …]
/libcore/luni/src/test/java/libcore/java/nio/channels/
DServerSocketChannelTest.java25 import java.net.StandardSocketOptions;
173 sc.setOption(StandardSocketOptions.SO_REUSEADDR, true); in test_setOption()
176 assertTrue(sc.getOption(StandardSocketOptions.SO_REUSEADDR)); in test_setOption()
178 sc.setOption(StandardSocketOptions.SO_REUSEADDR, false); in test_setOption()
181 assertEquals(false, (boolean)sc.getOption(StandardSocketOptions.SO_REUSEADDR)); in test_setOption()
183 sc.setOption(StandardSocketOptions.SO_RCVBUF, 1100); in test_setOption()
184 assertTrue(1100 <= sc.getOption(StandardSocketOptions.SO_RCVBUF)); in test_setOption()
188 sc.setOption(StandardSocketOptions.SO_RCVBUF, 2000); in test_setOption()
DAsynchronousServerSocketChannelTest.java27 import java.net.StandardSocketOptions;
209 assc.setOption(StandardSocketOptions.SO_RCVBUF, 5000); in test_options()
210 assertEquals(5000, (long)assc.getOption(StandardSocketOptions.SO_RCVBUF)); in test_options()
212 assc.setOption(StandardSocketOptions.SO_REUSEADDR, true); in test_options()
213 assertTrue(assc.getOption(StandardSocketOptions.SO_REUSEADDR)); in test_options()
222 assc.setOption(StandardSocketOptions.SO_KEEPALIVE, true); in test_options_iae()
270 assc.setOption(StandardSocketOptions.SO_REUSEADDR, true); in test_close()
347 assertTrue(supportedOptions.contains(StandardSocketOptions.SO_REUSEADDR)); in test_supportedOptions()
348 assertTrue(supportedOptions.contains(StandardSocketOptions.SO_RCVBUF)); in test_supportedOptions()
DAsynchronousSocketChannelTest.java28 import java.net.StandardSocketOptions;
254 asc.setOption(StandardSocketOptions.SO_REUSEADDR, true); in test_close()
839 asc.setOption(StandardSocketOptions.SO_SNDBUF, 5000); in test_options()
840 assertEquals(5000, (long) asc.getOption(StandardSocketOptions.SO_SNDBUF)); in test_options()
842 asc.setOption(StandardSocketOptions.SO_RCVBUF, 5000); in test_options()
843 assertEquals(5000, (long) asc.getOption(StandardSocketOptions.SO_RCVBUF)); in test_options()
845 asc.setOption(StandardSocketOptions.SO_KEEPALIVE, true); in test_options()
846 assertTrue(asc.getOption(StandardSocketOptions.SO_KEEPALIVE)); in test_options()
848 asc.setOption(StandardSocketOptions.SO_REUSEADDR, true); in test_options()
849 assertTrue(asc.getOption(StandardSocketOptions.SO_REUSEADDR)); in test_options()
[all …]
DDatagramChannelTest.java31 import java.net.StandardSocketOptions;
173 dc.setOption(StandardSocketOptions.SO_SNDBUF, 4096); in test_setOption()
176 assertEquals(4096, (int) dc.getOption(StandardSocketOptions.SO_SNDBUF)); in test_setOption()
182 dc.setOption(StandardSocketOptions.SO_SNDBUF, 4096); in test_setOption()
DSocketChannelTest.java33 import java.net.StandardSocketOptions;
293 sc.setOption(StandardSocketOptions.SO_LINGER, 1000); in test_setOption()
296 assertEquals(1000, (int) sc.<Integer>getOption(StandardSocketOptions.SO_LINGER)); in test_setOption()
302 sc.setOption(StandardSocketOptions.SO_LINGER, 2000); in test_setOption()
DMembershipKeyTest.java28 import java.net.StandardSocketOptions;
224 .setOption(StandardSocketOptions.IP_MULTICAST_LOOP, true /* enable loop */) in test_unblockWithJoinWithoutSource()
DDatagramChannelMulticastTest.java31 import java.net.StandardSocketOptions;
133 assertFalse(dc.getOption(StandardSocketOptions.SO_REUSEADDR)); in test_open()
443 dc.setOption(StandardSocketOptions.IP_MULTICAST_LOOP, true /* enable loop */); in check_joinAnySource_multicastLoopOption()
444 dc.setOption(StandardSocketOptions.IP_MULTICAST_IF, networkInterface); in check_joinAnySource_multicastLoopOption()
463 dc.setOption(StandardSocketOptions.IP_MULTICAST_LOOP, false /* enable loopback */); in check_joinAnySource_multicastLoopOption()
1309 datagramChannel.setOption(StandardSocketOptions.IP_MULTICAST_IF, networkInterface); in BindableChannel()
/libcore/ojluni/src/main/java/java/nio/channels/
DMulticastChannel.java33 import java.net.StandardSocketOptions; // javadoc
/libcore/
Dopenjdk_java_files.bp327 "ojluni/src/main/java/java/net/StandardSocketOptions.java",