summaryrefslogtreecommitdiffabout
path: root/libkcal/incidence.h
Unidiff
Diffstat (limited to 'libkcal/incidence.h') (more/less context) (ignore whitespace changes)
-rw-r--r--libkcal/incidence.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/libkcal/incidence.h b/libkcal/incidence.h
index 88df217..eef9e64 100644
--- a/libkcal/incidence.h
+++ b/libkcal/incidence.h
@@ -85,64 +85,65 @@ class Incidence : public IncidenceBase
85 template<class T> 85 template<class T>
86 class AddVisitor : public Visitor 86 class AddVisitor : public Visitor
87 { 87 {
88 public: 88 public:
89 AddVisitor( T *r ) : mResource( r ) {} 89 AddVisitor( T *r ) : mResource( r ) {}
90 bool visit( Event *e ) { return mResource->addEvent( e ); } 90 bool visit( Event *e ) { return mResource->addEvent( e ); }
91 bool visit( Todo *t ) { return mResource->addTodo( t ); } 91 bool visit( Todo *t ) { return mResource->addTodo( t ); }
92 bool visit( Journal *j ) { return mResource->addJournal( j ); } 92 bool visit( Journal *j ) { return mResource->addJournal( j ); }
93 93
94 private: 94 private:
95 T *mResource; 95 T *mResource;
96 }; 96 };
97 97
98 /** enumeration for describing an event's secrecy. */ 98 /** enumeration for describing an event's secrecy. */
99 enum { SecrecyPublic = 0, SecrecyPrivate = 1, SecrecyConfidential = 2 }; 99 enum { SecrecyPublic = 0, SecrecyPrivate = 1, SecrecyConfidential = 2 };
100 typedef ListBase<Incidence> List; 100 typedef ListBase<Incidence> List;
101 Incidence(); 101 Incidence();
102 Incidence(const Incidence &); 102 Incidence(const Incidence &);
103 ~Incidence(); 103 ~Incidence();
104 104
105 /** 105 /**
106 Accept IncidenceVisitor. A class taking part in the visitor mechanism has to 106 Accept IncidenceVisitor. A class taking part in the visitor mechanism has to
107 provide this implementation: 107 provide this implementation:
108 <pre> 108 <pre>
109 bool accept(Visitor &v) { return v.visit(this); } 109 bool accept(Visitor &v) { return v.visit(this); }
110 </pre> 110 </pre>
111 */ 111 */
112 virtual bool accept(Visitor &) { return false; } 112 virtual bool accept(Visitor &) { return false; }
113 113
114 virtual Incidence *clone() = 0; 114 virtual Incidence *clone() = 0;
115 virtual void cloneRelations( Incidence * ); 115 virtual void cloneRelations( Incidence * );
116 void addRelationsToList(QPtrList<Incidence> *rel); 116 void addRelationsToList(QPtrList<Incidence> *rel);
117 void clearRelations();
117 virtual QDateTime getNextAlarmDateTime( bool * ok, int * offset, QDateTime start_dt ) const = 0; 118 virtual QDateTime getNextAlarmDateTime( bool * ok, int * offset, QDateTime start_dt ) const = 0;
118 void setReadOnly( bool ); 119 void setReadOnly( bool );
119 120
120 /** 121 /**
121 Recreate event. The event is made a new unique event, but already stored 122 Recreate event. The event is made a new unique event, but already stored
122 event information is preserved. Sets uniquie id, creation date, last 123 event information is preserved. Sets uniquie id, creation date, last
123 modification date and revision number. 124 modification date and revision number.
124 */ 125 */
125 void recreate(); 126 void recreate();
126 Incidence* recreateCloneException(QDate); 127 Incidence* recreateCloneException(QDate);
127 128
128 /** set creation date */ 129 /** set creation date */
129 void setCreated(QDateTime); 130 void setCreated(QDateTime);
130 /** return time and date of creation. */ 131 /** return time and date of creation. */
131 QDateTime created() const; 132 QDateTime created() const;
132 133
133 /** set the number of revisions this event has seen */ 134 /** set the number of revisions this event has seen */
134 void setRevision(int rev); 135 void setRevision(int rev);
135 /** return the number of revisions this event has seen */ 136 /** return the number of revisions this event has seen */
136 int revision() const; 137 int revision() const;
137 138
138 /** Set starting date/time. */ 139 /** Set starting date/time. */
139 virtual void setDtStart(const QDateTime &dtStart); 140 virtual void setDtStart(const QDateTime &dtStart);
140 /** Return the incidence's ending date/time as a QDateTime. */ 141 /** Return the incidence's ending date/time as a QDateTime. */
141 virtual QDateTime dtEnd() const { return QDateTime(); } 142 virtual QDateTime dtEnd() const { return QDateTime(); }
142 143
143 /** sets the event's lengthy description. */ 144 /** sets the event's lengthy description. */
144 void setDescription(const QString &description); 145 void setDescription(const QString &description);
145 /** returns a reference to the event's description. */ 146 /** returns a reference to the event's description. */
146 QString description() const; 147 QString description() const;
147 148
148 /** sets the event's short summary. */ 149 /** sets the event's short summary. */