Boost  v1.57.0
doxygen for www.boost.org
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
boost::asio Namespace Reference

Namespaces

 detail
 
 error
 
 generic
 
 ip
 
 placeholders
 
 ssl
 

Classes

class  async_result
 An interface for customising the behaviour of an initiating function. More...
 
class  basic_datagram_socket
 Provides datagram-oriented socket functionality. More...
 
class  basic_io_object
 Base class for all I/O objects. More...
 
class  basic_raw_socket
 Provides raw-oriented socket functionality. More...
 
class  basic_seq_packet_socket
 Provides sequenced packet socket functionality. More...
 
class  basic_signal_set
 Provides signal functionality. More...
 
class  basic_socket
 Provides socket functionality. More...
 
class  basic_socket_acceptor
 Provides the ability to accept new connections. More...
 
class  basic_socket_iostream
 Iostream interface for a socket. More...
 
class  basic_socket_streambuf
 Iostream streambuf for a socket. More...
 
class  basic_stream_socket
 Provides stream-oriented socket functionality. More...
 
singleton  basic_streambuf
 Automatically resizable buffer class based on std::streambuf. More...
 
class  basic_waitable_timer
 Provides waitable timer functionality. More...
 
class  basic_yield_context
 Context object the represents the currently executing coroutine. More...
 
singleton  buffered_read_stream
 Adds buffering to the read-related operations of a stream. More...
 
singleton  buffered_stream
 Adds buffering to the read- and write-related operations of a stream. More...
 
singleton  buffered_write_stream
 Adds buffering to the write-related operations of a stream. More...
 
class  buffers_iterator
 A random access iterator over the bytes in a buffer sequence. More...
 
class  const_buffer
 Holds a buffer that cannot be modified. More...
 
class  const_buffers_1
 Adapts a single non-modifiable buffer so that it meets the requirements of the ConstBufferSequence concept. More...
 
class  coroutine
 Provides support for implementing stackless coroutines. More...
 
class  datagram_socket_service
 Default service implementation for a datagram socket. More...
 
struct  handler_type
 Default handler type traits provided for all handlers. More...
 
struct  handler_type< const Handler &, Signature >
 
struct  handler_type< const Handler, Signature >
 
struct  handler_type< const volatile Handler &, Signature >
 
struct  handler_type< const volatile Handler, Signature >
 
struct  handler_type< Handler &, Signature >
 
struct  handler_type< ReturnType(Arg1), Signature >
 
struct  handler_type< ReturnType(Arg1, Arg2), Signature >
 
struct  handler_type< ReturnType(Arg1, Arg2, Arg3), Signature >
 
struct  handler_type< ReturnType(Arg1, Arg2, Arg3, Arg4), Signature >
 
struct  handler_type< ReturnType(Arg1, Arg2, Arg3, Arg4, Arg5), Signature >
 
struct  handler_type< volatile Handler &, Signature >
 
struct  handler_type< volatile Handler, Signature >
 
class  invalid_service_owner
 Exception thrown when trying to add a service object to an io_service where the service has a different owner. More...
 
class  io_service
 Provides core I/O functionality. More...
 
struct  is_match_condition
 Type trait used to determine whether a type can be used as a match condition function with read_until and async_read_until. More...
 
class  is_read_buffered
 The is_read_buffered class is a traits class that may be used to determine whether a stream type supports buffering of read data. More...
 
class  is_write_buffered
 The is_write_buffered class is a traits class that may be used to determine whether a stream type supports buffering of written data. More...
 
class  mutable_buffer
 Holds a buffer that can be modified. More...
 
class  mutable_buffers_1
 Adapts a single modifiable buffer so that it meets the requirements of the MutableBufferSequence concept. More...
 
class  null_buffers
 An implementation of both the ConstBufferSequence and MutableBufferSequence concepts to represent a null buffer sequence. More...
 
class  raw_socket_service
 Default service implementation for a raw socket. More...
 
class  seq_packet_socket_service
 Default service implementation for a sequenced packet socket. More...
 
class  service_already_exists
 Exception thrown when trying to add a duplicate service to an io_service. More...
 
class  signal_set_service
 Default service implementation for a signal set. More...
 
class  socket_acceptor_service
 Default service implementation for a socket acceptor. More...
 
class  socket_base
 The socket_base class is used as a base for the basic_stream_socket and basic_datagram_socket class templates so that we have a common place to define the shutdown_type and enum. More...
 
class  stream_socket_service
 Default service implementation for a stream socket. More...
 
class  use_future_t
 Class used to specify that an asynchronous operation should return a future. More...
 
struct  wait_traits
 Wait traits suitable for use with the basic_waitable_timer class template. More...
 
class  waitable_timer_service
 Default service implementation for a timer. More...
 

Typedefs

typedef basic_signal_set signal_set
 Typedef for the typical usage of a signal set. More...
 
typedef basic_yield_context
< detail::wrapped_handler
< io_service::strand, void(*)(),
detail::is_continuation_if_running > > 
yield_context
 
typedef
boost::asio::io_service::strand 
strand
 (Deprecated: Use boost::asio::io_service::strand.) Typedef for backwards compatibility. More...
 
typedef basic_streambuf streambuf
 Typedef for the typical usage of basic_streambuf. More...
 

Functions

template<typename Allocator >
std::size_t read_size_helper (basic_streambuf< Allocator > &sb, std::size_t max_size)
 
std::size_t buffer_size (const mutable_buffer &b)
 Get the number of bytes in a modifiable buffer. More...
 
std::size_t buffer_size (const mutable_buffers_1 &b)
 Get the number of bytes in a modifiable buffer. More...
 
std::size_t buffer_size (const const_buffer &b)
 Get the number of bytes in a non-modifiable buffer. More...
 
std::size_t buffer_size (const const_buffers_1 &b)
 Get the number of bytes in a non-modifiable buffer. More...
 
template<typename BufferSequence >
std::size_t buffer_size (const BufferSequence &b)
 Get the total number of bytes in a buffer sequence. More...
 
template<typename PointerToPodType >
PointerToPodType buffer_cast (const mutable_buffer &b)
 Cast a non-modifiable buffer to a specified pointer to POD type. More...
 
template<typename PointerToPodType >
PointerToPodType buffer_cast (const const_buffer &b)
 Cast a non-modifiable buffer to a specified pointer to POD type. More...
 
mutable_buffers_1 buffer (const mutable_buffer &b)
 Create a new modifiable buffer from an existing buffer. More...
 
mutable_buffers_1 buffer (const mutable_buffer &b, std::size_t max_size_in_bytes)
 Create a new modifiable buffer from an existing buffer. More...
 
const_buffers_1 buffer (const const_buffer &b)
 Create a new non-modifiable buffer from an existing buffer. More...
 
const_buffers_1 buffer (const const_buffer &b, std::size_t max_size_in_bytes)
 Create a new non-modifiable buffer from an existing buffer. More...
 
mutable_buffers_1 buffer (void *data, std::size_t size_in_bytes)
 Create a new modifiable buffer that represents the given memory range. More...
 
const_buffers_1 buffer (const void *data, std::size_t size_in_bytes)
 Create a new non-modifiable buffer that represents the given memory range. More...
 
template<typename PodType , std::size_t N>
mutable_buffers_1 buffer (PodType(&data)[N])
 Create a new modifiable buffer that represents the given POD array. More...
 
template<typename PodType , std::size_t N>
mutable_buffers_1 buffer (PodType(&data)[N], std::size_t max_size_in_bytes)
 Create a new modifiable buffer that represents the given POD array. More...
 
template<typename PodType , std::size_t N>
const_buffers_1 buffer (const PodType(&data)[N])
 Create a new non-modifiable buffer that represents the given POD array. More...
 
template<typename PodType , std::size_t N>
const_buffers_1 buffer (const PodType(&data)[N], std::size_t max_size_in_bytes)
 Create a new non-modifiable buffer that represents the given POD array. More...
 
template<typename PodType , std::size_t N>
mutable_buffers_1 buffer (boost::array< PodType, N > &data)
 Create a new modifiable buffer that represents the given POD array. More...
 
template<typename PodType , std::size_t N>
mutable_buffers_1 buffer (boost::array< PodType, N > &data, std::size_t max_size_in_bytes)
 Create a new modifiable buffer that represents the given POD array. More...
 
template<typename PodType , std::size_t N>
const_buffers_1 buffer (boost::array< const PodType, N > &data)
 Create a new non-modifiable buffer that represents the given POD array. More...
 
template<typename PodType , std::size_t N>
const_buffers_1 buffer (boost::array< const PodType, N > &data, std::size_t max_size_in_bytes)
 Create a new non-modifiable buffer that represents the given POD array. More...
 
template<typename PodType , typename Allocator >
mutable_buffers_1 buffer (std::vector< PodType, Allocator > &data)
 Create a new modifiable buffer that represents the given POD vector. More...
 
template<typename PodType , typename Allocator >
mutable_buffers_1 buffer (std::vector< PodType, Allocator > &data, std::size_t max_size_in_bytes)
 Create a new modifiable buffer that represents the given POD vector. More...
 
template<typename PodType , typename Allocator >
const_buffers_1 buffer (const std::vector< PodType, Allocator > &data)
 Create a new non-modifiable buffer that represents the given POD vector. More...
 
template<typename PodType , typename Allocator >
const_buffers_1 buffer (const std::vector< PodType, Allocator > &data, std::size_t max_size_in_bytes)
 Create a new non-modifiable buffer that represents the given POD vector. More...
 
template<typename Elem , typename Traits , typename Allocator >
const_buffers_1 buffer (const std::basic_string< Elem, Traits, Allocator > &data)
 Create a new non-modifiable buffer that represents the given string. More...
 
template<typename Elem , typename Traits , typename Allocator >
const_buffers_1 buffer (const std::basic_string< Elem, Traits, Allocator > &data, std::size_t max_size_in_bytes)
 Create a new non-modifiable buffer that represents the given string. More...
 
std::size_t buffer_copy (const mutable_buffer &target, const const_buffer &source)
 Copies bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffer &target, const const_buffers_1 &source)
 Copies bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffer &target, const mutable_buffer &source)
 Copies bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffer &target, const mutable_buffers_1 &source)
 Copies bytes from a source buffer to a target buffer. More...
 
template<typename ConstBufferSequence >
std::size_t buffer_copy (const mutable_buffer &target, const ConstBufferSequence &source)
 Copies bytes from a source buffer sequence to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffers_1 &target, const const_buffer &source)
 Copies bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffers_1 &target, const const_buffers_1 &source)
 Copies bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffers_1 &target, const mutable_buffer &source)
 Copies bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffers_1 &target, const mutable_buffers_1 &source)
 Copies bytes from a source buffer to a target buffer. More...
 
template<typename ConstBufferSequence >
std::size_t buffer_copy (const mutable_buffers_1 &target, const ConstBufferSequence &source)
 Copies bytes from a source buffer sequence to a target buffer. More...
 
template<typename MutableBufferSequence >
std::size_t buffer_copy (const MutableBufferSequence &target, const const_buffer &source)
 Copies bytes from a source buffer to a target buffer sequence. More...
 
template<typename MutableBufferSequence >
std::size_t buffer_copy (const MutableBufferSequence &target, const const_buffers_1 &source)
 Copies bytes from a source buffer to a target buffer sequence. More...
 
template<typename MutableBufferSequence >
std::size_t buffer_copy (const MutableBufferSequence &target, const mutable_buffer &source)
 Copies bytes from a source buffer to a target buffer sequence. More...
 
template<typename MutableBufferSequence >
std::size_t buffer_copy (const MutableBufferSequence &target, const mutable_buffers_1 &source)
 Copies bytes from a source buffer to a target buffer sequence. More...
 
template<typename MutableBufferSequence , typename ConstBufferSequence >
std::size_t buffer_copy (const MutableBufferSequence &target, const ConstBufferSequence &source)
 Copies bytes from a source buffer sequence to a target buffer sequence. More...
 
std::size_t buffer_copy (const mutable_buffer &target, const const_buffer &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffer &target, const const_buffers_1 &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffer &target, const mutable_buffer &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffer &target, const mutable_buffers_1 &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer. More...
 
template<typename ConstBufferSequence >
std::size_t buffer_copy (const mutable_buffer &target, const ConstBufferSequence &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer sequence to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffers_1 &target, const const_buffer &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffers_1 &target, const const_buffers_1 &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffers_1 &target, const mutable_buffer &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer. More...
 
std::size_t buffer_copy (const mutable_buffers_1 &target, const mutable_buffers_1 &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer. More...
 
template<typename ConstBufferSequence >
std::size_t buffer_copy (const mutable_buffers_1 &target, const ConstBufferSequence &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer sequence to a target buffer. More...
 
template<typename MutableBufferSequence >
std::size_t buffer_copy (const MutableBufferSequence &target, const const_buffer &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer sequence. More...
 
template<typename MutableBufferSequence >
std::size_t buffer_copy (const MutableBufferSequence &target, const const_buffers_1 &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer sequence. More...
 
template<typename MutableBufferSequence >
std::size_t buffer_copy (const MutableBufferSequence &target, const mutable_buffer &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer sequence. More...
 
template<typename MutableBufferSequence >
std::size_t buffer_copy (const MutableBufferSequence &target, const mutable_buffers_1 &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer to a target buffer sequence. More...
 
template<typename MutableBufferSequence , typename ConstBufferSequence >
std::size_t buffer_copy (const MutableBufferSequence &target, const ConstBufferSequence &source, std::size_t max_bytes_to_copy)
 Copies a limited number of bytes from a source buffer sequence to a target buffer sequence. More...
 
template<typename BufferSequence >
buffers_iterator< BufferSequence > buffers_begin (const BufferSequence &buffers)
 Construct an iterator representing the beginning of the buffers' data. More...
 
template<typename BufferSequence >
buffers_iterator< BufferSequence > buffers_end (const BufferSequence &buffers)
 Construct an iterator representing the end of the buffers' data. More...
 
detail::transfer_all_t transfer_all ()
 Return a completion condition function object that indicates that a read or write operation should continue until all of the data has been transferred, or until an error occurs. More...
 
detail::transfer_at_least_t transfer_at_least (std::size_t minimum)
 Return a completion condition function object that indicates that a read or write operation should continue until a minimum number of bytes has been transferred, or until an error occurs. More...
 
detail::transfer_exactly_t transfer_exactly (std::size_t size)
 Return a completion condition function object that indicates that a read or write operation should continue until an exact number of bytes has been transferred, or until an error occurs. More...
 
template<typename Protocol , typename SocketService , typename Iterator >
Iterator connect (basic_socket< Protocol, SocketService > &s, Iterator begin)
 Establishes a socket connection by trying each endpoint in a sequence. More...
 
template<typename Protocol , typename SocketService , typename Iterator >
Iterator connect (basic_socket< Protocol, SocketService > &s, Iterator begin, boost::system::error_code &ec)
 Establishes a socket connection by trying each endpoint in a sequence. More...
 
template<typename Protocol , typename SocketService , typename Iterator >
Iterator connect (basic_socket< Protocol, SocketService > &s, Iterator begin, Iterator end)
 Establishes a socket connection by trying each endpoint in a sequence. More...
 
template<typename Protocol , typename SocketService , typename Iterator >
Iterator connect (basic_socket< Protocol, SocketService > &s, Iterator begin, Iterator end, boost::system::error_code &ec)
 Establishes a socket connection by trying each endpoint in a sequence. More...
 
template<typename Protocol , typename SocketService , typename Iterator , typename ConnectCondition >
Iterator connect (basic_socket< Protocol, SocketService > &s, Iterator begin, ConnectCondition connect_condition)
 Establishes a socket connection by trying each endpoint in a sequence. More...
 
template<typename Protocol , typename SocketService , typename Iterator , typename ConnectCondition >
Iterator connect (basic_socket< Protocol, SocketService > &s, Iterator begin, ConnectCondition connect_condition, boost::system::error_code &ec)
 Establishes a socket connection by trying each endpoint in a sequence. More...
 
template<typename Protocol , typename SocketService , typename Iterator , typename ConnectCondition >
Iterator connect (basic_socket< Protocol, SocketService > &s, Iterator begin, Iterator end, ConnectCondition connect_condition)
 Establishes a socket connection by trying each endpoint in a sequence. More...
 
template<typename Protocol , typename SocketService , typename Iterator , typename ConnectCondition >
Iterator connect (basic_socket< Protocol, SocketService > &s, Iterator begin, Iterator end, ConnectCondition connect_condition, boost::system::error_code &ec)
 Establishes a socket connection by trying each endpoint in a sequence. More...
 
template<typename Protocol , typename SocketService , typename Iterator , typename ComposedConnectHandler >
 BOOST_ASIO_INITFN_RESULT_TYPE (ComposedConnectHandler, void(boost::system::error_code, Iterator)) async_connect(basic_socket< Protocol
 Asynchronously establishes a socket connection by trying each endpoint in a sequence. More...
 
SocketService Iterator BOOST_ASIO_MOVE_ARG (ComposedConnectHandler) handler)
 
template<typename Protocol , typename SocketService , typename Iterator , typename ConnectCondition , typename ComposedConnectHandler >
 BOOST_ASIO_INITFN_RESULT_TYPE (ComposedConnectHandler, void(boost::system::error_code, Iterator)) async_connect(basic_socket< Protocol
 Asynchronously establishes a socket connection by trying each endpoint in a sequence. More...
 
BOOST_ASIO_DECL void * asio_handler_allocate (std::size_t size,...)
 Default allocation function for handlers. More...
 
BOOST_ASIO_DECL void asio_handler_deallocate (void *pointer, std::size_t size,...)
 Default deallocation function for handlers. More...
 
bool asio_handler_is_continuation (...)
 Default continuation function for handlers. More...
 
template<typename Function >
void asio_handler_invoke (Function &function,...)
 Default handler invocation hook used for non-const function objects. More...
 
template<typename Function >
void asio_handler_invoke (const Function &function,...)
 Default handler invocation hook used for const function objects. More...
 
template<typename Service >
Service & use_service (io_service &ios)
 
template<typename Service >
void add_service (io_service &ios, Service *svc)
 
template<typename Service >
bool has_service (io_service &ios)
 
template<typename SyncReadStream , typename MutableBufferSequence >
std::size_t read (SyncReadStream &s, const MutableBufferSequence &buffers)
 Attempt to read a certain amount of data from a stream before returning. More...
 
template<typename SyncReadStream , typename MutableBufferSequence >
std::size_t read (SyncReadStream &s, const MutableBufferSequence &buffers, boost::system::error_code &ec)
 Attempt to read a certain amount of data from a stream before returning. More...
 
template<typename SyncReadStream , typename MutableBufferSequence , typename CompletionCondition >
std::size_t read (SyncReadStream &s, const MutableBufferSequence &buffers, CompletionCondition completion_condition)
 Attempt to read a certain amount of data from a stream before returning. More...
 
template<typename SyncReadStream , typename MutableBufferSequence , typename CompletionCondition >
std::size_t read (SyncReadStream &s, const MutableBufferSequence &buffers, CompletionCondition completion_condition, boost::system::error_code &ec)
 Attempt to read a certain amount of data from a stream before returning. More...
 
template<typename SyncReadStream , typename Allocator >
std::size_t read (SyncReadStream &s, basic_streambuf< Allocator > &b)
 Attempt to read a certain amount of data from a stream before returning. More...
 
template<typename SyncReadStream , typename Allocator >
std::size_t read (SyncReadStream &s, basic_streambuf< Allocator > &b, boost::system::error_code &ec)
 Attempt to read a certain amount of data from a stream before returning. More...
 
template<typename SyncReadStream , typename Allocator , typename CompletionCondition >
std::size_t read (SyncReadStream &s, basic_streambuf< Allocator > &b, CompletionCondition completion_condition)
 Attempt to read a certain amount of data from a stream before returning. More...
 
template<typename SyncReadStream , typename Allocator , typename CompletionCondition >
std::size_t read (SyncReadStream &s, basic_streambuf< Allocator > &b, CompletionCondition completion_condition, boost::system::error_code &ec)
 Attempt to read a certain amount of data from a stream before returning. More...
 
template<typename AsyncReadStream , typename MutableBufferSequence , typename ReadHandler >
 BOOST_ASIO_INITFN_RESULT_TYPE (ReadHandler, void(boost::system::error_code, std::size_t)) async_read(AsyncReadStream &s
 Start an asynchronous operation to read a certain amount of data from a stream. More...
 
const MutableBufferSequence BOOST_ASIO_MOVE_ARG (ReadHandler) handler)
 
template<typename AsyncReadStream , typename MutableBufferSequence , typename CompletionCondition , typename ReadHandler >
 BOOST_ASIO_INITFN_RESULT_TYPE (ReadHandler, void(boost::system::error_code, std::size_t)) async_read(AsyncReadStream &s
 Start an asynchronous operation to read a certain amount of data from a stream. More...
 
template<typename SyncRandomAccessReadDevice , typename MutableBufferSequence >
std::size_t read_at (SyncRandomAccessReadDevice &d, uint64_t offset, const MutableBufferSequence &buffers)
 Attempt to read a certain amount of data at the specified offset before returning. More...
 
template<typename SyncRandomAccessReadDevice , typename MutableBufferSequence >
std::size_t read_at (SyncRandomAccessReadDevice &d, uint64_t offset, const MutableBufferSequence &buffers, boost::system::error_code &ec)
 Attempt to read a certain amount of data at the specified offset before returning. More...
 
template<typename SyncRandomAccessReadDevice , typename MutableBufferSequence , typename CompletionCondition >
std::size_t read_at (SyncRandomAccessReadDevice &d, uint64_t offset, const MutableBufferSequence &buffers, CompletionCondition completion_condition)
 Attempt to read a certain amount of data at the specified offset before returning. More...
 
template<typename SyncRandomAccessReadDevice , typename MutableBufferSequence , typename CompletionCondition >
std::size_t read_at (SyncRandomAccessReadDevice &d, uint64_t offset, const MutableBufferSequence &buffers, CompletionCondition completion_condition, boost::system::error_code &ec)
 Attempt to read a certain amount of data at the specified offset before returning. More...
 
template<typename SyncRandomAccessReadDevice , typename Allocator >
std::size_t read_at (SyncRandomAccessReadDevice &d, uint64_t offset, basic_streambuf< Allocator > &b)
 Attempt to read a certain amount of data at the specified offset before returning. More...
 
template<typename SyncRandomAccessReadDevice , typename Allocator >
std::size_t read_at (SyncRandomAccessReadDevice &d, uint64_t offset, basic_streambuf< Allocator > &b, boost::system::error_code &ec)
 Attempt to read a certain amount of data at the specified offset before returning. More...
 
template<typename SyncRandomAccessReadDevice , typename Allocator , typename CompletionCondition >
std::size_t read_at (SyncRandomAccessReadDevice &d, uint64_t offset, basic_streambuf< Allocator > &b, CompletionCondition completion_condition)
 Attempt to read a certain amount of data at the specified offset before returning. More...
 
template<typename SyncRandomAccessReadDevice , typename Allocator , typename CompletionCondition >
std::size_t read_at (SyncRandomAccessReadDevice &d, uint64_t offset, basic_streambuf< Allocator > &b, CompletionCondition completion_condition, boost::system::error_code &ec)
 Attempt to read a certain amount of data at the specified offset before returning. More...
 
template<typename SyncReadStream , typename Allocator >
std::size_t read_until (SyncReadStream &s, boost::asio::basic_streambuf< Allocator > &b, char delim)
 Read data into a streambuf until it contains a specified delimiter. More...
 
template<typename SyncReadStream , typename Allocator >
std::size_t read_until (SyncReadStream &s, boost::asio::basic_streambuf< Allocator > &b, char delim, boost::system::error_code &ec)
 Read data into a streambuf until it contains a specified delimiter. More...
 
template<typename SyncReadStream , typename Allocator >
std::size_t read_until (SyncReadStream &s, boost::asio::basic_streambuf< Allocator > &b, const std::string &delim)
 Read data into a streambuf until it contains a specified delimiter. More...
 
template<typename SyncReadStream , typename Allocator >
std::size_t read_until (SyncReadStream &s, boost::asio::basic_streambuf< Allocator > &b, const std::string &delim, boost::system::error_code &ec)
 Read data into a streambuf until it contains a specified delimiter. More...
 
template<typename SyncReadStream , typename Allocator , typename MatchCondition >
std::size_t read_until (SyncReadStream &s, boost::asio::basic_streambuf< Allocator > &b, MatchCondition match_condition, typename enable_if< is_match_condition< MatchCondition >::value >::type *=0)
 Read data into a streambuf until a function object indicates a match. More...
 
template<typename SyncReadStream , typename Allocator , typename MatchCondition >
std::size_t read_until (SyncReadStream &s, boost::asio::basic_streambuf< Allocator > &b, MatchCondition match_condition, boost::system::error_code &ec, typename enable_if< is_match_condition< MatchCondition >::value >::type *=0)
 Read data into a streambuf until a function object indicates a match. More...
 
template<typename Handler , typename Function >
void spawn (BOOST_ASIO_MOVE_ARG(Handler) handler, BOOST_ASIO_MOVE_ARG(Function) function, const boost::coroutines::attributes &attributes=boost::coroutines::attributes())
 Start a new stackful coroutine, calling the specified handler when it completes. More...
 
template<typename Handler , typename Function >
void spawn (basic_yield_context< Handler > ctx, BOOST_ASIO_MOVE_ARG(Function) function, const boost::coroutines::attributes &attributes=boost::coroutines::attributes())
 Start a new stackful coroutine, inheriting the execution context of another. More...
 
template<typename Function >
void spawn (boost::asio::io_service::strand strand, BOOST_ASIO_MOVE_ARG(Function) function, const boost::coroutines::attributes &attributes=boost::coroutines::attributes())
 Start a new stackful coroutine that executes in the context of a strand. More...
 
template<typename Function >
void spawn (boost::asio::io_service &io_service, BOOST_ASIO_MOVE_ARG(Function) function, const boost::coroutines::attributes &attributes=boost::coroutines::attributes())
 Start a new stackful coroutine that executes on a given io_service. More...
 
template<typename SyncWriteStream , typename ConstBufferSequence >
std::size_t write (SyncWriteStream &s, const ConstBufferSequence &buffers)
 Write all of the supplied data to a stream before returning. More...
 
template<typename SyncWriteStream , typename ConstBufferSequence >
std::size_t write (SyncWriteStream &s, const ConstBufferSequence &buffers, boost::system::error_code &ec)
 Write all of the supplied data to a stream before returning. More...
 
template<typename SyncWriteStream , typename ConstBufferSequence , typename CompletionCondition >
std::size_t write (SyncWriteStream &s, const ConstBufferSequence &buffers, CompletionCondition completion_condition)
 Write a certain amount of data to a stream before returning. More...
 
template<typename SyncWriteStream , typename ConstBufferSequence , typename CompletionCondition >
std::size_t write (SyncWriteStream &s, const ConstBufferSequence &buffers, CompletionCondition completion_condition, boost::system::error_code &ec)
 Write a certain amount of data to a stream before returning. More...
 
template<typename SyncWriteStream , typename Allocator >
std::size_t write (SyncWriteStream &s, basic_streambuf< Allocator > &b)
 Write all of the supplied data to a stream before returning. More...
 
template<typename SyncWriteStream , typename Allocator >
std::size_t write (SyncWriteStream &s, basic_streambuf< Allocator > &b, boost::system::error_code &ec)
 Write all of the supplied data to a stream before returning. More...
 
template<typename SyncWriteStream , typename Allocator , typename CompletionCondition >
std::size_t write (SyncWriteStream &s, basic_streambuf< Allocator > &b, CompletionCondition completion_condition)
 Write a certain amount of data to a stream before returning. More...
 
template<typename SyncWriteStream , typename Allocator , typename CompletionCondition >
std::size_t write (SyncWriteStream &s, basic_streambuf< Allocator > &b, CompletionCondition completion_condition, boost::system::error_code &ec)
 Write a certain amount of data to a stream before returning. More...
 
template<typename AsyncWriteStream , typename ConstBufferSequence , typename WriteHandler >
 BOOST_ASIO_INITFN_RESULT_TYPE (WriteHandler, void(boost::system::error_code, std::size_t)) async_write(AsyncWriteStream &s
 Start an asynchronous operation to write all of the supplied data to a stream. More...
 
const ConstBufferSequence BOOST_ASIO_MOVE_ARG (WriteHandler) handler)
 
template<typename AsyncWriteStream , typename ConstBufferSequence , typename CompletionCondition , typename WriteHandler >
 BOOST_ASIO_INITFN_RESULT_TYPE (WriteHandler, void(boost::system::error_code, std::size_t)) async_write(AsyncWriteStream &s
 Start an asynchronous operation to write a certain amount of data to a stream. More...
 
template<typename SyncRandomAccessWriteDevice , typename ConstBufferSequence >
std::size_t write_at (SyncRandomAccessWriteDevice &d, uint64_t offset, const ConstBufferSequence &buffers)
 Write all of the supplied data at the specified offset before returning. More...
 
template<typename SyncRandomAccessWriteDevice , typename ConstBufferSequence >
std::size_t write_at (SyncRandomAccessWriteDevice &d, uint64_t offset, const ConstBufferSequence &buffers, boost::system::error_code &ec)
 Write all of the supplied data at the specified offset before returning. More...
 
template<typename SyncRandomAccessWriteDevice , typename ConstBufferSequence , typename CompletionCondition >
std::size_t write_at (SyncRandomAccessWriteDevice &d, uint64_t offset, const ConstBufferSequence &buffers, CompletionCondition completion_condition)
 Write a certain amount of data at a specified offset before returning. More...
 
template<typename SyncRandomAccessWriteDevice , typename ConstBufferSequence , typename CompletionCondition >
std::size_t write_at (SyncRandomAccessWriteDevice &d, uint64_t offset, const ConstBufferSequence &buffers, CompletionCondition completion_condition, boost::system::error_code &ec)
 Write a certain amount of data at a specified offset before returning. More...
 
template<typename SyncRandomAccessWriteDevice , typename Allocator >
std::size_t write_at (SyncRandomAccessWriteDevice &d, uint64_t offset, basic_streambuf< Allocator > &b)
 Write all of the supplied data at the specified offset before returning. More...
 
template<typename SyncRandomAccessWriteDevice , typename Allocator >
std::size_t write_at (SyncRandomAccessWriteDevice &d, uint64_t offset, basic_streambuf< Allocator > &b, boost::system::error_code &ec)
 Write all of the supplied data at the specified offset before returning. More...
 
template<typename SyncRandomAccessWriteDevice , typename Allocator , typename CompletionCondition >
std::size_t write_at (SyncRandomAccessWriteDevice &d, uint64_t offset, basic_streambuf< Allocator > &b, CompletionCondition completion_condition)
 Write a certain amount of data at a specified offset before returning. More...
 
template<typename SyncRandomAccessWriteDevice , typename Allocator , typename CompletionCondition >
std::size_t write_at (SyncRandomAccessWriteDevice &d, uint64_t offset, basic_streambuf< Allocator > &b, CompletionCondition completion_condition, boost::system::error_code &ec)
 Write a certain amount of data at a specified offset before returning. More...
 

Variables

SocketService & s
 
SocketService Iterator begin
 
SocketService Iterator Iterator end
 
SocketService Iterator
ConnectCondition 
connect_condition
 
const MutableBufferSequence & buffers
 
const MutableBufferSequence
CompletionCondition 
completion_condition
 
basic_streambuf< Allocator > & b
 
basic_streambuf< Allocator > BOOST_ASIO_MOVE_ARG (ReadHandler) handler)
 
uint64_t offset
 
boost::asio::basic_streambuf
< Allocator > char 
delim
 
boost::asio::basic_streambuf
< Allocator > MatchCondition 
match_condition
 

Typedef Documentation

Typedef for the typical usage of a signal set.

(Deprecated: Use boost::asio::io_service::strand.) Typedef for backwards compatibility.

Typedef for the typical usage of basic_streambuf.

typedef basic_yield_context< detail::wrapped_handler< io_service::strand, void(*)(), detail::is_continuation_if_running> > boost::asio::yield_context

Function Documentation

template<typename Service >
void boost::asio::add_service ( io_service &  ios,
Service *  svc 
)

This function is used to add a service to the io_service.

Parameters
iosThe io_service object that owns the service.
svcThe service object. On success, ownership of the service object is transferred to the io_service. When the io_service object is destroyed, it will destroy the service object by performing:
delete static_cast<io_service::service*>(svc)
Exceptions
boost::asio::service_already_existsThrown if a service of the given type is already present in the io_service.
boost::asio::invalid_service_ownerThrown if the service's owning io_service is not the io_service object specified by the ios parameter.
BOOST_ASIO_DECL void* boost::asio::asio_handler_allocate ( std::size_t  size,
  ... 
)

Default allocation function for handlers.

Asynchronous operations may need to allocate temporary objects. Since asynchronous operations have a handler function object, these temporary objects can be said to be associated with the handler.

Implement asio_handler_allocate and asio_handler_deallocate for your own handlers to provide custom allocation for these temporary objects.

The default implementation of these allocation hooks uses ::operator new and operator delete.

Note
All temporary objects associated with a handler will be deallocated before the upcall to the handler is performed. This allows the same memory to be reused for a subsequent asynchronous operation initiated by the handler.
Example
class my_handler;
void* asio_handler_allocate(std::size_t size, my_handler* context)
{
return ::operator new(size);
}
void asio_handler_deallocate(void* pointer, std::size_t size,
my_handler* context)
{
::operator delete(pointer);
}
BOOST_ASIO_DECL void boost::asio::asio_handler_deallocate ( void *  pointer,
std::size_t  size,
  ... 
)

Default deallocation function for handlers.

Implement asio_handler_allocate and asio_handler_deallocate for your own handlers to provide custom allocation for the associated temporary objects.

The default implementation of these allocation hooks uses ::operator new and operator delete.

See also
asio_handler_allocate.
bool boost::asio::asio_handler_is_continuation (   ...)
inline

Default continuation function for handlers.

Asynchronous operations may represent a continuation of the asynchronous control flow associated with the current handler. The implementation can use this knowledge to optimise scheduling of the handler.

Implement asio_handler_is_continuation for your own handlers to indicate when a handler represents a continuation.

The default implementation of the continuation hook returns false.

Example
class my_handler;
{
return true;
}
template<typename BufferSequence >
buffers_iterator<BufferSequence> boost::asio::buffers_begin ( const BufferSequence &  buffers)
inline

Construct an iterator representing the beginning of the buffers' data.

References boost::asio::buffers_iterator< BufferSequence, ByteType >::begin().

template<typename BufferSequence >
buffers_iterator<BufferSequence> boost::asio::buffers_end ( const BufferSequence &  buffers)
inline

Construct an iterator representing the end of the buffers' data.

References boost::asio::buffers_iterator< BufferSequence, ByteType >::end().

template<typename Service >
bool boost::asio::has_service ( io_service &  ios)

This function is used to determine whether the io_service contains a service object corresponding to the given service type.

Parameters
iosThe io_service object that owns the service.
Returns
A boolean indicating whether the io_service contains the service.
template<typename Allocator >
std::size_t boost::asio::read_size_helper ( basic_streambuf< Allocator > &  sb,
std::size_t  max_size 
)
inline
template<typename Service >
Service& boost::asio::use_service ( io_service &  ios)

This function is used to locate a service object that corresponds to the given service type. If there is no existing implementation of the service, then the io_service will create a new instance of the service.

Parameters
iosThe io_service object that owns the service.
Returns
The service interface implementing the specified service type. Ownership of the service interface is not transferred to the caller.