⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wyterminal.3wy

📁 一个不错
💻 3WY
📖 第 1 页 / 共 2 页
字号:
.PP     [\fBRefer\fP] ::open(const char*,int).\"--------------------------------------------.PP.BI "virtual WyRet _swap(WySysFile& " "termf" ") throw()".PP    Interchange state of *this with \fItermf\fP.PP    [\fBRet\fP] Ok              Succeed          Wym_EBADTYPE    \fItermf\fP is not the same type as *this.\"--------------------------------------------.PP.BI "virtual WyTerminal* _alloc(WyRet& " "r" ") const".PP    Allocate a default object of the most inherited type that    *this refers.    Note: Inhertied class must override this member          See man. wybyteflow(3wy) for the reimpement example.    \fIr\fP is reset with the return status:            Wym_ENOMEM      Not enough memory            Wym_ENOSYS      *Not overridden            ...             Same from constructing WyTerminal().PP    [\fBRet\fP] Pointer of the allocated object, or NULL if failed.          User is responsible to \fBdelete\fP the returned object..\"--------------------------------------------.PP.BI "virtual WyRet read(void* " "buf" ", size_t " "count" ", size_t& " "n_read" ")".PP    Read at most \fIcount\fP bytes of data into memory pointed by \fIbuf\fP.    \fIn_read\fP is always written with the bytes read and stored    into \fIbuf\fP..PP    [\fBRet\fP] Ok              Succeed.          Wym_EBADF       Object is not valid for the operation          Wym_EFBIG       \fIcount\fP exceeds the maximum          Wym_EINTR       Interrupted by a signal before any data read          Wym_EAGAIN      Non-blocking I/O (no data read)          Wym_EIO         Low level I/O error          Wym_EINVAL      Device is not suitable for reading          Wym_EFAULT      \fIbuf\fP is inaccessible          Wym_ENOMEM      Not enough memory for \fIcount\fP.PP     [\fBRefer\fP] ::read(int,void*,size_t).\"--------------------------------------------.PP.BI "virtual WyRet read(WyStr&" " buf" ", size_t " "count" ", size_t& " "n_read" ")".PP    Read at most \fIcount\fP bytes of data and \fBappend\fP to \fIbuf\fP.    \fIn_read\fP is always written with the bytes read and appended    to \fIbuf\fP..PP    [\fBRet\fP] Ok              Succeed.          Wym_EBADF       Object is not valid for the operation          Wym_EFBIG       \fIcount\fP exceeds the maximum          Wym_EINTR       Interrupted by a signal before any data read          Wym_EAGAIN      Non-blocking I/O (no data read)          Wym_EIO         Low level I/O error          Wym_EINVAL      Device is not suitable for reading          Wym_ENOMEM      Not enough memory for \fIcount\fP.PP     [\fBRefer\fP] ::read(int,void*,size_t).\"--------------------------------------------.PP.BI "virtual WyRet write(const void* " "buf" ", size_t " "count" ", size_t& " "n_written" ")".PP    Write \fIcount\fP bytes of data in \fIbuf\fP to the device.    The number of written bytes is always stored into \fIn_written\fP.PP    [\fBRet\fP] Ok              Succeed          Wym_EBADF       Object is not valid for the operation          Wym_EINVAL      Object attatched device is not suitable          Wym_EFAULT      \fIbuf\fP is inaccessible          Wym_EFBIG       Attempt to write beyond the device limit           Wym_EAGAIN      Non-blocking I/O (write would block)          Wym_EINTR       Interrupted by a signal before data written          Wym_ENOSPC      Device left no space for the operation          Wym_EIO         Low level I/O error.PP     [\fBRefer\fP] ::write(int,const void*,size_t).\"--------------------------------------------.PP.BI "virtual WyRet write(WyCSeg " "buf" ", size_t& " "n_written" ")".PP    Write data indicated by \fIbuf\fP to the system file    The number of written bytes is always stored into \fIn_written\fP.PP    [\fBRet\fP] Ok              Succeed          Wym_EBADF       Object is not valid for the operation          Wym_EINVAL      Object attatched device is not suitable          Wym_EFBIG       Attempt to write beyond the device limit           Wym_EAGAIN      Non-blocking I/O (write would block)          Wym_EINTR       Interrupted by a signal before data written          Wym_ENOSPC      Device left no space for the operation          Wym_EIO         Low level I/O error.PP     [\fBRefer\fP] ::write(int,const void*,size_t).\"--------------------------------------------.PP.BI "virtual WyRet write(const WyStr& " "buf" ", size_t& " "n_written" ")".PP    Write data in \fIbuf\fP to the device.    The number of written bytes is always stored into \fIn_written\fP.PP    [\fBRet\fP] Ok              Succeed          Wym_EBADF       Object is not valid for the operation          Wym_EINVAL      Object attatched device is not suitable          Wym_EFBIG       Attempt to write beyond the device limit           Wym_EAGAIN      Non-blocking I/O (write would block)          Wym_EINTR       Interrupted by a signal before data written          Wym_ENOSPC      Device left no space for the operation          Wym_EIO         Low level I/O error.PP     [\fBRefer\fP] ::write(int,const void*,size_t).\"--------------------------------------------.PP.BI "virtual WyRet drain(void)" .PP    Wait until all output written to *this associated terminal device    has been transmitted..PP    [\fBRet\fP] Ok              Succeed.          Wym_EBADF       Object is not valid for the operation          Wym_EINTR       Interrupted by a signal          ...             reply converted from the errno ::tcdrain                          returned.PP     [\fBRefer\fP] ::tcdrain(int).\"--------------------------------------------.PP.BI "virtual WyRet sendbreak(int " "duration" ")" .PP    Send a break signal. \fIduration\fP indicates how long the break    signal should be.    0= 0.25-0.5 seconds    others= 0.25*\fIduration\fP to 0.5*\fIduration\fP seconds.PP    [\fBRet\fP] Ok              Succeed.          ...             reply converted from the errno ::tcsendbreak                          returned.PP     [\fBRefer\fP] ::tcsendbreak(int,int).\"--------------------------------------------.PP.BI "virtual WyRet flush(int " "queue_selector" ")" .PP    Discard the buffered data (written or read). Behavior depends on    the value of \fIqueue_selector\fP:    TCIFLUSH = discard data received but not read.    TCOFLUSH = discard date written but not transmitted.    TCIOFLUSH= do both the TCIFLUSH and TCOFLUSH functions..PP    [\fBRet\fP] Ok              Succeed.          ...             reply converted from the errno ::tcflush                          returned.PP     [\fBRefer\fP] ::tcflush(int,int).\"--------------------------------------------.PP.BI "virtual WyRet flow(int " "action" ")" .PP    Suspend or resume I/O of data, depending on \fIaction\fP:.    TCOOFF  Suspend output    TCOON   Resume output    TCIOFF  Transmit a STOP character, which stops the terminal from             sending data to the system.    TCION   Transmit a START character, which starts the terminal            sending data to the system.PP    [\fBRet\fP] Ok              Succeed.          ...             reply converted from the errno ::tcflow                          returned.PP     [\fBRefer\fP] ::tcflow(int).\"--------------------------------------------.PP.BI "virtual WyRet setattr(const WyTermios& " "tio" ",int " "option" ")" .PP    Set the terminal object with the attribute \fItio\fP. When the changes    take effect is specified by \fIaction\fP:    TCSANOW    The changes occur immediately    TCSADRAIN  The changes occur after all current output has been               transmitted. This options should be used when changing               parameters that affect output    TCSAFLUSH  The changes occur after all output has been transmitted.               Discard all input received but not read.    Note: Refer to POSIX Programmer's Guide,Donald Lewine,p161-162           for correct and portable use of struct termios          1. Read the terminal termios before modifying          2. Modify only those bits required          3. Read back the terminal termios to check if accepted.PP    [\fBRet\fP] Ok              Succeed. \fItio\fP terminal attributes are                          written to *this associated terminal.          Wym_EBADF       Object is not valid for the operation          Wym_ENOTTY      Object does not refer to a terminal device          ...             reply converted from the errno ::tcsetattr                          returned.PP     [\fBRefer\fP] ::tcsetattr(int,struct termios*).\"--------------------------------------------.PP.BI "WyRet getattr(WyTermios& " "tio" ") const" .PP    Reset \fItio\fP with the attribute settings of the terminal    device *this associates.PP    [\fBRet\fP] Ok              Succeed.          Wym_EBADF       Object is not valid for the operation          Wym_ENOTTY      Object does not refer to a terminal device          ...             reply converted from the errno ::tcgetattr                          returned.PP     [\fBRefer\fP] ::tcgetattr(int,struct termios*).\"--------------------------------------------.PP.BI   "WyRet devname(WyStr& " "pathname" ") const".PP    Reset \fIpathname\fP with the pathname of the terminal device    *this associates.PP    [\fBRet\fP] Ok              Succeed          Wym_EBADF       Object is not valid for the operation          Wym_ENOTTY      Object does not refer to a terminal device          ...             reply converted from the errno ::ttyname_r                          returned.PP     [\fBRefer\fP] ::ttyname_r(int,char*,size_t).\"--------------------------------------------.SH "SEE ALSO".BR wyret.BR wytermios.BR wyfilestat.BR wyregfile.BR wysockfile.BR wytimespec.SH NOTEExcept added by this library, replys are converted from the errno an underlying C library function returned. Report of such replysare brief from Linux Programmer's Manual. See the associated man pagefor details.Project is in development, http://sourceforge.net/projects/libwx

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -