The Actor Class

    enum Role { Person = 0 , Student, Employer, Final };
    
    class actor {                      
defines the repertoire

public: actor() { } virtual void walk() { if (exists()) self()->walk(); } virtual void talk() { if (exists()) self()->talk(); } virtual void think() { if (exists()) self()->think(); } virtual void act() { if (exists()) self()->act(); } virtual void become(Role) { }
only for a person

virtual void become(actor*) { } virtual actor* self() { return this; }
an empty self

int exists() { return self() != this; }
who ami

};

slide: The Actor Class