Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

strmod::strmod::FDUtil Class Reference

A class utility library for file descriptor operations. More...

#include <StrMod/FDUtil.h>

List of all members.

Static Public Methods

bool setNonBlock (int fd, int &myerrno)
 Set a file descriptor to POSIX non-blocking.

bool setBlock (int fd, int &myerrno)
 Set a file descriptor to blocking.


Detailed Description

A class utility library for file descriptor operations.

This should probably be changed to a namespace. It, perhaps, shouldn't exist at all. :-)

Definition at line 42 of file FDUtil.h.


Member Function Documentation

bool strmod::strmod::FDUtil::setBlock int    fd,
int &    myerrno
[static]
 

Set a file descriptor to blocking.

Removes O_NDELAY and O_NONBLOCK.

Returns true on success, false on failure. If there's a failure, myerrno will be set to the errno result that precipitated the failure, otherwise, it will not be touched.

Parameters:
fd The file descriptor to set to non-blocking.
myerrno An OUT parameter, will be set to errno if there's an error.

Definition at line 51 of file FDUtil.cxx.

bool strmod::strmod::FDUtil::setNonBlock int    fd,
int &    myerrno
[static]
 

Set a file descriptor to POSIX non-blocking.

This will turn off O_NDELAY and turn on O_NONBLOCK.

Returns true on success, false on failure. If there's a failure, myerrno will be set to the errno result that precipitated the failure, otherwise, it will not be touched.

Parameters:
fd The file descriptor to set to non-blocking.
myerrno An OUT parameter, will be set to errno if there's an error.

Definition at line 35 of file FDUtil.cxx.


The documentation for this class was generated from the following files:
Generated on Wed Jan 29 00:32:53 2003 for libNet by doxygen1.3-rc1