📄 wyfilehandle.3wy
字号:
.\".\" Edited by I.J.Wang, 2004.\".TH WyFileHandle 3wy "libwy v0.31".SH NAMEWyFileHandle \- class of the system file descriptor.SH SYNOPSIS.B #include <wyfilehandle.h>.PPWyFileHandle is a discardable class for the system file descriptorNo member of this class modifies the state of the associateddevice. This class is intended a medium for file descriptorcommunication with C-library functions..SH "PUBLIC MEMBERS" \fBWyFileHandle\fP() throw() \fBWyFileHandle\fP(const WyFileHandle&) throw() explicit \fBWyFileHandle\fP(int) throw() \fBWyFileHandle\fP(WyFileHandle&, Wy::ByMove_t) throw() bool \fBis_default\fP(void) const throw() WyRet \fBstat\fP(WyFileStat&) const int \fBfd\fP(void) const throw() void \fBreset\fP(void) throw() void \fBreset\fP(WyFileHandle) throw() void \fBreset\fP(int) throw() const WyFileHandle& \fBoperator =\fP(const WyFileHandle&) throw() const WyFileHandle& \fBoperator =\fP(int) throw() bool \fBoperator ==\fP(const WyFileHandle&) const throw() bool \fBoperator !=\fP(const WyFileHandle&) const throw().SH "DESCRIPTION".\"--------------------------------------------.PP.BI "WyFileHandle() throw()".PP Construct default object fd()= -1.\"--------------------------------------------.PP.BI "WyFileHandle(const WyFileHandle& " "h" ") throw()".PP Construct object by copy from \fIh\fP. fd()= \fIh\fP.fd().\"--------------------------------------------.PP.BI "explicit WyFileHandle(int " "fd" ") throw()".PP Construct object from \fIfd\fP. fd()= \fIfd\fP.\"--------------------------------------------.PP.BI "WyFileHandle(WyFileHandle& " "src" ", Wy::ByMove_t) throw()".PP See Wy_Array(Wy_Array&, Wy::ByMove_t) in wy_array(3wy) for definition of the move constructor..\"--------------------------------------------.PP.BI "bool is_default(void) const throw()".TP Is *this equivalent to the default object.PP [\fBRet\fP] true= object is equivalent to WyFileHandle(). false= otherwise.\"--------------------------------------------.PP.BI "WyRet stat(WyFileStat& " "filestat" ") const" .PP Reset \fIfilestat\fP with the file information *this associates.PP [\fBRet\fP] Ok Succeed. Wym_EBADF Object is not valid for the operation Wym_ENOMEM Not enough memory ....PP [\fBRefer\fP] ::fstat(int,struct stat*).\"--------------------------------------------.PP.BI "int fd(void) throw()" .PP Get the file descriptor of *this.PP [\fBRet\fP] File descriptor of *this.\"--------------------------------------------.PP.BI "void reset(void) throw()" .PP Reconstruct *this to the state as WyFileHandle().\"--------------------------------------------.PP.BI "void reset(WyFileHandle " "h" ") throw()" .PP Reconstruct *this to the state as WyFileHandle(\fIh\fP).\"--------------------------------------------.PP.BI "void reset(int " "fd" ") throw()" .PP Reconstruct *this to the state as WyFileHandle(\fIfd\fP).\"--------------------------------------------.PP.BI "const WyFileHandle& operator =(const WyFileHandle& " "h" ") throw()".PP Assign object from \fIh\fP.PP [\fBRet\fP] Const reference of *this.\"--------------------------------------------.PP.BI "const WyFileHandle& operator =(int " "fd" ") throw()".PP Assign object from \fIfd\fP.PP [\fBRet\fP] Const reference of *this.\"--------------------------------------------.PP.BI "bool operator ==(const WyFileHandle& " "rhs" ") const throw()".PP.BI "bool operator !=(const WyFileHandle& " "rhs" ") const throw()".PP Test equivalence of *this with \fIrhs\fP *this==\fIrhs\fP yields true iff this->fd()==\fIrhs\fP.fd().PP [\fBRet\fP] true= relation holds false= otherwise.\"--------------------------------------------.SH "SEE ALSO".BR wyret.BR wybyteflow.BR wyregfile.BR wyfilestat.BR wymutex.BR wytimespec.SH NOTEProject is in development, http://sourceforge.net/projects/libwx
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -