Skip to content
Skip to link menu
Trinity API Reference
Trinity API Reference
kio/kio
kio/kio
kio
kio
kdirwatch.h
1
/* This file is part of the KDE libraries
2
Copyright (C) 1998 Sven Radej <sven@lisa.exp.univie.ac.at>
3
4
This library is free software; you can redistribute it and/or
5
modify it under the terms of the GNU Library General Public
6
License version 2 as published by the Free Software Foundation.
7
8
This library is distributed in the hope that it will be useful,
9
but WITHOUT ANY WARRANTY; without even the implied warranty of
10
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11
Library General Public License for more details.
12
13
You should have received a copy of the GNU Library General Public License
14
along with this library; see the file COPYING.LIB. If not, write to
15
the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
16
Boston, MA 02110-1301, USA.
17
*/
18
#ifndef _KDIRWATCH_H
19
#define _KDIRWATCH_H
20
21
#include <tqtimer.h>
22
#include <tqdatetime.h>
23
#include <tqmap.h>
24
25
#include <kdelibs_export.h>
26
27
#define kdirwatch KDirWatch::self()
28
29
class
KDirWatchPrivate;
30
63
class
KIO_EXPORT
KDirWatch
:
public
TQObject
64
{
65
Q_OBJECT
66
67
public
:
76
KDirWatch
(TQObject* parent = 0,
const
char
* name = 0);
77
83
~
KDirWatch
();
84
99
void
addDir(
const
TQString& path,
100
bool
watchFiles =
false
,
bool
recursive =
false
);
101
106
void
addFile(
const
TQString& file);
107
113
TQDateTime ctime(
const
TQString& path);
114
121
void
removeDir(
const
TQString& path);
122
129
void
removeFile(
const
TQString& file);
130
143
bool
stopDirScan(
const
TQString& path);
144
158
bool
restartDirScan(
const
TQString& path);
159
176
void
startScan(
bool
notify=
false
,
bool
skippedToo=
false
);
177
183
void
stopScan();
184
190
bool
isStopped
() {
return
_isStopped; }
191
197
bool
contains(
const
TQString& path )
const
;
198
203
static
void
statistics();
204
209
void
setCreated(
const
TQString &path );
214
void
setDirty(
const
TQString &path );
219
void
setDeleted(
const
TQString &path );
220
221
enum
Method { FAM, DNotify, Stat, INotify };
227
Method internalMethod();
228
241
static
KDirWatch
*
self
();
248
static
bool
exists();
249
250
signals:
251
265
void
dirty (
const
TQString &path);
266
271
void
created (
const
TQString &path );
272
279
void
deleted (
const
TQString &path );
280
281
private
:
282
bool
_isStopped;
283
284
KDirWatchPrivate *d;
285
static
KDirWatch
* s_pSelf;
286
};
287
288
#endif
289
290
// vim: sw=3 et
KDirWatch
Watch directories and files for changes.
Definition:
kdirwatch.h:63
KDirWatch::isStopped
bool isStopped()
Is scanning stopped? After creation of a KDirWatch instance, this is false.
Definition:
kdirwatch.h:190
kio/kio
Skip menu "kio/kio"
Main Page
Modules
Namespace List
Class Hierarchy
Alphabetical List
Class List
File List
Namespace Members
Class Members
Related Pages
kio/kio
Skip menu "kio/kio"
arts
dcop
dnssd
interfaces
interface
library
kspeech
ktexteditor
kabc
kate
kcmshell
kdecore
kded
kdefx
kdeprint
kdesu
kdeui
kdoctools
khtml
kimgio
kinit
kio
bookmarks
httpfilter
kfile
kio
kioexec
kpasswdserver
kssl
kioslave
http
kjs
kmdi
kmdi
knewstuff
kparts
krandr
kresources
kspell2
kunittest
kutils
kwallet
libkmid
libkscreensaver