![]() |
Home | Libraries | People | FAQ | More |
boost::process::async_pipe
// In header: <boost/process/async_pipe.hpp> class async_pipe { public: // types typedef ; typedef ; typedef ; // construct/copy/destruct (); (, ); (, ); (, , ); (async_pipe &); (async_pipe &&); template<typename CharT, typename Traits> (, basic_pipe< ); template<typename CharT, typename Traits> (, , basic_pipe< ); template<typename CharT, typename Traits> async_pipe & (basic_pipe< ); async_pipe & (async_pipe &); async_pipe & (async_pipe &&); ~(); // public member functions template<typename CharT, typename Traits> () ; (); (); (); () ; (); template<typename MutableBufferSequence> (); template<typename MutableBufferSequence> (); () ; () ; template<typename MutableBufferSequence, typename ReadHandler> (, ); template<typename ConstBufferSequence, typename WriteHandler> (, ); () ; () ; (); (); (::); (::); (::) ; (::) ; };
Class implementing an asnychronous I/O-Object for use with boost.asio. It is based on the corresponding I/O Object, that is either boost::asio::windows::stream_handle or boost::asio::posix::stream_descriptor.
It can be used directly with boost::asio::async_read or async_write.
![]() |
Note |
---|---|
The object is copyable, but that does invoke a handle duplicate. |
async_pipe
public
construct/copy/destruct( ios);
Construct a new async_pipe
, does automatically open the pipe. Initializes source and sink with the same io_context.
![]() |
Note |
---|---|
Windows creates a named pipe here, where the name is automatically generated. |
( ios_source, ios_sink);
Construct a new async_pipe
, does automatically open the pipe.
![]() |
Note |
---|---|
Windows creates a named pipe here, where the name is automatically generated. |
( ios, name);
Construct a new async_pipe
, does automatically open. Initializes source and sink with the same io_context.
![]() |
Note |
---|---|
Windows restricts possible names. |
( ios_source, ios_sink, name);
Construct a new async_pipe
, does automatically open.
![]() |
Note |
---|---|
Windows restricts possible names. |
(async_pipe & lhs);
Copy-Constructor of the async pipe.
![]() |
Note |
---|---|
Windows requires a named pipe for this, if a the wrong type is used an exception is thrown. |
(async_pipe && lhs);
Move-Constructor of the async pipe.
template<typename CharT, typename Traits> ( ios, basic_pipe< p);
Construct the async-pipe from a pipe.
![]() |
Note |
---|---|
Windows requires a named pipe for this, if a the wrong type is used an exception is thrown. |
template<typename CharT, typename Traits> ( ios_source, ios_sink, basic_pipe< p);
Construct the async-pipe from a pipe, with two different io_context objects.
![]() |
Note |
---|---|
Windows requires a named pipe for this, if a the wrong type is used an exception is thrown. |
template<typename CharT, typename Traits> async_pipe & (basic_pipe< p);
Assign a basic_pipe
.
![]() |
Note |
---|---|
Windows requires a named pipe for this, if a the wrong type is used an exception is thrown. |
async_pipe & (async_pipe & lhs);
Copy Assign a pipe.
![]() |
Note |
---|---|
Duplicates the handles. |
async_pipe & (async_pipe && lhs);
Move assign a pipe
~();
Destructor. Closes the pipe handles.
async_pipe
public member functionstemplate<typename CharT, typename Traits> () ;
Explicit cast to basic_pipe
.
();
Cancel the current asynchronous operations.
();
Close the pipe handles.
( ec);
Close the pipe handles. While passing an error_code
() ;
Check if the pipes are open.
();
Async close, i.e. close after current operation is completed.
![]() |
Note |
---|---|
There is no guarantee that this will indeed read the entire pipe-buffer |
template<typename MutableBufferSequence> ( buffers);
Read some data from the handle.
See the boost.asio documentation for more details.
template<typename MutableBufferSequence> ( buffers);
Write some data to the handle.
See the boost.asio documentation for more details.
() ;
Get the native handle of the source.
() ;
Get the native handle of the sink.
template<typename MutableBufferSequence, typename ReadHandler> ( buffers, handler);
Start an asynchronous read.
See the boost.asio documentation for more details.
template<typename ConstBufferSequence, typename WriteHandler> ( buffers, handler);
Start an asynchronous write.
See the boost.asio documentation for more details.
() ;Get the asio handle of the pipe sink.
() ;Get the asio handle of the pipe source.
();Get the asio handle of the pipe sink. Qualified as rvalue.
();Get the asio handle of the pipe source. Qualified as rvalue.
(:: ios);Move the source out of this class and change the io_context. Qualified as rvalue.
![]() |
Note |
---|---|
Will always move. |
(:: ios);Move the sink out of this class and change the io_context. Qualified as rvalue.
![]() |
Note |
---|---|
Will always move |
(:: ios) ;Copy the source out of this class and change the io_context.
![]() |
Note |
---|---|
Will always copy. |
(:: ios) ;Copy the sink out of this class and change the io_context.
![]() |
Note |
---|---|
Will always copy |