SUMO - Simulation of Urban MObility
|
#include <AGChild.h>
Public Member Functions | |
AGChild (int age) | |
bool | alocateASchool (std::list< AGSchool > *schools, AGPosition housePos) |
virtual bool | decide (SUMOReal probability) const |
Lets the person make a decision. | |
virtual int | getAge () const |
Provides the age of the person. | |
int | getSchoolClosing () |
AGPosition | getSchoolLocation () |
int | getSchoolOpeining () |
bool | haveASchool () |
bool | leaveSchool () |
void | print () |
virtual void | print () const |
Puts out a summary of the class properties. | |
bool | setSchool (AGSchool *school) |
Protected Attributes | |
int | age |
Private Attributes | |
AGSchool * | school |
AGChild::AGChild | ( | int | age | ) | [inline] |
bool AGChild::alocateASchool | ( | std::list< AGSchool > * | schools, |
AGPosition | housePos | ||
) |
schools,: | school vector from City object |
housepos,: | Position of the households habitation |
Definition at line 64 of file AGChild.cpp.
References AGPerson::age, AGPosition::distanceTo(), setSchool(), and SUMOReal.
bool AGPerson::decide | ( | SUMOReal | probability | ) | const [virtual, inherited] |
Lets the person make a decision.
The higher the degree of belief is, the more likely this method returns true.
[in] | degreeOfBelief | how strong the person beliefs the proposition |
Definition at line 72 of file AGPerson.cpp.
References RandHelper::rand().
Referenced by AGAdult::tryToWork().
int AGPerson::getAge | ( | ) | const [virtual, inherited] |
Provides the age of the person.
Definition at line 65 of file AGPerson.cpp.
References AGPerson::age.
Definition at line 105 of file AGChild.cpp.
References AGSchool::getClosingHour(), and school.
Definition at line 100 of file AGChild.cpp.
References AGSchool::getPosition(), and school.
Definition at line 110 of file AGChild.cpp.
References AGSchool::getOpeningHour(), and school.
Definition at line 92 of file AGChild.cpp.
References school.
Definition at line 82 of file AGChild.cpp.
References AGSchool::removeChild(), and school.
void AGChild::print | ( | ) |
Definition at line 47 of file AGChild.cpp.
References AGPerson::age, and school.
void AGPerson::print | ( | ) | const [virtual, inherited] |
Puts out a summary of the class properties.
Reimplemented in AGAdult.
Definition at line 58 of file AGPerson.cpp.
References AGPerson::age.
bool AGChild::setSchool | ( | AGSchool * | school | ) |
Definition at line 52 of file AGChild.cpp.
References AGSchool::addNewChild(), and school.
Referenced by alocateASchool().
int AGPerson::age [protected, inherited] |
Definition at line 72 of file AGPerson.h.
Referenced by alocateASchool(), AGPerson::getAge(), print(), AGAdult::print(), and AGPerson::print().
AGSchool* AGChild::school [private] |
Definition at line 70 of file AGChild.h.
Referenced by getSchoolClosing(), getSchoolLocation(), getSchoolOpeining(), haveASchool(), leaveSchool(), print(), and setSchool().