ircproxy The Ultimate Cyborg |
#include <PersistXML.h>
Definition at line 64 of file PersistXML.h.
Public Member Functions | |
Indentation (void) | |
Construct a new indentation object of zero spaces. | |
Indentation (Indentation const &indent) | |
Copy constructor. | |
Indentation & | operator++ (void) |
Pre-increment indentation with two spaces. | |
Indentation | operator++ (int) |
Post-increment indentation with two spaces. | |
Indentation & | operator-- (void) |
Pre-decrement indentation by two spaces. | |
Indentation | operator-- (int) |
Post-decrement indentation by two spaces. | |
Private Attributes | |
int | M_spaces |
The number of spaces to indent. | |
Friends | |
std::ostream & | operator<< (std::ostream &os, Indentation const &indentation) |
Print object to ostream. |
Indentation::Indentation | ( | void | ) | [inline] |
Construct a new indentation object of zero spaces.
Definition at line 69 of file PersistXML.h.
00069 : M_spaces(0) { }
Indentation::Indentation | ( | Indentation const & | indent | ) | [inline] |
Indentation& Indentation::operator++ | ( | void | ) | [inline] |
Pre-increment indentation with two spaces.
Definition at line 73 of file PersistXML.h.
References M_spaces.
00073 { M_spaces += 2; return *this; }
Indentation Indentation::operator++ | ( | int | ) | [inline] |
Post-increment indentation with two spaces.
Definition at line 75 of file PersistXML.h.
References M_spaces.
00075 { Indentation tmp(*this); M_spaces += 2; return tmp; }
Indentation& Indentation::operator-- | ( | void | ) | [inline] |
Pre-decrement indentation by two spaces.
Definition at line 77 of file PersistXML.h.
References M_spaces.
00077 { M_spaces -= 2; return *this; }
Indentation Indentation::operator-- | ( | int | ) | [inline] |
Post-decrement indentation by two spaces.
Definition at line 79 of file PersistXML.h.
References M_spaces.
00079 { Indentation tmp(*this); M_spaces -= 2; return tmp; }
std::ostream& operator<< | ( | std::ostream & | os, | |
Indentation const & | indentation | |||
) | [friend] |
Print object to ostream.
Definition at line 81 of file PersistXML.h.
00082 { 00083 for (int i = 0; i < indentation.M_spaces; ++i) 00084 os << ' '; 00085 return os; 00086 }
int Indentation::M_spaces [private] |
The number of spaces to indent.
Definition at line 66 of file PersistXML.h.
Referenced by operator++(), and operator--().
Copyright © 2005-2007 Carlo Wood. All rights reserved. |
---|