Struct asyncio::socket_base::Debug [] [src]

pub struct Debug(_);

Socket option to enable socket-level debugging.

Implements the SOL_SOCKET/SO_DEBUG socket option.

Examples

Setting the option:

use asyncio::*;
use asyncio::ip::*;
use asyncio::socket_base::Debug;

let ctx = &IoContext::new().unwrap();
let soc = TcpSocket::new(ctx, Tcp::v4()).unwrap();

soc.set_option(Debug::new(true)).unwrap();

Getting the option:

use asyncio::*;
use asyncio::ip::*;
use asyncio::socket_base::Debug;

let ctx = &IoContext::new().unwrap();
let soc = TcpSocket::new(ctx, Tcp::v4()).unwrap();

let opt: Debug = soc.get_option().unwrap();
let is_set: bool = opt.get();

Methods

impl Debug
[src]

Trait Implementations

impl Default for Debug
[src]

Returns the "default value" for a type. Read more

impl Clone for Debug
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<P: Protocol> SocketOption<P> for Debug
[src]

impl<P: Protocol> GetSocketOption<P> for Debug
[src]

impl<P: Protocol> SetSocketOption<P> for Debug
[src]