StdSocket

std.socket.Socket wrapper wich is compatible with PSQLConnection. If you want to use custom socket type (vibe-d or any other), make it duck-type and exception-compatible with this one.

Constructors

this
this(string host, ushort port, Duration timeout)

Establish connection to backend. Constructor is expected to throw Exception if anything goes wrong.

Members

Functions

receive
auto receive(ubyte[] buf)

Fill byte buffer from the socket completely or throw.

send
auto send(const(ubyte)[] buf)

Send whole byte buffer or throw. Throws: PsqlSocketException.

Properties

socket
Socket socket [@property getter]

Underlying socket instance.

Meta