#include <eoAged.h>
Public Member Functions | |
| eoAged (const Object &_o) | |
| Main ctor from an already built Object. | |
| eoAged (const eoAged &_a) | |
| Copy constructor. | |
| virtual | ~eoAged () |
| Virtual dtor. They are needed in virtual class hierarchies. | |
| unsigned long | Age () const |
| returns the age of the object | |
| const eoAged & | operator++ () |
| Increments age. | |
Methods from eoObject | |
readFrom and printOn are directly inherited from eo1d | |
| virtual std::string | className () const |
| Return the class id. | |
| virtual void | readFrom (istream &_is) |
| Read object. | |
| virtual void | printOn (ostream &_os) const |
| Write object. | |
Private Member Functions | |
| eoAged () | |
| Default Constructor. | |
Private Attributes | |
| unsigned long | age |
The Object must be an eoObject, thus, it must have its methods: className, printOn, readFrom.
Definition at line 47 of file eoAged.h.
|
|||||||||
|
Default Constructor. \ Itīs private so that it is not used anywhere; the right way of using this object is to create an Object and passing it to an aged by means of the copy ctor; that way itīs turned into an Aged object |
|
|||||||||
|
Return the class id. This should be redefined in each class; but it's got code as an example of implementation. Only "leaf" classes can be non-virtual. |
|
||||||||||
|
Read object.
|
|
||||||||||
|
Write object. It's called printOn since it prints the object _on_ a stream.
|
1.3.9.1