XXII. Direct IO Functions

소개

PHP supports the direct io functions as described in the Posix Standard (Section 6) for performing I/O functions at a lower level than the C-Language stream I/O functions (fopen(), fread(),..). The use of the DIO functions should be considered only when direct control of a device is needed. In all other cases, the standard filesystem functions are more than adequate.

참고: 이 확장 모듈은 윈도우 플랫폼에서는 사용할 수 없습니다.

요구 사항

이 확장 모듈을 빌드할 때 외부 라이브러리가 필요하지 않습니다.

설치

To get these functions to work, you have to configure PHP with --enable-dio.

런타임 설정

이 확장 모듈은 php.ini 설정이 존재하지 않습니다.

리소스 종류

One resource type is defined by this extension: a file descriptor returned by dio_open().

상수 정의

이 확장 모듈은 상수를 정의하지 않습니다.

차례
dio_close -- Closes the file descriptor given by fd
dio_fcntl -- Performs a c library fcntl on fd
dio_open --  Opens a new filename with specified permissions of flags and creation permissions of mode
dio_read --  Reads n bytes from fd and returns them, if n is not specified, reads 1k block
dio_seek -- Seeks to pos on fd from whence
dio_stat --  Gets stat information about the file descriptor fd
dio_tcsetattr --  Sets terminal attributes and baud rate for a serial port
dio_truncate --  Truncates file descriptor fd to offset bytes
dio_write --  Writes data to fd with optional truncation at length