std::ostreambuf_iterator< CharT, Traits > Class Template Reference

Provides output iterator semantics for streambufs. More...

#include <streambuf_iterator.h>

Inheritance diagram for std::ostreambuf_iterator< CharT, Traits >:

Inheritance graph
[legend]
Collaboration diagram for std::ostreambuf_iterator< CharT, Traits >:

Collaboration graph
[legend]
List of all members.

Public Types

typedef Category iterator_category
 One of the tag types.
typedef Type value_type
 The type "pointed to" by the iterator.
typedef Distance difference_type
 Distance between iterators is represented as this type.
typedef Pointer pointer
 This type represents a pointer-to-value_type.
typedef Reference reference
 This type represents a reference-to-value_type.
typedef CharT char_type
 Public typedefs.
typedef Traits traits_type
 Public typedefs.
typedef basic_streambuf< CharT,
Traits > 
streambuf_type
 Public typedefs.
typedef basic_ostream< CharT,
Traits > 
ostream_type
 Public typedefs.

Public Member Functions

 ostreambuf_iterator (ostream_type &s) throw ()
 Construct output iterator from ostream.
 ostreambuf_iterator (streambuf_type *s) throw ()
 Construct output iterator from streambuf.
ostreambuf_iteratoroperator= (CharT c)
 Write character to streambuf. Calls streambuf.sputc().
ostreambuf_iteratoroperator * ()
 Return *this.
ostreambuf_iteratoroperator++ (int)
 Return *this.
ostreambuf_iteratoroperator++ ()
 Return *this.
bool failed () const throw ()
 Return true if previous operator=() failed.
ostreambuf_iteratorM_put (const CharT *__ws, streamsize __len)

Private Attributes

streambuf_typeM_sbuf
bool M_failed

Detailed Description

template<typename CharT, typename Traits>
class std::ostreambuf_iterator< CharT, Traits >

Provides output iterator semantics for streambufs.

Definition at line 191 of file streambuf_iterator.h.


Member Typedef Documentation

template<typename CharT, typename Traits>
typedef CharT std::ostreambuf_iterator< CharT, Traits >::char_type

Public typedefs.

Definition at line 198 of file streambuf_iterator.h.

template<typename CharT, typename Traits>
typedef Traits std::ostreambuf_iterator< CharT, Traits >::traits_type

Public typedefs.

Definition at line 199 of file streambuf_iterator.h.

template<typename CharT, typename Traits>
typedef basic_streambuf<CharT, Traits> std::ostreambuf_iterator< CharT, Traits >::streambuf_type

Public typedefs.

Definition at line 200 of file streambuf_iterator.h.

template<typename CharT, typename Traits>
typedef basic_ostream<CharT, Traits> std::ostreambuf_iterator< CharT, Traits >::ostream_type

Public typedefs.

Definition at line 201 of file streambuf_iterator.h.

template<typename Category, typename Type, typename Distance = ptrdiff_t, typename Pointer = Type*, typename Reference = Type&>
typedef Category std::iterator< Category, Type, Distance, Pointer, Reference >::iterator_category [inherited]

One of the tag types.

Definition at line 109 of file stl_iterator_base_types.h.

template<typename Category, typename Type, typename Distance = ptrdiff_t, typename Pointer = Type*, typename Reference = Type&>
typedef Type std::iterator< Category, Type, Distance, Pointer, Reference >::value_type [inherited]

The type "pointed to" by the iterator.

Reimplemented in __gnu_cxx::sequence_buffer< Sequence, Buf_sz >.

Definition at line 111 of file stl_iterator_base_types.h.

template<typename Category, typename Type, typename Distance = ptrdiff_t, typename Pointer = Type*, typename Reference = Type&>
typedef Distance std::iterator< Category, Type, Distance, Pointer, Reference >::difference_type [inherited]

Distance between iterators is represented as this type.

Reimplemented in std::reverse_iterator< Iterator >.

Definition at line 113 of file stl_iterator_base_types.h.

template<typename Category, typename Type, typename Distance = ptrdiff_t, typename Pointer = Type*, typename Reference = Type&>
typedef Pointer std::iterator< Category, Type, Distance, Pointer, Reference >::pointer [inherited]

This type represents a pointer-to-value_type.

Reimplemented in std::Bit_iterator, std::Bit_const_iterator, std::reverse_iterator< Iterator >, __gnu_cxx::Rope_const_iterator< CharT, Alloc >, and __gnu_cxx::Rope_iterator< CharT, Alloc >.

Definition at line 115 of file stl_iterator_base_types.h.

template<typename Category, typename Type, typename Distance = ptrdiff_t, typename Pointer = Type*, typename Reference = Type&>
typedef Reference std::iterator< Category, Type, Distance, Pointer, Reference >::reference [inherited]

This type represents a reference-to-value_type.

Reimplemented in std::Bit_iterator, std::Bit_const_iterator, std::reverse_iterator< Iterator >, __gnu_cxx::Rope_const_iterator< CharT, Alloc >, and __gnu_cxx::Rope_iterator< CharT, Alloc >.

Definition at line 117 of file stl_iterator_base_types.h.


Constructor & Destructor Documentation

template<typename CharT, typename Traits>
std::ostreambuf_iterator< CharT, Traits >::ostreambuf_iterator ( ostream_type s  )  throw () [inline]

Construct output iterator from ostream.

Definition at line 210 of file streambuf_iterator.h.

template<typename CharT, typename Traits>
std::ostreambuf_iterator< CharT, Traits >::ostreambuf_iterator ( streambuf_type s  )  throw () [inline]

Construct output iterator from streambuf.

Definition at line 214 of file streambuf_iterator.h.


Member Function Documentation

template<typename CharT, typename Traits>
ostreambuf_iterator& std::ostreambuf_iterator< CharT, Traits >::operator= ( CharT  c  )  [inline]

Write character to streambuf. Calls streambuf.sputc().

Definition at line 219 of file streambuf_iterator.h.

template<typename CharT, typename Traits>
ostreambuf_iterator& std::ostreambuf_iterator< CharT, Traits >::operator * (  )  [inline]

Return *this.

Definition at line 229 of file streambuf_iterator.h.

template<typename CharT, typename Traits>
ostreambuf_iterator& std::ostreambuf_iterator< CharT, Traits >::operator++ ( int   )  [inline]

Return *this.

Definition at line 234 of file streambuf_iterator.h.

template<typename CharT, typename Traits>
ostreambuf_iterator& std::ostreambuf_iterator< CharT, Traits >::operator++ (  )  [inline]

Return *this.

Definition at line 239 of file streambuf_iterator.h.

template<typename CharT, typename Traits>
bool std::ostreambuf_iterator< CharT, Traits >::failed (  )  const throw () [inline]

Return true if previous operator=() failed.

Definition at line 244 of file streambuf_iterator.h.


The documentation for this class was generated from the following file:
Generated on Tue Jan 2 17:00:14 2007 for libstdc++-v3 Source by  doxygen 1.5.1