JX Application Framework
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Protected Member Functions | List of all members
JOutPipeStreambuf< _CharT, _Traits > Class Template Reference

#include <JOutPipeStreambuf.h>

Inheritance diagram for JOutPipeStreambuf< _CharT, _Traits >:
[legend]

Public Types

using int_type = typename std::basic_streambuf< _CharT, _Traits >::int_type
 

Public Member Functions

 JOutPipeStreambuf (const int fd, const bool close)
 
 ~JOutPipeStreambuf () override
 
int GetDescriptor ()
 
bool WillClosePipe () const
 
void ShouldClosePipe (const bool close=true)
 
void close ()
 

Protected Member Functions

std::streamsize xsputn (const _CharT *s, std::streamsize n) override
 
int_type overflow (int_type c) override
 

Detailed Description

template<typename _CharT, typename _Traits = std::char_traits<_CharT>>
class JOutPipeStreambuf< _CharT, _Traits >
This class implements an unbuffered streambuf for the write end of a pipe.

http://www.horstmann.com/cpp/iostreams.html
http://www.codeproject.com/vcpp/stl/custom_iostream_streams.asp

Member Typedef Documentation

◆ int_type

template<typename _CharT , typename _Traits = std::char_traits<_CharT>>
using JOutPipeStreambuf< _CharT, _Traits >::int_type = typename std::basic_streambuf<_CharT, _Traits>::int_type

Constructor & Destructor Documentation

◆ JOutPipeStreambuf()

template<typename _CharT , typename _Traits >
JOutPipeStreambuf< _CharT, _Traits >::JOutPipeStreambuf ( const int  fd,
const bool  close 
)

◆ ~JOutPipeStreambuf()

template<typename _CharT , typename _Traits >
JOutPipeStreambuf< _CharT, _Traits >::~JOutPipeStreambuf ( )
override

Member Function Documentation

◆ close()

template<typename _CharT , typename _Traits >
void JOutPipeStreambuf< _CharT, _Traits >::close ( )

This only closes the underlying file descriptor if itsCloseFlag is set.

◆ GetDescriptor()

template<typename _CharT , typename _Traits >
int JOutPipeStreambuf< _CharT, _Traits >::GetDescriptor ( )

◆ overflow()

template<typename _CharT , typename _Traits >
JOutPipeStreambuf< _CharT, _Traits >::int_type JOutPipeStreambuf< _CharT, _Traits >::overflow ( int_type  c)
overrideprotected

◆ ShouldClosePipe()

template<typename _CharT , typename _Traits >
void JOutPipeStreambuf< _CharT, _Traits >::ShouldClosePipe ( const bool  close = true)

◆ WillClosePipe()

template<typename _CharT , typename _Traits >
bool JOutPipeStreambuf< _CharT, _Traits >::WillClosePipe ( ) const

◆ xsputn()

template<typename _CharT , typename _Traits >
std::streamsize JOutPipeStreambuf< _CharT, _Traits >::xsputn ( const _CharT *  s,
std::streamsize  n 
)
overrideprotected

The documentation for this class was generated from the following files: