kmail
kmfolderdir.h
Go to the documentation of this file.00001 #ifndef kmfolderdir_h 00002 #define kmfolderdir_h 00003 00004 #include <qstring.h> 00005 #include "kmfoldernode.h" 00006 #include "kmfoldertype.h" 00007 00008 class KMFolder; 00009 class KMFolderMgr; 00010 00011 00015 class KMFolderDir: public KMFolderNode, public KMFolderNodeList 00016 { 00017 Q_OBJECT 00018 00019 public: 00020 KMFolderDir( KMFolder * owner, KMFolderDir * parent = 0, 00021 const QString& path = QString::null, 00022 KMFolderDirType = KMStandardDir ); 00023 virtual ~KMFolderDir(); 00024 00025 virtual bool isDir() const { return true; } 00026 00028 virtual bool reload(); 00029 00031 virtual QString path() const; 00032 00034 QString label() const; 00035 00037 virtual QString prettyURL() const; 00038 00042 virtual KMFolder* createFolder(const QString& folderName, 00043 bool sysFldr=false, 00044 KMFolderType folderType=KMFolderTypeMbox); 00045 00047 virtual KMFolderNode* hasNamedFolder(const QString& name); 00048 00050 virtual KMFolderMgr* manager() const; 00051 00053 KMFolder* owner() const { return mOwner; } 00054 00055 virtual KMFolderDirType type() const { return mDirType; } 00056 00057 protected: 00058 KMFolder * mOwner; 00059 KMFolderDirType mDirType; 00060 }; 00061 00062 00063 //----------------------------------------------------------------------------- 00064 00065 class KMFolderRootDir: public KMFolderDir 00066 { 00067 Q_OBJECT 00068 00069 public: 00070 KMFolderRootDir(KMFolderMgr* manager, 00071 const QString& path=QString::null, 00072 KMFolderDirType dirType = KMStandardDir); 00073 virtual ~KMFolderRootDir(); 00074 virtual QString path() const; 00075 00077 virtual void setPath(const QString&); 00078 00079 virtual QString prettyURL() const; 00080 00081 void setBaseURL( const QCString& baseURL ); 00082 00083 virtual KMFolderMgr* manager() const; 00084 00085 protected: 00086 QString mPath; 00087 KMFolderMgr *mManager; 00088 QCString mBaseURL; 00089 }; 00090 00091 #endif /*kmfolderdir_h*/ 00092