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 is the documentation for an old version of Boost. Click here to view this page for the latest version.
PrevUpHomeNext

posix::basic_descriptor

Provides POSIX descriptor functionality.

template<
    typename Executor = any_io_executor>
class basic_descriptor :
  public posix::descriptor_base
Types

Name

Description

rebind_executor

Rebinds the descriptor type to another executor.

bytes_readable

IO control command to get the amount of data that can be read without blocking.

executor_type

The type of the executor associated with the object.

lowest_layer_type

A descriptor is always the lowest layer.

native_handle_type

The native representation of a descriptor.

wait_type

Wait types.

Member Functions

Name

Description

assign

Assign an existing native descriptor to the descriptor.

async_wait

Asynchronously wait for the descriptor to become ready to read, ready to write, or to have pending error conditions.

basic_descriptor [constructor]

Construct a descriptor without opening it.

Construct a descriptor on an existing native descriptor.

Move-construct a descriptor from another.

Move-construct a basic_descriptor from a descriptor of another executor type.

cancel

Cancel all asynchronous operations associated with the descriptor.

close

Close the descriptor.

get_executor

Get the executor associated with the object.

io_control

Perform an IO control command on the descriptor.

is_open

Determine whether the descriptor is open.

lowest_layer

Get a reference to the lowest layer.

Get a const reference to the lowest layer.

native_handle

Get the native descriptor representation.

native_non_blocking

Gets the non-blocking mode of the native descriptor implementation.

Sets the non-blocking mode of the native descriptor implementation.

non_blocking

Gets the non-blocking mode of the descriptor.

Sets the non-blocking mode of the descriptor.

operator=

Move-assign a descriptor from another.

Move-assign a basic_descriptor from a descriptor of another executor type.

release

Release ownership of the native descriptor implementation.

wait

Wait for the descriptor to become ready to read, ready to write, or to have pending error conditions.

Protected Member Functions

Name

Description

~basic_descriptor [destructor]

Protected destructor to prevent deletion through this type.

The posix::basic_descriptor class template provides the ability to wrap a POSIX descriptor.

Thread Safety

Distinct objects: Safe.

Shared objects: Unsafe.

Requirements

Header: boost/asio/posix/basic_descriptor.hpp

Convenience header: boost/asio.hpp


PrevUpHomeNext