libkcal
duration.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef KCAL_DURATION_H
00022 #define KCAL_DURATION_H
00023
00024 #include <qdatetime.h>
00025
00026 #include "libkcal_export.h"
00027
00028 namespace KCal {
00029
00033 class LIBKCAL_EXPORT Duration
00034 {
00035 public:
00036 Duration();
00037 Duration( const QDateTime &start, const QDateTime &end );
00038 Duration( int seconds );
00039
00040 QDateTime end( const QDateTime &start ) const;
00041
00042 int asSeconds() const;
00043
00044 private:
00045 int mSeconds;
00046
00047 class Private;
00048 Private *d;
00049 };
00050
00051 bool operator==( const Duration&, const Duration& );
00052 inline bool operator!=( const Duration &d1, const Duration &d2 )
00053 {
00054 return !operator==( d1, d2 );
00055 }
00056
00057 }
00058
00059 #endif
|