00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef KCAL_ATTENDEE_H
00023 #define KCAL_ATTENDEE_H
00024
00025 #include <tqstring.h>
00026 #include <tqstringlist.h>
00027
00028 #include "listbase.h"
00029 #include "person.h"
00030
00031 namespace KCal {
00032
00036 class LIBKCAL_EXPORT Attendee : public Person
00037 {
00038 public:
00039 enum PartStat { NeedsAction, Accepted, Declined, Tentative,
00040 Delegated, Completed, InProcess, None };
00041 enum Role { ReqParticipant, OptParticipant, NonParticipant, Chair };
00042
00043 typedef ListBase<Attendee> List;
00044
00055 Attendee( const TQString &name, const TQString &email,
00056 bool rsvp = false, PartStat status = None,
00057 Role role = ReqParticipant, const TQString &u = TQString() );
00061 virtual ~Attendee();
00062
00066
00067 void setRole( Role );
00068
00072 Role role() const;
00073
00077 TQString roleStr() const;
00081 static TQString roleName( Role );
00085 static TQStringList roleList();
00086
00090 TQString uid() const;
00094 void setUid ( const TQString & );
00095
00099 void setStatus( PartStat s );
00100
00104 PartStat status() const;
00105
00109 TQString statusStr() const;
00113 static TQString statusName( PartStat );
00117 static TQStringList statusList();
00118
00122 void setRSVP( bool r ) { mRSVP = r; }
00126 bool RSVP() const { return mRSVP; }
00127
00131 void setDelegate( const TQString &delegate ) { mDelegate = delegate; }
00135 TQString delegate() const { return mDelegate; }
00136
00140 void setDelegator( const TQString &delegator ) { mDelegator = delegator; }
00144 TQString delegator() const { return mDelegator; }
00145
00146 private:
00147 bool mRSVP;
00148 Role mRole;
00149 PartStat mStatus;
00150 TQString mUid;
00151 TQString mDelegate;
00152 TQString mDelegator;
00153
00154 class Private;
00155 Private *d;
00156 };
00157
00158 bool operator==( const Attendee& a1, const Attendee& a2 );
00159
00160 }
00161
00162 #endif