http_socket() = {atom(), inet:socket()}
close/1 | Close a socks5 socket. |
connect/3 | |
connect/4 | |
controlling_process/2 | Assign a new controlling process Pid to Socket. |
messages/1 | Atoms used to identify messages in {active, once | true} mode. |
peername/1 | Return the address and port for the other end of a connection. |
recv/2 | |
recv/3 | Receive a packet from a socket in passive mode. |
send/2 | Send a packet on a socket. |
setopts/2 | Set one or more options for a socket. |
shutdown/2 | Immediately close a socket in one or two directions. |
sockname/1 | Get the local address and port of a socket. |
close(X1::http_socket()) -> ok
Close a socks5 socket.
See also: gen_tcp:close/1.
connect(ProxyHost, ProxyPort, Opts) -> any()
connect(ProxyHost, ProxyPort, Opts, Timeout) -> any()
controlling_process(X1::http_socket(), Pid::pid()) -> ok | {error, closed | not_owner | atom()}
Assign a new controlling process Pid to Socket.
See also: gen_tcp:controlling_process/2.
messages(X1) -> any()
Atoms used to identify messages in {active, once | true} mode.
peername(X1::http_socket()) -> {ok, {inet:ip_address(), inet:port_number()}} | {error, atom()}
Return the address and port for the other end of a connection.
See also: inet:peername/1.
recv(Socket, Length) -> any()
recv(X1::http_socket(), Length::non_neg_integer(), Timeout::timeout()) -> {ok, any()} | {error, closed | atom()}
Receive a packet from a socket in passive mode.
See also: gen_tcp:recv/3.
send(X1::http_socket(), Packet::iolist()) -> ok | {error, atom()}
Send a packet on a socket.
See also: gen_tcp:send/2.
setopts(X1::http_socket(), Opts::list()) -> ok | {error, atom()}
Set one or more options for a socket.
See also: inet:setopts/2.
shutdown(X1::http_socket(), How::read | write | read_write) -> ok
Immediately close a socket in one or two directions.
See also: gen_tcp:shutdown/2.
sockname(X1::http_socket()) -> {ok, {inet:ip_address(), inet:port_number()}} | {error, atom()}
Get the local address and port of a socket
See also: inet:sockname/1.