stlencoders
1.1.3
|
An output iterator adaptor used to wrap lines after a set number of characters. More...
Public Types | |
typedef Iterator | iterator_type |
The underlying iterator type. More... | |
typedef charT | char_type |
The character type. More... | |
typedef traits | traits_type |
The character traits type. More... | |
typedef traits::off_type | off_type |
An integral type holding the number of characters per line. More... | |
Public Member Functions | |
line_wrap_iterator (Iterator i, off_type n, const charT *s) | |
Constructs a line_wrap_iterator adaptor which will copy a delimiter string to the underlying iterator after every n characters. More... | |
Iterator | base () const |
Returns current . More... | |
line_wrap_iterator & | operator= (char_type c) |
Copies a character to the underlying output iterator. More... | |
line_wrap_iterator & | operator* () |
Returns *this . More... | |
line_wrap_iterator & | operator++ () |
Returns *this . More... | |
line_wrap_iterator & | operator++ (int) |
Returns *this . More... | |
Protected Attributes | |
Iterator | current |
The underlying iterator. More... | |
An output iterator adaptor used to wrap lines after a set number of characters.
Iterator | the underlying iterator class |
charT | the output character type |
traits | the output character traits type |
typedef charT stlencoders::line_wrap_iterator< Iterator, charT, traits >::char_type |
The character type.
typedef Iterator stlencoders::line_wrap_iterator< Iterator, charT, traits >::iterator_type |
The underlying iterator type.
typedef traits::off_type stlencoders::line_wrap_iterator< Iterator, charT, traits >::off_type |
An integral type holding the number of characters per line.
typedef traits stlencoders::line_wrap_iterator< Iterator, charT, traits >::traits_type |
The character traits type.
|
inline |
Constructs a line_wrap_iterator adaptor which will copy a delimiter string to the underlying iterator after every n characters.
i | the underlying iterator |
n | the number of characters per line |
s | the line delimiter string |
|
inline |
Returns current
.
|
inline |
Returns *this
.
|
inline |
Returns *this
.
|
inline |
Returns *this
.
|
inline |
Copies a character to the underlying output iterator.
If the maximum number of characters per line has been reached, copies the delimiter string to the underlying output iterator. Then outputs the given character and increments the underlying iterator.
c | the character to be written |
*this
|
protected |
The underlying iterator.