# class KAutoMount

###

Module | kio
Namespace |
Class | KAutoMount
Inherits | QObject

This class implements synchronous mounting of devices, as well as showing a file-manager window after mounting a device, optionally. It is a wrapper around the asychronous KIO.special() call for mount, used by KMimeType.

This class implements synchronous mounting of devices.

### methods

- KAutoMount (readonly, format, device, mountpoint, desktopFile, show_filemanager_window)

  returns ctor

  Argument | Type | Default
  --- | --- | ---
  readonly | bool |
  format | QByteArray |
  device | QString |
  mountpoint | QString |
  desktopFile | QString |
  show_filemanager_window | bool | 1

  Mounts a device.

  readonly - if true, the device is mounted read-only

  format - the file system (e.g. vfat, ext2...) [optional, fstab is used otherwise]

  device - the path to the device (e.g. /dev/fd0)

  mountpoint - the directory where to mount the device [optional, fstab is used otherwise]

  desktopFile - the file the user clicked on - to notify KDirWatch of the fact that it should emit fileDirty for it (to have the icon change)

  show_filemanager_window - if true, a file-manager window for that mountpoint is shown after the mount, if successful.

- KAutoMount ( )

  returns dtor
  Not implemented

  KAutoMount deletes itself. Don't delete it manually.

- error ( )

  returns Nothing
  SIGNAL ("error ()")

  Emitted in case the directory could not been mounted

- finished ( )

  returns Nothing
  SIGNAL ("finished ()")

  Emitted when the directory has been mounted