# Poco

# class PipeStreamBuf

Library: Foundation
Package: Processes
Header: Poco/PipeStream.h

## Description

This is the streambuf class used for reading from and writing to a Pipe.

## Inheritance

Direct Base Classes: BufferedStreamBuf

All Base Classes: BufferedStreamBuf

## Member Summary

Member Functions: close, readFromDevice, writeToDevice

## Types Aliases

### openmode

using openmode = BufferedStreamBuf::openmode;

## Constructors

### PipeStreamBuf

PipeStreamBuf(
const Pipe & pipe,
openmode mode
);

Creates a PipeStreamBuf with the given Pipe.

## Destructor

### ~PipeStreamBuf

~PipeStreamBuf() override;

Destroys the PipeStreamBuf.

## Member Functions

### close

void close();

Closes the pipe.

### readFromDevice

std::streamsize readFromDevice(
char * buffer,
std::streamsize length
) override;

### writeToDevice

std::streamsize writeToDevice(
const char * buffer,
std::streamsize length
) override;