• Home
  • Raw
  • Download

Lines Matching full:option

50   /// Socket option to permit sending of broadcast messages.
52 * Implements the SOL_SOCKET/SO_BROADCAST socket option.
55 * Setting the option:
59 * asio::socket_base::broadcast option(true);
60 * socket.set_option(option);
64 * Getting the current option value:
68 * asio::socket_base::broadcast option;
69 * socket.get_option(option);
70 * bool is_set = option.value();
80 /// Socket option to enable socket-level debugging.
82 * Implements the SOL_SOCKET/SO_DEBUG socket option.
85 * Setting the option:
89 * asio::socket_base::debug option(true);
90 * socket.set_option(option);
94 * Getting the current option value:
98 * asio::socket_base::debug option;
99 * socket.get_option(option);
100 * bool is_set = option.value();
109 /// Socket option to prevent routing, use local interfaces only.
111 * Implements the SOL_SOCKET/SO_DONTROUTE socket option.
114 * Setting the option:
118 * asio::socket_base::do_not_route option(true);
119 * socket.set_option(option);
123 * Getting the current option value:
127 * asio::socket_base::do_not_route option;
128 * socket.get_option(option);
129 * bool is_set = option.value();
139 /// Socket option to send keep-alives.
141 * Implements the SOL_SOCKET/SO_KEEPALIVE socket option.
144 * Setting the option:
148 * asio::socket_base::keep_alive option(true);
149 * socket.set_option(option);
153 * Getting the current option value:
157 * asio::socket_base::keep_alive option;
158 * socket.get_option(option);
159 * bool is_set = option.value();
168 /// Socket option for the send buffer size of a socket.
170 * Implements the SOL_SOCKET/SO_SNDBUF socket option.
173 * Setting the option:
177 * asio::socket_base::send_buffer_size option(8192);
178 * socket.set_option(option);
182 * Getting the current option value:
186 * asio::socket_base::send_buffer_size option;
187 * socket.get_option(option);
188 * int size = option.value();
198 /// Socket option for the send low watermark.
200 * Implements the SOL_SOCKET/SO_SNDLOWAT socket option.
203 * Setting the option:
207 * asio::socket_base::send_low_watermark option(1024);
208 * socket.set_option(option);
212 * Getting the current option value:
216 * asio::socket_base::send_low_watermark option;
217 * socket.get_option(option);
218 * int size = option.value();
228 /// Socket option for the receive buffer size of a socket.
230 * Implements the SOL_SOCKET/SO_RCVBUF socket option.
233 * Setting the option:
237 * asio::socket_base::receive_buffer_size option(8192);
238 * socket.set_option(option);
242 * Getting the current option value:
246 * asio::socket_base::receive_buffer_size option;
247 * socket.get_option(option);
248 * int size = option.value();
258 /// Socket option for the receive low watermark.
260 * Implements the SOL_SOCKET/SO_RCVLOWAT socket option.
263 * Setting the option:
267 * asio::socket_base::receive_low_watermark option(1024);
268 * socket.set_option(option);
272 * Getting the current option value:
276 * asio::socket_base::receive_low_watermark option;
277 * socket.get_option(option);
278 * int size = option.value();
288 /// Socket option to allow the socket to be bound to an address that is
291 * Implements the SOL_SOCKET/SO_REUSEADDR socket option.
294 * Setting the option:
298 * asio::socket_base::reuse_address option(true);
299 * acceptor.set_option(option);
303 * Getting the current option value:
307 * asio::socket_base::reuse_address option;
308 * acceptor.get_option(option);
309 * bool is_set = option.value();
319 /// Socket option to specify whether the socket lingers on close if unsent
322 * Implements the SOL_SOCKET/SO_LINGER socket option.
325 * Setting the option:
329 * asio::socket_base::linger option(true, 30);
330 * socket.set_option(option);
334 * Getting the current option value:
338 * asio::socket_base::linger option;
339 * socket.get_option(option);
340 * bool is_set = option.enabled();
341 * unsigned short timeout = option.timeout();
351 /// Socket option to report aborted connections on accept.
353 * Implements a custom socket option that determines whether or not an accept
355 * By default the option is false.
358 * Setting the option:
362 * asio::socket_base::enable_connection_aborted option(true);
363 * acceptor.set_option(option);
367 * Getting the current option value:
371 * asio::socket_base::enable_connection_aborted option;
372 * acceptor.get_option(option);
373 * bool is_set = option.value();