Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | None |
Language | Haskell2010 |
Watches GUnixMounts
for changes.
Synopsis
- newtype UnixMountMonitor = UnixMountMonitor (ManagedPtr UnixMountMonitor)
- class (GObject o, IsDescendantOf UnixMountMonitor o) => IsUnixMountMonitor o
- toUnixMountMonitor :: (MonadIO m, IsUnixMountMonitor o) => o -> m UnixMountMonitor
- noUnixMountMonitor :: Maybe UnixMountMonitor
- unixMountMonitorGet :: (HasCallStack, MonadIO m) => m UnixMountMonitor
- unixMountMonitorNew :: (HasCallStack, MonadIO m) => m UnixMountMonitor
- unixMountMonitorSetRateLimit :: (HasCallStack, MonadIO m, IsUnixMountMonitor a) => a -> Int32 -> m ()
- type C_UnixMountMonitorMountpointsChangedCallback = Ptr () -> Ptr () -> IO ()
- type UnixMountMonitorMountpointsChangedCallback = IO ()
- afterUnixMountMonitorMountpointsChanged :: (IsUnixMountMonitor a, MonadIO m) => a -> UnixMountMonitorMountpointsChangedCallback -> m SignalHandlerId
- genClosure_UnixMountMonitorMountpointsChanged :: MonadIO m => UnixMountMonitorMountpointsChangedCallback -> m (GClosure C_UnixMountMonitorMountpointsChangedCallback)
- mk_UnixMountMonitorMountpointsChangedCallback :: C_UnixMountMonitorMountpointsChangedCallback -> IO (FunPtr C_UnixMountMonitorMountpointsChangedCallback)
- noUnixMountMonitorMountpointsChangedCallback :: Maybe UnixMountMonitorMountpointsChangedCallback
- onUnixMountMonitorMountpointsChanged :: (IsUnixMountMonitor a, MonadIO m) => a -> UnixMountMonitorMountpointsChangedCallback -> m SignalHandlerId
- wrap_UnixMountMonitorMountpointsChangedCallback :: UnixMountMonitorMountpointsChangedCallback -> C_UnixMountMonitorMountpointsChangedCallback
- type C_UnixMountMonitorMountsChangedCallback = Ptr () -> Ptr () -> IO ()
- type UnixMountMonitorMountsChangedCallback = IO ()
- afterUnixMountMonitorMountsChanged :: (IsUnixMountMonitor a, MonadIO m) => a -> UnixMountMonitorMountsChangedCallback -> m SignalHandlerId
- genClosure_UnixMountMonitorMountsChanged :: MonadIO m => UnixMountMonitorMountsChangedCallback -> m (GClosure C_UnixMountMonitorMountsChangedCallback)
- mk_UnixMountMonitorMountsChangedCallback :: C_UnixMountMonitorMountsChangedCallback -> IO (FunPtr C_UnixMountMonitorMountsChangedCallback)
- noUnixMountMonitorMountsChangedCallback :: Maybe UnixMountMonitorMountsChangedCallback
- onUnixMountMonitorMountsChanged :: (IsUnixMountMonitor a, MonadIO m) => a -> UnixMountMonitorMountsChangedCallback -> m SignalHandlerId
- wrap_UnixMountMonitorMountsChangedCallback :: UnixMountMonitorMountsChangedCallback -> C_UnixMountMonitorMountsChangedCallback
Exported types
newtype UnixMountMonitor Source #
Memory-managed wrapper type.
Instances
Eq UnixMountMonitor Source # | |
Defined in GI.Gio.Objects.UnixMountMonitor (==) :: UnixMountMonitor -> UnixMountMonitor -> Bool # (/=) :: UnixMountMonitor -> UnixMountMonitor -> Bool # | |
GObject UnixMountMonitor Source # | |
Defined in GI.Gio.Objects.UnixMountMonitor gobjectType :: IO GType # | |
IsGValue UnixMountMonitor Source # | Convert |
Defined in GI.Gio.Objects.UnixMountMonitor toGValue :: UnixMountMonitor -> IO GValue # fromGValue :: GValue -> IO UnixMountMonitor # | |
HasParentTypes UnixMountMonitor Source # | |
Defined in GI.Gio.Objects.UnixMountMonitor | |
type ParentTypes UnixMountMonitor Source # | |
Defined in GI.Gio.Objects.UnixMountMonitor |
class (GObject o, IsDescendantOf UnixMountMonitor o) => IsUnixMountMonitor o Source #
Type class for types which can be safely cast to UnixMountMonitor
, for instance with toUnixMountMonitor
.
Instances
(GObject o, IsDescendantOf UnixMountMonitor o) => IsUnixMountMonitor o Source # | |
Defined in GI.Gio.Objects.UnixMountMonitor |
toUnixMountMonitor :: (MonadIO m, IsUnixMountMonitor o) => o -> m UnixMountMonitor Source #
Cast to UnixMountMonitor
, for types for which this is known to be safe. For general casts, use castTo
.
noUnixMountMonitor :: Maybe UnixMountMonitor Source #
A convenience alias for Nothing
:: Maybe
UnixMountMonitor
.
Methods
Overloaded methods
get
:: (HasCallStack, MonadIO m) | |
=> m UnixMountMonitor | Returns: the |
Gets the UnixMountMonitor
for the current thread-default main
context.
The mount monitor can be used to monitor for changes to the list of mounted filesystems as well as the list of mount points (ie: fstab entries).
You must only call objectUnref
on the return value from under
the same main context as you called this function.
Since: 2.44
new
:: (HasCallStack, MonadIO m) | |
=> m UnixMountMonitor | Returns: a |
Deprecated: (Since version 2.44)Use unixMountMonitorGet
instead.
Deprecated alias for unixMountMonitorGet
.
This function was never a true constructor, which is why it was renamed.
setRateLimit
unixMountMonitorSetRateLimit Source #
:: (HasCallStack, MonadIO m, IsUnixMountMonitor a) | |
=> a |
|
-> Int32 |
|
-> m () |
Deprecated: (Since version 2.44)This function does nothing. Don't call it.
This function does nothing.
Before 2.44, this was a partially-effective way of controlling the
rate at which events would be reported under some uncommon
circumstances. Since mountMonitor
is a singleton, it also meant
that calling this function would have side effects for other users of
the monitor.
Since: 2.18
Signals
mountpointsChanged
type C_UnixMountMonitorMountpointsChangedCallback = Ptr () -> Ptr () -> IO () Source #
Type for the callback on the (unwrapped) C side.
type UnixMountMonitorMountpointsChangedCallback = IO () Source #
Emitted when the unix mount points have changed.
afterUnixMountMonitorMountpointsChanged :: (IsUnixMountMonitor a, MonadIO m) => a -> UnixMountMonitorMountpointsChangedCallback -> m SignalHandlerId Source #
Connect a signal handler for the mountpointsChanged signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
unixMountMonitor #mountpointsChanged callback
genClosure_UnixMountMonitorMountpointsChanged :: MonadIO m => UnixMountMonitorMountpointsChangedCallback -> m (GClosure C_UnixMountMonitorMountpointsChangedCallback) Source #
Wrap the callback into a GClosure
.
mk_UnixMountMonitorMountpointsChangedCallback :: C_UnixMountMonitorMountpointsChangedCallback -> IO (FunPtr C_UnixMountMonitorMountpointsChangedCallback) Source #
Generate a function pointer callable from C code, from a C_UnixMountMonitorMountpointsChangedCallback
.
noUnixMountMonitorMountpointsChangedCallback :: Maybe UnixMountMonitorMountpointsChangedCallback Source #
A convenience synonym for
.Nothing
:: Maybe
UnixMountMonitorMountpointsChangedCallback
onUnixMountMonitorMountpointsChanged :: (IsUnixMountMonitor a, MonadIO m) => a -> UnixMountMonitorMountpointsChangedCallback -> m SignalHandlerId Source #
Connect a signal handler for the mountpointsChanged signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
unixMountMonitor #mountpointsChanged callback
wrap_UnixMountMonitorMountpointsChangedCallback :: UnixMountMonitorMountpointsChangedCallback -> C_UnixMountMonitorMountpointsChangedCallback Source #
mountsChanged
type C_UnixMountMonitorMountsChangedCallback = Ptr () -> Ptr () -> IO () Source #
Type for the callback on the (unwrapped) C side.
type UnixMountMonitorMountsChangedCallback = IO () Source #
Emitted when the unix mounts have changed.
afterUnixMountMonitorMountsChanged :: (IsUnixMountMonitor a, MonadIO m) => a -> UnixMountMonitorMountsChangedCallback -> m SignalHandlerId Source #
Connect a signal handler for the mountsChanged signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
unixMountMonitor #mountsChanged callback
genClosure_UnixMountMonitorMountsChanged :: MonadIO m => UnixMountMonitorMountsChangedCallback -> m (GClosure C_UnixMountMonitorMountsChangedCallback) Source #
Wrap the callback into a GClosure
.
mk_UnixMountMonitorMountsChangedCallback :: C_UnixMountMonitorMountsChangedCallback -> IO (FunPtr C_UnixMountMonitorMountsChangedCallback) Source #
Generate a function pointer callable from C code, from a C_UnixMountMonitorMountsChangedCallback
.
noUnixMountMonitorMountsChangedCallback :: Maybe UnixMountMonitorMountsChangedCallback Source #
A convenience synonym for
.Nothing
:: Maybe
UnixMountMonitorMountsChangedCallback
onUnixMountMonitorMountsChanged :: (IsUnixMountMonitor a, MonadIO m) => a -> UnixMountMonitorMountsChangedCallback -> m SignalHandlerId Source #
Connect a signal handler for the mountsChanged signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
unixMountMonitor #mountsChanged callback