KCalCore Library
filestorage.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00029 #ifndef KCALCORE_FILESTORAGE_H
00030 #define KCALCORE_FILESTORAGE_H
00031
00032 #include "kcalcore_export.h"
00033 #include "calstorage.h"
00034
00035 namespace KCalCore {
00036
00037 class CalFormat;
00038 class Calendar;
00039
00044 class KCALCORE_EXPORT FileStorage : public CalStorage
00045 {
00046 public:
00047
00051 typedef QSharedPointer<FileStorage> Ptr;
00052
00064 explicit FileStorage( const Calendar::Ptr &calendar,
00065 const QString &fileName = QString(),
00066 KCalCore::CalFormat *format = 0 );
00067
00071 virtual ~FileStorage();
00072
00079 void setFileName( const QString &fileName );
00080
00085 QString fileName() const;
00086
00094 void setSaveFormat( KCalCore::CalFormat *format );
00095
00100 CalFormat *saveFormat() const;
00101
00106 bool open();
00107
00112 bool load();
00113
00118 bool save();
00119
00124 bool close();
00125
00126 private:
00127
00128 Q_DISABLE_COPY( FileStorage )
00129 class Private;
00130 Private *const d;
00131
00132 };
00133
00134 }
00135
00136 #endif