• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • tdeio/tdeio
 

tdeio/tdeio

  • tdeio
  • tdeio
tdefileshare.h
1 /* This file is part of the KDE project
2  Copyright (c) 2001 David Faure <david@mandrakesoft.com>
3  Copyright (c) 2001 Laurent Montel <lmontel@mandrakesoft.com>
4 
5  This library is free software; you can redistribute it and/or
6  modify it under the terms of the GNU Library General Public
7  License version 2 as published by the Free Software Foundation.
8 
9  This library is distributed in the hope that it will be useful,
10  but WITHOUT ANY WARRANTY; without even the implied warranty of
11  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  Library General Public License for more details.
13 
14  You should have received a copy of the GNU Library General Public License
15  along with this library; see the file COPYING.LIB. If not, write to
16  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17  Boston, MA 02110-1301, USA.
18 */
19 
20 #ifndef TDEFILESHARE_H
21 #define TDEFILESHARE_H
22 #include <tqobject.h>
23 
24 #include <tdelibs_export.h>
25 
26 class KDirWatch;
27 
32 class KFileSharePrivate : public TQObject
33 {
34  Q_OBJECT
35 
36 public:
37  KFileSharePrivate();
38  ~KFileSharePrivate();
39  KDirWatch* m_watchFile;
40  static KFileSharePrivate *self();
41  static KFileSharePrivate *_self;
42 protected slots: // this is why this class needs to be in the .h
43  void slotFileChange(const TQString &);
44 };
45 
51 class TDEIO_EXPORT KFileShare
52 {
53 
54 
55 public:
59  static void readConfig();
60 
64  static void readShareList();
65 
66 
70  static int isDirectoryShared( const TQString& path );
71 
72  enum Authorization { NotInitialized, ErrorNotFound, Authorized, UserNotAllowed };
76  static Authorization authorization();
77 
78  static TQString findExe( const char* exeName );
79 
87  static bool setShared( const TQString& path, bool shared );
88 
89  /*
90  * SuSE only enhancement for now
91  */
92  static bool SuSEsetShared( const TQString& path, bool shared, bool ro );
93 
101  enum ShareMode { Simple, Advanced };
102 
108  static bool sharingEnabled();
109 
116  static bool isRestricted();
117 
123  static TQString fileShareGroup();
124 
128  static ShareMode shareMode();
129 
133  static bool sambaEnabled();
134 
138  static bool nfsEnabled();
139 
144  static bool sambaActive();
145 
150  static bool nfsActive();
151 
152 private:
153  static Authorization s_authorization;
154 // static TQStringList* s_shareList;
155  static TQMap<TQString,TQString>* s_shareMap;
156  static ShareMode s_shareMode;
157  static bool s_sambaEnabled;
158  static bool s_nfsEnabled;
159  static bool s_restricted;
160  static TQString s_fileShareGroup;
161  static bool s_sharingEnabled;
162 
163 };
164 
165 #endif
KFileShare::ShareMode
ShareMode
The used share mode.
Definition: tdefileshare.h:101
KFileShare
Common functionality for the file sharing (communication with the backend)
Definition: tdefileshare.h:51
KDirWatch
Watch directories and files for changes.
Definition: kdirwatch.h:65

tdeio/tdeio

Skip menu "tdeio/tdeio"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

tdeio/tdeio

Skip menu "tdeio/tdeio"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  •     tdecore
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  • tdeioslave
  •   http
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdeio/tdeio by doxygen 1.8.8
This website is maintained by Timothy Pearson.