Boost
C++ Libraries
...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
This version of Boost is under active development. You are currently in the develop branch. The current version is 1.91.0.
The file type when rebound to the specified executor.
typedef basic_file< Executor1 > other;
|
Name |
Description |
|---|---|
|
Rebinds the file type to another executor. |
|
|
The type of the executor associated with the object. |
|
|
A bitmask type (C++ Std [lib.bitmask.types]). |
|
|
The native representation of a file. |
|
|
Basis for seeking in a file. |
|
Name |
Description |
|---|---|
|
Assign an existing native file to the file. |
|
|
basic_file [constructor] |
Construct a basic_file without opening it. |
|
Cancel all asynchronous operations associated with the file. |
|
|
Close the file. |
|
|
Get the executor associated with the object. |
|
|
Determine whether the file is open. |
|
|
Get the native file representation. |
|
|
Open the file using the specified path. |
|
|
Move-assign a basic_file from another. |
|
|
Release ownership of the underlying native file. |
|
|
Alter the size of the file. |
|
|
Get the size of the file. |
|
|
Synchronise the file to disk. |
|
|
Synchronise the file data to disk. |
|
Name |
Description |
|---|---|
|
~basic_file [destructor] |
Protected destructor to prevent deletion through this type. |
|
Name |
Description |
|---|---|
|
append [static] |
Open the file in append mode. |
|
create [static] |
Create the file if it does not exist. |
|
exclusive [static] |
Ensure a new file is created. Must be combined with create. |
|
read_only [static] |
Open the file for reading. |
|
read_write [static] |
Open the file for reading and writing. |
|
sync_all_on_write [static] |
Open the file so that write operations automatically synchronise the file data and metadata to disk. |
|
truncate [static] |
Open the file with any existing contents truncated. |
|
write_only [static] |
Open the file for writing. |
The basic_file
class template provides functionality that is common to both stream-oriented
and random-access files.
Distinct objects: Safe.
Shared objects: Unsafe.
Header: boost/asio/basic_file.hpp
Convenience header: boost/asio.hpp