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

tdeio/tdeio

Public Types | Static Public Member Functions | List of all members
KFileShare Class Reference

#include <tdefileshare.h>

Public Types

enum  Authorization { NotInitialized, ErrorNotFound, Authorized, UserNotAllowed }
 
enum  ShareMode { Simple, Advanced }
 

Static Public Member Functions

static void readConfig ()
 
static void readShareList ()
 
static int isDirectoryShared (const TQString &path)
 
static Authorization authorization ()
 
static TQString findExe (const char *exeName)
 
static bool setShared (const TQString &path, bool shared)
 
static bool SuSEsetShared (const TQString &path, bool shared, bool ro)
 
static bool sharingEnabled ()
 
static bool isRestricted ()
 
static TQString fileShareGroup ()
 
static ShareMode shareMode ()
 
static bool sambaEnabled ()
 
static bool nfsEnabled ()
 
static bool sambaActive ()
 
static bool nfsActive ()
 

Detailed Description

Common functionality for the file sharing (communication with the backend)

Since
3.1

Definition at line 51 of file tdefileshare.h.

Member Enumeration Documentation

enum KFileShare::ShareMode

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.

Definition at line 101 of file tdefileshare.h.

Member Function Documentation

KFileShare::Authorization KFileShare::authorization ( )
static

Call this to know if the current user is authorized to share directories.

Definition at line 233 of file tdefileshare.cpp.

TQString KFileShare::fileShareGroup ( )
static

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 145 of file tdefileshare.cpp.

int KFileShare::isDirectoryShared ( const TQString &  path)
static

Call this to know if a directory is currently shared.

Definition at line 213 of file tdefileshare.cpp.

bool KFileShare::isRestricted ( )
static

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 138 of file tdefileshare.cpp.

bool KFileShare::nfsActive ( )
static

Returns whether NFS is active (service is running)

Definition at line 333 of file tdefileshare.cpp.

bool KFileShare::nfsEnabled ( )
static

Returns whether NFS is enabled.

Definition at line 160 of file tdefileshare.cpp.

void KFileShare::readConfig ( )
static

Reads the file share configuration file.

Definition at line 89 of file tdefileshare.cpp.

void KFileShare::readShareList ( )
static

Reads the list of shared folders.

Definition at line 168 of file tdefileshare.cpp.

bool KFileShare::sambaActive ( )
static

Returns whether Samba is active (service is running)

Definition at line 326 of file tdefileshare.cpp.

bool KFileShare::sambaEnabled ( )
static

Returns whether Samba is enabled.

Definition at line 153 of file tdefileshare.cpp.

bool KFileShare::setShared ( const TQString &  path,
bool  shared 
)
static

Uses a suid perl script to share the given path with NFS and Samba.

Parameters
paththe path to share
sharedwhether the path should be shared or not
Returns
whether the perl script was successful

Definition at line 251 of file tdefileshare.cpp.

KFileShare::ShareMode KFileShare::shareMode ( )
static

Returns the configured share mode.

Definition at line 124 of file tdefileshare.cpp.

bool KFileShare::sharingEnabled ( )
static

Returns whether sharing is enabled If this is false, file sharing is disabled and nobody can share files.

Definition at line 131 of file tdefileshare.cpp.


The documentation for this class was generated from the following files:
  • tdefileshare.h
  • tdefileshare.cpp

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.