KIO
Enumerations | |
enum | Authorization { NotInitialized, ErrorNotFound, Authorized, UserNotAllowed } |
enum | ShareMode { Simple, Advanced } |
Functions | |
Authorization | authorization () |
QString | fileShareGroup () |
bool | isDirectoryShared (const QString &path) |
bool | isRestricted () |
bool | nfsEnabled () |
void | readConfig () |
void | readShareList () |
bool | sambaEnabled () |
bool | setShared (const QString &path, bool shared) |
ShareMode | shareMode () |
bool | sharingEnabled () |
Detailed Description
Common functionality for the file sharing (communication with the backend)
Enumeration Type Documentation
Enumerator | |
---|---|
NotInitialized | |
ErrorNotFound | |
Authorized | |
UserNotAllowed |
Definition at line 48 of file kfileshare.h.
The used share mode.
Simple means that the simple sharing dialog is used and users can share only folders from there HOME folder. Advanced means that the advanced sharing dialog is used and users can share any folder.
Enumerator | |
---|---|
Simple | |
Advanced |
Definition at line 70 of file kfileshare.h.
Function Documentation
KFileShare::Authorization KFileShare::authorization | ( | ) |
Call this to know if the current user is authorized to share directories.
Definition at line 227 of file kfileshare.cpp.
QString KFileShare::fileShareGroup | ( | ) |
Returns the group that is used for file sharing.
That is, all users in that group are allowed to share files if file sharing is restricted.
Definition at line 160 of file kfileshare.cpp.
Call this to know if a directory is currently shared.
Definition at line 216 of file kfileshare.cpp.
bool KFileShare::isRestricted | ( | ) |
Returns whether file sharing is restricted.
If it is not restricted every user can shar files. If it is restricted only users in the configured file share group can share files.
Definition at line 153 of file kfileshare.cpp.
bool KFileShare::nfsEnabled | ( | ) |
Returns whether NFS is enabled.
Definition at line 175 of file kfileshare.cpp.
void KFileShare::readConfig | ( | ) |
Reads the file share configuration file.
Definition at line 106 of file kfileshare.cpp.
void KFileShare::readShareList | ( | ) |
Reads the list of shared folders.
Definition at line 183 of file kfileshare.cpp.
bool KFileShare::sambaEnabled | ( | ) |
Returns whether Samba is enabled.
Definition at line 168 of file kfileshare.cpp.
Uses a suid perl script to share the given path with NFS and Samba.
- Parameters
-
path the path to share shared whether the path should be shared or not
- Returns
- whether the perl script was successful
Definition at line 235 of file kfileshare.cpp.
KFileShare::ShareMode KFileShare::shareMode | ( | ) |
Returns the configured share mode.
Definition at line 139 of file kfileshare.cpp.
bool KFileShare::sharingEnabled | ( | ) |
Returns whether sharing is enabled If this is false, file sharing is disabled and nobody can share files.
Definition at line 146 of file kfileshare.cpp.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:24:55 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.