C++ counterparts of SPL native functions that deal with file operations. More...

Detailed Description

C++ counterparts of SPL native functions that deal with file operations.

Function Documentation

Create a directory

Parameters

Remove a file or directory.

Parameters

Remove a file or directory.

Parameters

Open a file.

Parameters
Returns
The FILE* for the file, encoded as uint64.

Open a file.

Parameters
Returns
The FILE* for the file, encoded as uint64.

Close a file.

Parameters
Returns
Return code from the system fclose() call.

Flush a file to disk.

Parameters
Returns
Return code from the system fflush() call.

Return the current file position.

Parameters
Returns
File position.

Set the current file position.

Parameters

Return the indicator for specifying to seek relative to the start of the file.

Returns
The SEEK_SET indicator.

Return the indicator for specifying to seek relative to the current file position.

Returns
The SEEK_CUR indicator.

Return the indicator for specifying to seek relative to the end of the file.

Returns
The SEEK_END indicator.

Set the current file position to the start of the file.

Parameters

Test if the stream is at the end of the file.

Parameters
Returns
The value 'true' if the stream is at the end of the file.

Clear the error and end-of-file indicators for an open file.

Parameters

Return information about a file.

Parameters

Return information about a file.

Parameters

Return timestamp information about a file.

Parameters

Return timestamp information about a file.

Parameters

Return information about a file.

Parameters

Return information about a file.

Parameters

Return timestamp information about a file.

Parameters

Return timestamp information about a file.

Parameters

Write a string to a file.

Parameters

Write a string to a file.

Parameters

Write a string to a file.

Parameters

Write a string to a file.

Parameters

Write an SPL value to a file as a text string.

Parameters

Write an SPL value to a file using binary format.

Parameters

Write a list of bytes to a file using binary format.

Parameters

Read a 'token' from a file. A token is a series of non-whitespace characters. Whitespace is skipped until a non-whitespace character is found, and then all non-whitespace characters in the token are returned.

Parameters
Returns
The token read from the file. The token is empty if the end of the file is reached.

Read a line from a file.

Parameters
Returns
The line read from the file (the new line character is not included).
template<class T >

Read an SPL value from a file as a text string.

Parameters
template<class T >

Read an SPL value from a file using binary format.

Parameters

Read a list of bytes from a file using binary format.

Parameters
Returns
Number of bytes read.

Read a whole file into a blob as binary.

Parameters

Write a blob into a file as binary.

Parameters

Return whether the value is EOF.

Parameters
Returns
The value 'true' if the value is EOF.

Return whether the value is EACCES.

Parameters
Returns
The value 'true' if the value is EACCES.

Return whether the value is EAGAIN.

Parameters
Returns
The value 'true' if the value is EAGAIN.

Return whether the value is EBADF.

Parameters
Returns
The value 'true' if the value is EBADF.

Return whether the value is EFAULT.

Parameters
Returns
The value 'true' if the value is EFAULT.

Return whether the value is EFBIG.

Parameters
Returns
The value 'true' if the value is EFBIG.

Return whether the value is EINTR.

Parameters
Returns
The value 'true' if the value is EINTR.

Return whether the value is EINVAL.

Parameters
Returns
The value 'true' if the value is EINVAL.

Return whether the value is EIO.

Parameters
Returns
The value 'true' if the value is EIO.

Return whether the value is EISDIR.

Parameters
Returns
The value 'true' if the value is EISDIR.

Return whether the value is EMFILE.

Parameters
Returns
The value 'true' if the value is EMFILE.

Return whether the value is ENFILE.

Parameters
Returns
The value 'true' if the value is ENFILE.

Return whether the value is ELOOP.

Parameters
Returns
The value 'true' if the value is ELOOP.

Return whether the value is ENAMETOOLONG.

Parameters
Returns
The value 'true' if the value is ENAMETOOLONG.

Return whether the value is ENODEV.

Parameters
Returns
The value 'true' if the value is ENODEV.

Return whether the value is ENOENT.

Parameters
Returns
The value 'true' if the value is ENOENT.

Return whether the value is ENOMEM.

Parameters
Returns
The value 'true' if the value is ENOMEM.

Return whether the value is ENOSPC.

Parameters
Returns
The value 'true' if the value is ENOSPC.

Return whether the value is ENOTDIR.

Parameters
Returns
The value 'true' if the value is ENOTDIR.

Return whether the value is ENXIO.

Parameters
Returns
The value 'true' if the value is ENXIO.

Return whether the value is EOVERFLOW.

Parameters
Returns
The value 'true' if the value is EOVERFLOW.

Return whether the value is EPIPE.

Parameters
Returns
The value 'true' if the value is EPIPE.

Return whether the value is EPERM.

Parameters
Returns
The value 'true' if the value is EPERM.

Return whether the value is EROFS.

Parameters
Returns
The value 'true' if the value is EROFS.

Return whether the value is ESPIPE.

Parameters
Returns
The value 'true' if the value is ESPIPE.

Return whether the value is ETXTBSY.

Parameters
Returns
The value 'true' if the value is ETXTBSY.

Return whether the value is EWOULDBLOCK.

Parameters
Returns
The value 'true' if the value is EWOULDBLOCK.