1
/* This file is part of the KDE project
2
Copyright (c) 2004 Jan Schaefer <j_schaef@informatik.uni-kl.de>
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.
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.
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.
22
#include <QtCore/QObject>
24
#include <kio/kio_export.h>
27
* Similar functionality like KFileShare,
28
* but works only for Samba and do not need
30
* Singleton class, call instance() to get an instance.
32
class KIO_EXPORT KSambaShare : public QObject
37
* Returns the one and only instance of KSambaShare
39
static KSambaShare* instance();
42
* Whether or not the given path is shared by Samba.
43
* @param path the path to check if it is shared by Samba.
44
* @return whether the given path is shared by Samba.
46
bool isDirectoryShared( const QString & path ) const;
49
* Returns a list of all directories shared by Samba.
50
* The resulting list is not sorted.
51
* @return a list of all directories shared by Samba.
53
QStringList sharedDirectories() const;
56
* KSambaShare destructor.
58
* The instance is destroyed automatically!
60
virtual ~KSambaShare();
63
* Returns the path to the used smb.conf file
64
* or null if no file was found
66
QString smbConfPath() const;
70
* Emitted when the smb.conf file has changed
76
class KSambaSharePrivate;
77
KSambaSharePrivate * const d;
79
Q_PRIVATE_SLOT( d, void _k_slotFileChange(const QString&) )