#include <pstream.h>
Inheritance diagram for redi::pstream_common< CharT, Traits >:

Public Types | |
| typedef streambuf_type::pmode | pmode |
| Type used to specify how to connect to the process. | |
Public Member Functions | |
| pstream_common () | |
| Default constructor. | |
| pstream_common (const std::string &command, pmode mode) | |
| Constructor that initialises the stream by starting a process. | |
| pstream_common (const std::string &file, const std::vector< std::string > &argv, pmode mode) | |
| Constructor that initialises the stream by starting a process. | |
| virtual void | open (const std::string &command, pmode mode) |
| Start a process. | |
| virtual void | open (const std::string &file, const std::vector< std::string > &argv, pmode mode) |
| Start a process. | |
| void | close () |
| Close the pipe. | |
| bool | is_open () const |
| Report whether the stream's buffer has been initialised. | |
| const std::string & | command () const |
| Return the command used to initialise the stream. | |
| streambuf_type * | rdbuf () const |
| Return a pointer to the stream buffer. | |
Protected Types | |
|
typedef basic_pstreambuf< CharT, Traits > | streambuf_type |
Protected Member Functions | |
| virtual | ~pstream_common ()=0 |
| Pure virtual destructor. | |
Protected Attributes | |
| std::string | command_ |
| The command used to start the process. | |
| streambuf_type | buf_ |
| The stream buffer. | |
Abstract Base Class providing common functionality for basic_ipstream, basic_opstream and basic_pstream. pstream_common manages the basic_pstreambuf stream buffer that is used by the derived classes to initialise an IOStream class.
|
|||||||||
|
Default constructor. Creates an uninitialised stream. |
|
||||||||||||||||
|
Constructor that initialises the stream by starting a process. Initialises the stream buffer by calling open() with the supplied arguments.
|
|
||||||||||||||||||||
|
Constructor that initialises the stream by starting a process. Initialises the stream buffer by calling open() with the supplied arguments.
|
|
|||||||||
|
Pure virtual destructor.
This is a pure virtual function to make
|
|
|||||||||
|
Close the pipe. Waits for the associated process to finish and closes the pipe. |
|
|||||||||
|
Return the command used to initialise the stream.
|
|
|||||||||
|
Report whether the stream's buffer has been initialised.
|
|
||||||||||||||||||||
|
Start a process. Starts a new process by executing file with the arguments in argv and opens pipes to the process as given by mode.
Reimplemented in redi::basic_ipstream< CharT, Traits >, redi::basic_opstream< CharT, Traits >, redi::basic_pstream< CharT, Traits >, and redi::basic_rpstream< CharT, Traits >. |
|
||||||||||||||||
|
Start a process. Starts a new process by passing command to the shell and opens pipes to the process as given by mode.
Reimplemented in redi::basic_ipstream< CharT, Traits >, redi::basic_opstream< CharT, Traits >, redi::basic_pstream< CharT, Traits >, and redi::basic_rpstream< CharT, Traits >. |
|
|||||||||
|
Return a pointer to the stream buffer.
|
1.3.2