UnixInputStream

GUnixInputStream implements GInputStream for reading from a UNIX file descriptor, including asynchronous operations. (If the file descriptor refers to a socket or pipe, this will use poll() to do asynchronous I/O. If it refers to a regular file, it will fall back to doing asynchronous I/O in another thread.)

Note that <gio/gunixinputstream.h> belongs to the UNIX-specific GIO interfaces, thus you have to use the gio-unix-2.0.pc pkg-config file when using it.

Constructors

this
this(GUnixInputStream* gUnixInputStream, bool ownedRef = false)

Sets our main struct and passes it to the parent class.

this
this(int fd, bool closeFd)

Creates a new GUnixInputStream for the given fd.

Members

Functions

getCloseFd
bool getCloseFd()

Returns whether the file descriptor of stream will be closed when the stream is closed.

getFd
int getFd()

Return the UNIX file descriptor that the stream reads from.

getStruct
void* getStruct()

the main Gtk struct as a void*

getUnixInputStreamStruct
GUnixInputStream* getUnixInputStreamStruct(bool transferOwnership = false)

Get the main Gtk struct

setCloseFd
void setCloseFd(bool closeFd)

Sets whether the file descriptor of stream shall be closed when the stream is closed.

Static functions

getType
GType getType()

Variables

gUnixInputStream
GUnixInputStream* gUnixInputStream;

the main Gtk struct