Teuchos::basic_FancyOStream_buf< CharT, Traits > Class Template Reference

Stream buffering class that performs the magic of indenting data sent to an std::ostream object. More...

#include <Teuchos_FancyOStream.hpp>

List of all members.

Public Types

typedef CharT char_type
 
typedef Traits traits_type
 
typedef traits_type::int_type int_type
 
typedef traits_type::pos_type pos_type
 
typedef traits_type::off_type off_type
 

Public Member Functions

 basic_FancyOStream_buf (const RCP< std::basic_ostream< char_type, traits_type > > &oStream, const std::basic_string< char_type, traits_type > &tabIndentStr, const int startingTab, const bool showLinePrefix, const int maxLenLinePrefix, const bool showTabCount, const bool showProcRank)
 
void initialize (const RCP< std::basic_ostream< char_type, traits_type > > &oStream, const std::basic_string< char_type, traits_type > &tabIndentStr, const int startingTab, const bool showLinePrefix, const int maxLenLinePrefix, const bool showTabCount, const bool showProcRank)
 
RCP< std::basic_ostream
< char_type, traits_type > > 
getOStream ()
 
void setTabIndentStr (const std::basic_string< char_type, traits_type > &tabIndentStr)
 
const std::basic_string
< char_type, traits_type > & 
getTabIndentStr () const
 
void setShowLinePrefix (const bool showLinePrefix)
 
bool getShowLinePrefix () const
 
void setMaxLenLinePrefix (const int maxLenLinePrefix)
 
int getMaxLenLinePrefix () const
 
void setShowTabCount (const bool showTabCount)
 
bool getShowTabCount () const
 
void setShowProcRank (const bool showProcRank)
 
bool getShowProcRank () const
 
void setProcRankAndSize (const int procRank, const int numProcs)
 
int getProcRank () const
 
int getNumProcs () const
 
void setOutputToRootOnly (const int rootRank)
 
int getOutputToRootOnly () const
 
void pushTab (const int tabs)
 
int getNumCurrTabs () const
 
void popTab ()
 
void pushLinePrefix (const std::basic_string< char_type, traits_type > &linePrefix)
 
void popLinePrefix ()
 
const std::basic_string
< char_type, traits_type > & 
getTopLinePrefix () const
 
void pushDisableTabbing ()
 
void popDisableTabbing ()
 

Private Types

typedef std::basic_string
< char_type, traits_type
string_t
typedef std::deque< int > tabIndentStack_t
typedef std::deque< string_tlinePrefixStack_t

Private Member Functions

std::ostream & out ()
void writeChars (const char_type s[], std::streamsize n)
void writeFrontMatter ()
 basic_FancyOStream_buf ()
 basic_FancyOStream_buf (const basic_FancyOStream_buf< CharT, Traits > &)
basic_FancyOStream_buf< CharT,
Traits > 
operator= (const basic_FancyOStream_buf< CharT, Traits > &)

Private Attributes

RCP< std::basic_ostream
< char_type, traits_type > > 
oStreamSet_
RCP< std::basic_ostream
< char_type, traits_type > > 
oStream_
std::basic_string< char_type,
traits_type
tabIndentStr_
bool showLinePrefix_
int maxLenLinePrefix_
bool showTabCount_
bool showProcRank_
int rootRank_
int procRank_
int numProcs_
int rankPrintWidth_
RCP< std::ostringstream > lineOut_
int tabIndent_
tabIndentStack_t tabIndentStack_
linePrefixStack_t linePrefixStack_
int enableTabbingStack_
bool wroteNewline_

Protected overridden functions from std::basic_streambuf



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

Detailed Description

template<typename CharT, typename Traits>
class Teuchos::basic_FancyOStream_buf< CharT, Traits >

Stream buffering class that performs the magic of indenting data sent to an std::ostream object.

Note, this is not a user-level class. Users should use basic_FancyOStream.

Definition at line 50 of file Teuchos_FancyOStream.hpp.


Member Typedef Documentation

template<typename CharT, typename Traits>
typedef CharT Teuchos::basic_FancyOStream_buf< CharT, Traits >::char_type

Definition at line 55 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
typedef Traits Teuchos::basic_FancyOStream_buf< CharT, Traits >::traits_type

Definition at line 57 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
typedef traits_type::int_type Teuchos::basic_FancyOStream_buf< CharT, Traits >::int_type

Definition at line 59 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
typedef traits_type::pos_type Teuchos::basic_FancyOStream_buf< CharT, Traits >::pos_type

Definition at line 61 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
typedef traits_type::off_type Teuchos::basic_FancyOStream_buf< CharT, Traits >::off_type

Definition at line 63 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
typedef std::basic_string<char_type,traits_type> Teuchos::basic_FancyOStream_buf< CharT, Traits >::string_t [private]

Definition at line 252 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
typedef std::deque<int> Teuchos::basic_FancyOStream_buf< CharT, Traits >::tabIndentStack_t [private]

Definition at line 253 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
typedef std::deque<string_t> Teuchos::basic_FancyOStream_buf< CharT, Traits >::linePrefixStack_t [private]

Definition at line 254 of file Teuchos_FancyOStream.hpp.


Constructor & Destructor Documentation

template<typename CharT , typename Traits >
Teuchos::basic_FancyOStream_buf< CharT, Traits >::basic_FancyOStream_buf ( const RCP< std::basic_ostream< char_type, traits_type > > &  oStream,
const std::basic_string< char_type, traits_type > &  tabIndentStr,
const int  startingTab,
const bool  showLinePrefix,
const int  maxLenLinePrefix,
const bool  showTabCount,
const bool  showProcRank 
) [inline]

Definition at line 737 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
Teuchos::basic_FancyOStream_buf< CharT, Traits >::basic_FancyOStream_buf (  )  [private]
template<typename CharT, typename Traits>
Teuchos::basic_FancyOStream_buf< CharT, Traits >::basic_FancyOStream_buf ( const basic_FancyOStream_buf< CharT, Traits > &   )  [private]

Member Function Documentation

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::initialize ( const RCP< std::basic_ostream< char_type, traits_type > > &  oStream,
const std::basic_string< char_type, traits_type > &  tabIndentStr,
const int  startingTab,
const bool  showLinePrefix,
const int  maxLenLinePrefix,
const bool  showTabCount,
const bool  showProcRank 
) [inline]

Definition at line 753 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
RCP< std::basic_ostream< CharT, Traits > > Teuchos::basic_FancyOStream_buf< CharT, Traits >::getOStream (  )  [inline]

Definition at line 784 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::setTabIndentStr ( const std::basic_string< char_type, traits_type > &  tabIndentStr  )  [inline]

Definition at line 791 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
const std::basic_string< CharT, Traits > & Teuchos::basic_FancyOStream_buf< CharT, Traits >::getTabIndentStr (  )  const [inline]

Definition at line 801 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::setShowLinePrefix ( const bool  showLinePrefix  )  [inline]

Definition at line 808 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
bool Teuchos::basic_FancyOStream_buf< CharT, Traits >::getShowLinePrefix (  )  const [inline]

Definition at line 815 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::setMaxLenLinePrefix ( const int  maxLenLinePrefix  )  [inline]

Definition at line 822 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::getMaxLenLinePrefix (  )  const [inline]

Definition at line 830 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::setShowTabCount ( const bool  showTabCount  )  [inline]

Definition at line 837 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
bool Teuchos::basic_FancyOStream_buf< CharT, Traits >::getShowTabCount (  )  const [inline]

Definition at line 844 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::setShowProcRank ( const bool  showProcRank  )  [inline]

Definition at line 851 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
bool Teuchos::basic_FancyOStream_buf< CharT, Traits >::getShowProcRank (  )  const [inline]

Definition at line 858 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::setProcRankAndSize ( const int  procRank,
const int  numProcs 
) [inline]

Definition at line 865 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::getProcRank (  )  const [inline]

Definition at line 875 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::getNumProcs (  )  const [inline]

Definition at line 882 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::setOutputToRootOnly ( const int  rootRank  )  [inline]

Definition at line 889 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::getOutputToRootOnly (  )  const [inline]

Definition at line 913 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::pushTab ( const int  tabs  )  [inline]

Definition at line 920 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::getNumCurrTabs (  )  const [inline]

Definition at line 934 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::popTab (  )  [inline]

Definition at line 941 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::pushLinePrefix ( const std::basic_string< char_type, traits_type > &  linePrefix  )  [inline]

Definition at line 949 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::popLinePrefix (  )  [inline]

Definition at line 958 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
const std::basic_string< CharT, Traits > & Teuchos::basic_FancyOStream_buf< CharT, Traits >::getTopLinePrefix (  )  const [inline]

Definition at line 966 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::pushDisableTabbing (  )  [inline]

Definition at line 973 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::popDisableTabbing (  )  [inline]

Definition at line 980 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
std::streamsize Teuchos::basic_FancyOStream_buf< CharT, Traits >::xsputn ( const char_type s,
std::streamsize  n 
) [inline, protected]

Definition at line 990 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
basic_FancyOStream_buf< CharT, Traits >::int_type Teuchos::basic_FancyOStream_buf< CharT, Traits >::overflow ( int_type  c  )  [inline, protected]

Definition at line 1004 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
std::ostream & Teuchos::basic_FancyOStream_buf< CharT, Traits >::out (  )  [inline, private]

Definition at line 1022 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::writeChars ( const char_type  s[],
std::streamsize  n 
) [inline, private]

Definition at line 1031 of file Teuchos_FancyOStream.hpp.

template<typename CharT , typename Traits >
void Teuchos::basic_FancyOStream_buf< CharT, Traits >::writeFrontMatter (  )  [inline, private]

Definition at line 1077 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
basic_FancyOStream_buf<CharT,Traits> Teuchos::basic_FancyOStream_buf< CharT, Traits >::operator= ( const basic_FancyOStream_buf< CharT, Traits > &   )  [private]

Member Data Documentation

template<typename CharT, typename Traits>
RCP<std::basic_ostream<char_type,traits_type> > Teuchos::basic_FancyOStream_buf< CharT, Traits >::oStreamSet_ [private]

Definition at line 259 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
RCP<std::basic_ostream<char_type,traits_type> > Teuchos::basic_FancyOStream_buf< CharT, Traits >::oStream_ [private]

Definition at line 260 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
std::basic_string<char_type,traits_type> Teuchos::basic_FancyOStream_buf< CharT, Traits >::tabIndentStr_ [private]

Definition at line 261 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
bool Teuchos::basic_FancyOStream_buf< CharT, Traits >::showLinePrefix_ [private]

Definition at line 262 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::maxLenLinePrefix_ [private]

Definition at line 263 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
bool Teuchos::basic_FancyOStream_buf< CharT, Traits >::showTabCount_ [private]

Definition at line 264 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
bool Teuchos::basic_FancyOStream_buf< CharT, Traits >::showProcRank_ [private]

Definition at line 265 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::rootRank_ [private]

Definition at line 266 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::procRank_ [private]

Definition at line 267 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::numProcs_ [private]

Definition at line 268 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::rankPrintWidth_ [private]

Definition at line 269 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
RCP<std::ostringstream> Teuchos::basic_FancyOStream_buf< CharT, Traits >::lineOut_ [private]

Definition at line 271 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::tabIndent_ [private]

Definition at line 273 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
tabIndentStack_t Teuchos::basic_FancyOStream_buf< CharT, Traits >::tabIndentStack_ [private]

Definition at line 274 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
linePrefixStack_t Teuchos::basic_FancyOStream_buf< CharT, Traits >::linePrefixStack_ [private]

Definition at line 275 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
int Teuchos::basic_FancyOStream_buf< CharT, Traits >::enableTabbingStack_ [private]

Definition at line 276 of file Teuchos_FancyOStream.hpp.

template<typename CharT, typename Traits>
bool Teuchos::basic_FancyOStream_buf< CharT, Traits >::wroteNewline_ [private]

Definition at line 278 of file Teuchos_FancyOStream.hpp.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on Tue Oct 20 10:14:04 2009 for Teuchos Package Browser (Single Doxygen Collection) by  doxygen 1.6.1