DtkCore
DTK Core module
载入中...
搜索中...
未找到
dfilewatcher.h
浏览该文件的文档.
1// SPDX-FileCopyrightText: 2017 - 2022 UnionTech Software Technology Co., Ltd.
2//
3// SPDX-License-Identifier: LGPL-3.0-or-later
4
5#ifndef DFILEWATCHER_H
6#define DFILEWATCHER_H
7
8#include "dbasefilewatcher.h"
9
10DCORE_BEGIN_NAMESPACE
11
12class DFileWatcherPrivate;
13class LIBDTKCORESHARED_EXPORT DFileWatcher : public DBaseFileWatcher
14{
15 Q_OBJECT
16
17public:
18 explicit DFileWatcher(const QString &filePath, QObject *parent = 0);
19
20private Q_SLOTS:
21 void onFileDeleted(const QString &path, const QString &name);
22 void onFileAttributeChanged(const QString &path, const QString &name);
23 void onFileMoved(const QString &fromPath, const QString &fromName,
24 const QString &toPath, const QString &toName);
25 void onFileCreated(const QString &path, const QString &name);
26 void onFileModified(const QString &path, const QString &name);
27 void onFileClosed(const QString &path, const QString &name);
28
29private:
30 D_DECLARE_PRIVATE(DFileWatcher)
31};
32
33DCORE_END_NAMESPACE
34
35#endif // DFILEWATCHER_H
DBaseFileWatcher 类提供了一系列接口可供监视文件和目录的变动。
Definition dbasefilewatcher.h:17
Definition dfilewatcher.h:14
DFileWatcher(const QString &filePath, QObject *parent=0)
构造函数