var searchIndex = {}; searchIndex["simple_stream"] = {"doc":"","items":[[3,"Plain","simple_stream","",null,null],[3,"Socket","","Wrapper for file descriptor based sockets",null,null],[3,"Secure","","",null,null],[0,"frame","","",null,null],[0,"simple","simple_stream::frame","The frame module provides a structred way to send and receive\nmessage through streams.",null,null],[3,"SimpleFrame","simple_stream::frame::simple","",null,null],[3,"SimpleFrameBuilder","","",null,null],[11,"clone","","",0,null],[11,"clone","","",1,null],[11,"from_bytes","","",1,{"inputs":[{"name":"vec"}],"output":{"name":"option"}}],[11,"new","","",0,null],[11,"payload","","",0,null],[11,"to_bytes","","",0,null],[11,"len_as_vec","","",0,null],[11,"as_mut_raw_erased","","",0,null],[11,"default","","",0,{"inputs":[],"output":{"name":"simpleframe"}}],[0,"websocket","simple_stream::frame","",null,null],[3,"WebSocketFrame","simple_stream::frame::websocket","",null,null],[3,"WebSocketFrameBuilder","","",null,null],[4,"FrameType","","",null,null],[13,"Control","","",2,null],[13,"Data","","",2,null],[4,"OpType","","",null,null],[13,"Continuation","","",3,null],[13,"Text","","",3,null],[13,"Binary","","",3,null],[13,"Close","","",3,null],[13,"Ping","","",3,null],[13,"Pong","","",3,null],[11,"eq","","",2,null],[11,"clone","","",2,null],[11,"eq","","",3,null],[11,"clone","","",3,null],[11,"clone","","",4,null],[11,"clone","","",5,null],[11,"from_bytes","","",5,{"inputs":[{"name":"vec"}],"output":{"name":"option"}}],[11,"new","","",4,null],[11,"op_type","","",4,null],[11,"frame_type","","",4,null],[11,"is_masked","","",4,null],[11,"payload_unmasked","","",4,null],[11,"payload","","",4,null],[11,"to_bytes","","",4,null],[11,"len_as_vec","","",4,null],[11,"as_mut_raw_erased","","",4,null],[11,"default","","",4,{"inputs":[],"output":{"name":"websocketframe"}}],[11,"fmt","","",2,null],[11,"fmt","","",2,null],[11,"fmt","","",3,null],[11,"fmt","","",3,null],[8,"Frame","simple_stream::frame","",null,null],[10,"to_bytes","","",6,null],[10,"payload","","",6,null],[10,"len_as_vec","","",6,null],[10,"as_mut_raw_erased","","",6,null],[8,"FrameBuilder","","",null,null],[10,"from_bytes","","",7,{"inputs":[{"name":"vec"}],"output":{"name":"option"}}],[11,"fmt","simple_stream","",8,null],[11,"eq","","",8,null],[11,"ne","","",8,null],[11,"clone","","",8,null],[11,"new","","Creates a new socket with assumed ownership of `fd`",8,{"inputs":[{"name":"rawfd"}],"output":{"name":"socket"}}],[11,"set_tcp_nodelay","","",8,null],[11,"set_nonblocking","","",8,null],[11,"set_bindtodevice","","",8,null],[11,"set_broadcast","","",8,null],[11,"set_bsdcompat","","",8,null],[11,"set_debug","","",8,null],[11,"set_dontroute","","",8,null],[11,"set_keepalive","","",8,null],[11,"set_linger","","",8,null],[11,"set_mark","","",8,null],[11,"set_oobinline","","",8,null],[11,"set_passcred","","",8,null],[11,"set_priority","","",8,null],[11,"set_rcvbuf","","",8,null],[11,"set_rcvbufforce","","",8,null],[11,"set_rcvlowat","","",8,null],[11,"set_sndlowat","","",8,null],[11,"set_rcvtimeo","","",8,null],[11,"set_sndtimeo","","",8,null],[11,"set_reuseaddr","","",8,null],[11,"set_sndbuf","","",8,null],[11,"set_sndbufforce","","",8,null],[11,"set_timestamp","","",8,null],[11,"read","","",8,null],[11,"write","","",8,null],[11,"flush","","",8,null],[11,"as_raw_fd","","",8,null],[11,"clone","","",9,null],[11,"new","","",9,{"inputs":[{"name":"s"}],"output":{"name":"plain"}}],[11,"b_recv","","",9,null],[11,"b_send","","",9,null],[11,"nb_recv","","",9,null],[11,"nb_send","","",9,null],[11,"as_raw_fd","","",9,null],[11,"shutdown","","",9,null],[11,"close","","",9,null],[11,"clone","","",10,null],[11,"new","","",10,{"inputs":[{"name":"sslstream"}],"output":{"name":"secure"}}],[11,"b_recv","","",10,null],[11,"b_send","","",10,null],[11,"nb_recv","","",10,null],[11,"nb_send","","",10,null],[11,"as_raw_fd","","",10,null],[11,"shutdown","","",10,null],[11,"close","","",10,null],[8,"TcpOptions","","The `TcpOptions` trait allows for various TCP level settings.",null,null],[10,"set_tcp_nodelay","","If set, disable the Nagle algorithm. This means that segments are always sent as soon as\npossible, even if there is only a small amount of data. When not set, data is buffered\nuntil there is a sufficient amount to send out, thereby avoiding the frequent sending of\nsmall packets, which results in poor utilization of the network. This option is\noverridden by TCP_CORK; however, setting this option forces an explicit flush of pending\noutput, even if TCP_CORK is currently set.",11,null],[8,"SocketOptions","","The `SocketOptions` trait allows for various socket level settings.",null,null],[10,"set_bindtodevice","","Bind this socket to a particular device like "eth0", as specified in the passed\ninterface name. If the name is an empty string or the option length is zero, the socket\ndevice binding is removed. The passed option is a variable-length null-terminated\ninterface name string with the maximum size of IFNAMSIZ. If a socket is bound to an\ninterface, only packets received from that particular interface are processed by the\nsocket. Note that this only works for some socket types, particularly AF_INET sockets.\nIt is not supported for packet sockets (use normal bind(2) there).",12,null],[10,"set_broadcast","","When enabled, datagram sockets are allowed to send packets to a broadcast address.\nThis option has no effect on stream-oriented sockets.",12,null],[10,"set_bsdcompat","","Enable BSD bug-to-bug compatibility. This is used by the UDP protocol module in\nLinux 2.0 and 2.2. If enabled ICMP errors received for a UDP socket will not be passed\nto the user program. In later kernel versions, support for this option has been phased\nout: Linux 2.4 silently ignores it, and Linux 2.6 generates a kernel warning\n(printk()) if a program uses this option. Linux 2.0 also enabled BSD bug-to-bug\ncompatibility options (random header changing, skipping of the broadcast flag) for raw\nsockets with this option, but that was removed in Linux 2.2.",12,null],[10,"set_debug","","Enable socket debugging. Only allowed for processes with the CAP_NET_ADMIN capability\nor an effective user ID of 0.",12,null],[10,"set_dontroute","","Don't send via a gateway, only send to directly connected hosts. The same effect can be\nachieved by setting the MSG_DONTROUTE flag on a socket send(2) operation. Expects an\ninteger boolean flag.",12,null],[10,"set_keepalive","","Enable sending of keep-alive messages on connection-oriented sockets. Expects an integer\nboolean flag.",12,null],[10,"set_linger","","Sets or gets the SO_LINGER option. When enabled, a close(2) or shutdown(2) will not return\nuntil all queued messages for the socket have been successfully sent or the linger timeout\nhas been reached. Otherwise, the call returns immediately and the closing is done in the\nbackground. When the socket is closed as part of exit(2), it always lingers in the\nbackground.",12,null],[10,"set_mark","","Set the mark for each packet sent through this socket (similar to the netfilter MARK\ntarget but socket-based). Changing the mark can be used for mark-based routing without\nnetfilter or for packet filtering. Setting this option requires the CAP_NET_ADMIN\ncapability.",12,null],[10,"set_oobinline","","If this option is enabled, out-of-band data is directly placed into the receive data\nstream. Otherwise out-of-band data is only passed when the MSG_OOB flag is set during\nreceiving.",12,null],[10,"set_passcred","","Enable or disable the receiving of the SCM_CREDENTIALS control message. For more\ninformation see unix(7).",12,null],[10,"set_priority","","Set the protocol-defined priority for all packets to be sent on this socket. Linux uses\nthis value to order the networking queues: packets with a higher priority may be processed\nfirst depending on the selected device queueing discipline. For ip(7), this also sets the\nIP type-of-service (TOS) field for outgoing packets. Setting a priority outside the\nrange 0 to 6 requires the CAP_NET_ADMIN capability.",12,null],[10,"set_rcvbuf","","Sets or gets the maximum socket receive buffer in bytes. The kernel doubles this value\n(to allow space for bookkeeping overhead) when it is set using setsockopt(2), and this\ndoubled value is returned by getsockopt(2). The default value is set by\nthe /proc/sys/net/core/rmem_default file, and the maximum allowed value is set by\nthe /proc/sys/net/core/rmem_max file. The minimum (doubled) value for this option is 256.",12,null],[10,"set_rcvbufforce","","Using this socket option, a privileged (CAP_NET_ADMIN) process can perform the same task\nas SO_RCVBUF, but the rmem_max limit can be overridden.",12,null],[10,"set_rcvlowat","","Specify the minimum number of bytes in the buffer until the socket layer will pass the\ndata to the protocol (SO_SNDLOWAT) or the user on receiving (SO_RCVLOWAT). These two\nvalues are initialized to 1. SO_SNDLOWAT is not changeable on Linux (setsockopt(2) fails\nwith the error ENOPROTOOPT). SO_RCVLOWAT is changeable only since Linux 2.4. The select(2)\nand poll(2) system calls currently do not respect the SO_RCVLOWAT setting on Linux, and\nmark a socket readable when even a single byte of data is available. A subsequent read\nfrom the socket will block until SO_RCVLOWAT bytes are available.",12,null],[10,"set_sndlowat","","Specify the minimum number of bytes in the buffer until the socket layer will pass the\ndata to the protocol (SO_SNDLOWAT) or the user on receiving (SO_RCVLOWAT). These two\nvalues are initialized to 1. SO_SNDLOWAT is not changeable on Linux (setsockopt(2) fails\nwith the error ENOPROTOOPT). SO_RCVLOWAT is changeable only since Linux 2.4. The select(2)\nand poll(2) system calls currently do not respect the SO_RCVLOWAT setting on Linux, and\nmark a socket readable when even a single byte of data is available. A subsequent read\nfrom the socket will block until SO_RCVLOWAT bytes are available.",12,null],[10,"set_rcvtimeo","","Specify the receiving or sending timeouts until reporting an error. The argument is a\nstruct timeval. If an input or output function blocks for this period of time, and data\nhas been sent or received, the return value of that function will be the amount of data\ntransferred; if no data has been transferred and the timeout has been reached then -1 is\nreturned with errno set to EAGAIN or EWOULDBLOCK, or EINPROGRESS (for connect(2)) just as\nif the socket was specified to be nonblocking. If the timeout is set to zero (the default)\nthen the operation will never timeout. Timeouts only have effect for system calls that\nperform socket I/O (e.g., read(2), recvmsg(2), send(2), sendmsg(2)); timeouts have no\neffect for select(2), poll(2), epoll_wait(2), and so on.",12,null],[10,"set_sndtimeo","","Specify the receiving or sending timeouts until reporting an error. The argument is a\nstruct timeval. If an input or output function blocks for this period of time, and data\nhas been sent or received, the return value of that function will be the amount of data\ntransferred; if no data has been transferred and the timeout has been reached then -1 is\nreturned with errno set to EAGAIN or EWOULDBLOCK, or EINPROGRESS (for connect(2)) just as\nif the socket was specified to be nonblocking. If the timeout is set to zero (the default)\nthen the operation will never timeout. Timeouts only have effect for system calls that\nperform socket I/O (e.g., read(2), recvmsg(2), send(2), sendmsg(2)); timeouts have no\neffect for select(2), poll(2), epoll_wait(2), and so on.",12,null],[10,"set_reuseaddr","","Indicates that the rules used in validating addresses supplied in a bind(2) call should\nallow reuse of local addresses. For AF_INET sockets this means that a socket may bind,\nexcept when there is an active listening socket bound to the address. When the listening\nsocket is bound to INADDR_ANY with a specific port then it is not possible to bind to this\nport for any local address. Argument is an integer boolean flag.",12,null],[10,"set_sndbuf","","Sets or gets the maximum socket send buffer in bytes. The kernel doubles this value\n(to allow space for bookkeeping overhead) when it is set using setsockopt(2), and this\ndoubled value is returned by getsockopt(2). The default value is set by\nthe /proc/sys/net/core/wmem_default file and the maximum allowed value is set by\nthe /proc/sys/net/core/wmem_max file. The minimum (doubled) value for this option is 2048.",12,null],[10,"set_sndbufforce","","Using this socket option, a privileged (CAP_NET_ADMIN) process can perform the same task\nas SO_SNDBUF, but the wmem_max limit can be overridden.",12,null],[10,"set_timestamp","","Enable or disable the receiving of the SO_TIMESTAMP control message. The timestamp control\nmessage is sent with level SOL_SOCKET and the cmsg_data field is a struct timeval\nindicating the reception time of the last packet passed to the user in this call.\nSee cmsg(3) for details on control messages.",12,null],[10,"set_nonblocking","","Sets the `O_NONBLOCK` flag on the underlying fd",12,null],[8,"Blocking","","",null,null],[10,"b_recv","","",13,null],[10,"b_send","","",13,null],[8,"NonBlocking","","",null,null],[10,"nb_recv","","",14,null],[10,"nb_send","","",14,null]],"paths":[[3,"SimpleFrame"],[3,"SimpleFrameBuilder"],[4,"FrameType"],[4,"OpType"],[3,"WebSocketFrame"],[3,"WebSocketFrameBuilder"],[8,"Frame"],[8,"FrameBuilder"],[3,"Socket"],[3,"Plain"],[3,"Secure"],[8,"TcpOptions"],[8,"SocketOptions"],[8,"Blocking"],[8,"NonBlocking"]]}; initSearch(searchIndex);