#### PyKDE - Python Bindings for KDE

# class KLockFile

Table of contents
Modules
kdecore Classes
All Classes

Module | kdecore
Class | KLockFile
Inherits | KShared

### enums

- LockOptions = {LockNoBlock, LockForce }
- LockResult = {LockOK, LockFail, LockError, LockStale }

### methods

- KLockFile (file)

  returns a KLockFile instance
  In versions KDE 3.3.0 and above only

  Argument | Type | Default
  --- | --- | ---
  file | QString |

- getLockInfo (hostname, appname)

  returns (bool) pid (int)
  In versions KDE 3.3.0 and above only

  Argument | Type | Default
  --- | --- | ---
  hostname | QString |
  appname | QString |

- isLocked ()

  returns (bool)
  In versions KDE 3.3.0 and above only

- lock (options = 0)

  returns (KLockFile.LockResult)
  In versions KDE 3.3.0 and above only

  Argument | Type | Default
  --- | --- | ---
  options | int | 0

- setStaleTime (_staleTime)

  returns nothing
  In versions KDE 3.3.0 and above only

  Argument | Type | Default
  --- | --- | ---
  _staleTime | int |

- staleTime ()

  returns (int)
  In versions KDE 3.3.0 and above only

- unlock ()

  returns nothing
  In versions KDE 3.3.0 and above only