#ifndef NODEPATH_H #define NODEPATH_H #include #include #define PATH_SEPARATOR "/" #define FOLDER_MIME "application/x-foldernode" #define TAG_MIME "application/x-tagnode" #define NOTE_MIME "application/x-notenode" // NodePath 类用于处理节点路径 class NodePath { public: // 构造函数,初始化节点路径 NodePath(const QString &path); // 将路径分割为字符串列表 QStringList separate() const; // 获取当前路径 QString path() const; // 获取父路径 NodePath parentPath() const; // 获取所有笔记文件夹的路径 static QString getAllNoteFolderPath(); // 获取回收站文件夹的路径 static QString getTrashFolderPath(); private: QString m_path; // 存储节点路径 }; #endif // NODEPATH_H