{-# LANGUAGE TypeApplications #-}
#if (MIN_VERSION_haskell_gi_overloading(1,0,0) && !defined(__HADDOCK_VERSION__))
#define ENABLE_OVERLOADING
#endif
module GI.NM.Objects.SecretAgentOld
(
SecretAgentOld(..) ,
IsSecretAgentOld ,
toSecretAgentOld ,
#if defined(ENABLE_OVERLOADING)
ResolveSecretAgentOldMethod ,
#endif
#if defined(ENABLE_OVERLOADING)
SecretAgentOldDeleteSecretsMethodInfo ,
#endif
secretAgentOldDeleteSecrets ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldDestroyMethodInfo ,
#endif
secretAgentOldDestroy ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldEnableMethodInfo ,
#endif
secretAgentOldEnable ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldGetContextBusyWatcherMethodInfo,
#endif
secretAgentOldGetContextBusyWatcher ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldGetDbusConnectionMethodInfo,
#endif
secretAgentOldGetDbusConnection ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldGetDbusNameOwnerMethodInfo,
#endif
secretAgentOldGetDbusNameOwner ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldGetMainContextMethodInfo ,
#endif
secretAgentOldGetMainContext ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldGetRegisteredMethodInfo ,
#endif
secretAgentOldGetRegistered ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldGetSecretsMethodInfo ,
#endif
secretAgentOldGetSecrets ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldRegisterMethodInfo ,
#endif
secretAgentOldRegister ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldRegisterAsyncMethodInfo ,
#endif
secretAgentOldRegisterAsync ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldRegisterFinishMethodInfo ,
#endif
secretAgentOldRegisterFinish ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldSaveSecretsMethodInfo ,
#endif
secretAgentOldSaveSecrets ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldUnregisterMethodInfo ,
#endif
secretAgentOldUnregister ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldUnregisterAsyncMethodInfo ,
#endif
secretAgentOldUnregisterAsync ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldUnregisterFinishMethodInfo,
#endif
secretAgentOldUnregisterFinish ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldAutoRegisterPropertyInfo ,
#endif
constructSecretAgentOldAutoRegister ,
getSecretAgentOldAutoRegister ,
#if defined(ENABLE_OVERLOADING)
secretAgentOldAutoRegister ,
#endif
setSecretAgentOldAutoRegister ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldCapabilitiesPropertyInfo ,
#endif
constructSecretAgentOldCapabilities ,
getSecretAgentOldCapabilities ,
#if defined(ENABLE_OVERLOADING)
secretAgentOldCapabilities ,
#endif
setSecretAgentOldCapabilities ,
#if defined(ENABLE_OVERLOADING)
SecretAgentOldDbusConnectionPropertyInfo,
#endif
constructSecretAgentOldDbusConnection ,
getSecretAgentOldDbusConnection ,
#if defined(ENABLE_OVERLOADING)
secretAgentOldDbusConnection ,
#endif
#if defined(ENABLE_OVERLOADING)
SecretAgentOldIdentifierPropertyInfo ,
#endif
constructSecretAgentOldIdentifier ,
getSecretAgentOldIdentifier ,
#if defined(ENABLE_OVERLOADING)
secretAgentOldIdentifier ,
#endif
#if defined(ENABLE_OVERLOADING)
SecretAgentOldRegisteredPropertyInfo ,
#endif
getSecretAgentOldRegistered ,
#if defined(ENABLE_OVERLOADING)
secretAgentOldRegistered ,
#endif
) where
import Data.GI.Base.ShortPrelude
import qualified Data.GI.Base.ShortPrelude as SP
import qualified Data.GI.Base.Overloading as O
import qualified Prelude as P
import qualified Data.GI.Base.Attributes as GI.Attributes
import qualified Data.GI.Base.BasicTypes as B.Types
import qualified Data.GI.Base.ManagedPtr as B.ManagedPtr
import qualified Data.GI.Base.GArray as B.GArray
import qualified Data.GI.Base.GClosure as B.GClosure
import qualified Data.GI.Base.GError as B.GError
import qualified Data.GI.Base.GHashTable as B.GHT
import qualified Data.GI.Base.GVariant as B.GVariant
import qualified Data.GI.Base.GValue as B.GValue
import qualified Data.GI.Base.GParamSpec as B.GParamSpec
import qualified Data.GI.Base.CallStack as B.CallStack
import qualified Data.GI.Base.Properties as B.Properties
import qualified Data.GI.Base.Signals as B.Signals
import qualified Control.Monad.IO.Class as MIO
import qualified Data.Coerce as Coerce
import qualified Data.Text as T
import qualified Data.Kind as DK
import qualified Data.ByteString.Char8 as B
import qualified Data.Map as Map
import qualified Foreign.Ptr as FP
import qualified GHC.OverloadedLabels as OL
import qualified GHC.Records as R
import qualified Data.Word as DW
import qualified Data.Int as DI
import qualified System.Posix.Types as SPT
import qualified Foreign.C.Types as FCT
#if MIN_VERSION_base(4,18,0)
import qualified GI.GLib.Structs.Bytes as GLib.Bytes
import qualified GI.GLib.Structs.MainContext as GLib.MainContext
import qualified GI.GLib.Structs.VariantType as GLib.VariantType
import qualified GI.GObject.Objects.Object as GObject.Object
import qualified GI.Gio.Callbacks as Gio.Callbacks
import qualified GI.Gio.Interfaces.AsyncInitable as Gio.AsyncInitable
import qualified GI.Gio.Interfaces.AsyncResult as Gio.AsyncResult
import qualified GI.Gio.Interfaces.Initable as Gio.Initable
import qualified GI.Gio.Objects.Cancellable as Gio.Cancellable
import qualified GI.Gio.Objects.DBusConnection as Gio.DBusConnection
import qualified GI.NM.Callbacks as NM.Callbacks
import {-# SOURCE #-} qualified GI.NM.Enums as NM.Enums
import {-# SOURCE #-} qualified GI.NM.Flags as NM.Flags
import {-# SOURCE #-} qualified GI.NM.Interfaces.Connection as NM.Connection
import {-# SOURCE #-} qualified GI.NM.Objects.Setting as NM.Setting
import {-# SOURCE #-} qualified GI.NM.Objects.Setting8021x as NM.Setting8021x
import {-# SOURCE #-} qualified GI.NM.Objects.SettingAdsl as NM.SettingAdsl
import {-# SOURCE #-} qualified GI.NM.Objects.SettingBluetooth as NM.SettingBluetooth
import {-# SOURCE #-} qualified GI.NM.Objects.SettingBond as NM.SettingBond
import {-# SOURCE #-} qualified GI.NM.Objects.SettingBridge as NM.SettingBridge
import {-# SOURCE #-} qualified GI.NM.Objects.SettingBridgePort as NM.SettingBridgePort
import {-# SOURCE #-} qualified GI.NM.Objects.SettingCdma as NM.SettingCdma
import {-# SOURCE #-} qualified GI.NM.Objects.SettingConnection as NM.SettingConnection
import {-# SOURCE #-} qualified GI.NM.Objects.SettingDcb as NM.SettingDcb
import {-# SOURCE #-} qualified GI.NM.Objects.SettingDummy as NM.SettingDummy
import {-# SOURCE #-} qualified GI.NM.Objects.SettingGeneric as NM.SettingGeneric
import {-# SOURCE #-} qualified GI.NM.Objects.SettingGsm as NM.SettingGsm
import {-# SOURCE #-} qualified GI.NM.Objects.SettingIP4Config as NM.SettingIP4Config
import {-# SOURCE #-} qualified GI.NM.Objects.SettingIP6Config as NM.SettingIP6Config
import {-# SOURCE #-} qualified GI.NM.Objects.SettingIPConfig as NM.SettingIPConfig
import {-# SOURCE #-} qualified GI.NM.Objects.SettingIPTunnel as NM.SettingIPTunnel
import {-# SOURCE #-} qualified GI.NM.Objects.SettingInfiniband as NM.SettingInfiniband
import {-# SOURCE #-} qualified GI.NM.Objects.SettingMacsec as NM.SettingMacsec
import {-# SOURCE #-} qualified GI.NM.Objects.SettingMacvlan as NM.SettingMacvlan
import {-# SOURCE #-} qualified GI.NM.Objects.SettingOlpcMesh as NM.SettingOlpcMesh
import {-# SOURCE #-} qualified GI.NM.Objects.SettingOvsBridge as NM.SettingOvsBridge
import {-# SOURCE #-} qualified GI.NM.Objects.SettingOvsInterface as NM.SettingOvsInterface
import {-# SOURCE #-} qualified GI.NM.Objects.SettingOvsPatch as NM.SettingOvsPatch
import {-# SOURCE #-} qualified GI.NM.Objects.SettingOvsPort as NM.SettingOvsPort
import {-# SOURCE #-} qualified GI.NM.Objects.SettingPpp as NM.SettingPpp
import {-# SOURCE #-} qualified GI.NM.Objects.SettingPppoe as NM.SettingPppoe
import {-# SOURCE #-} qualified GI.NM.Objects.SettingProxy as NM.SettingProxy
import {-# SOURCE #-} qualified GI.NM.Objects.SettingSerial as NM.SettingSerial
import {-# SOURCE #-} qualified GI.NM.Objects.SettingTCConfig as NM.SettingTCConfig
import {-# SOURCE #-} qualified GI.NM.Objects.SettingTeam as NM.SettingTeam
import {-# SOURCE #-} qualified GI.NM.Objects.SettingTeamPort as NM.SettingTeamPort
import {-# SOURCE #-} qualified GI.NM.Objects.SettingTun as NM.SettingTun
import {-# SOURCE #-} qualified GI.NM.Objects.SettingVlan as NM.SettingVlan
import {-# SOURCE #-} qualified GI.NM.Objects.SettingVpn as NM.SettingVpn
import {-# SOURCE #-} qualified GI.NM.Objects.SettingVxlan as NM.SettingVxlan
import {-# SOURCE #-} qualified GI.NM.Objects.SettingWimax as NM.SettingWimax
import {-# SOURCE #-} qualified GI.NM.Objects.SettingWired as NM.SettingWired
import {-# SOURCE #-} qualified GI.NM.Objects.SettingWireless as NM.SettingWireless
import {-# SOURCE #-} qualified GI.NM.Objects.SettingWirelessSecurity as NM.SettingWirelessSecurity
import {-# SOURCE #-} qualified GI.NM.Structs.BridgeVlan as NM.BridgeVlan
import {-# SOURCE #-} qualified GI.NM.Structs.IPAddress as NM.IPAddress
import {-# SOURCE #-} qualified GI.NM.Structs.IPRoute as NM.IPRoute
import {-# SOURCE #-} qualified GI.NM.Structs.IPRoutingRule as NM.IPRoutingRule
import {-# SOURCE #-} qualified GI.NM.Structs.Range as NM.Range
import {-# SOURCE #-} qualified GI.NM.Structs.TCAction as NM.TCAction
import {-# SOURCE #-} qualified GI.NM.Structs.TCQdisc as NM.TCQdisc
import {-# SOURCE #-} qualified GI.NM.Structs.TCTfilter as NM.TCTfilter
import {-# SOURCE #-} qualified GI.NM.Structs.TeamLinkWatcher as NM.TeamLinkWatcher
import {-# SOURCE #-} qualified GI.NM.Structs.VariantAttributeSpec as NM.VariantAttributeSpec
#else
import qualified GI.GLib.Structs.MainContext as GLib.MainContext
import qualified GI.GObject.Objects.Object as GObject.Object
import qualified GI.Gio.Callbacks as Gio.Callbacks
import qualified GI.Gio.Interfaces.AsyncInitable as Gio.AsyncInitable
import qualified GI.Gio.Interfaces.AsyncResult as Gio.AsyncResult
import qualified GI.Gio.Interfaces.Initable as Gio.Initable
import qualified GI.Gio.Objects.Cancellable as Gio.Cancellable
import qualified GI.Gio.Objects.DBusConnection as Gio.DBusConnection
import qualified GI.NM.Callbacks as NM.Callbacks
import {-# SOURCE #-} qualified GI.NM.Flags as NM.Flags
import {-# SOURCE #-} qualified GI.NM.Interfaces.Connection as NM.Connection
#endif
newtype SecretAgentOld = SecretAgentOld (SP.ManagedPtr SecretAgentOld)
deriving (SecretAgentOld -> SecretAgentOld -> Bool
(SecretAgentOld -> SecretAgentOld -> Bool)
-> (SecretAgentOld -> SecretAgentOld -> Bool) -> Eq SecretAgentOld
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: SecretAgentOld -> SecretAgentOld -> Bool
== :: SecretAgentOld -> SecretAgentOld -> Bool
$c/= :: SecretAgentOld -> SecretAgentOld -> Bool
/= :: SecretAgentOld -> SecretAgentOld -> Bool
Eq)
instance SP.ManagedPtrNewtype SecretAgentOld where
toManagedPtr :: SecretAgentOld -> ManagedPtr SecretAgentOld
toManagedPtr (SecretAgentOld ManagedPtr SecretAgentOld
p) = ManagedPtr SecretAgentOld
p
foreign import ccall "nm_secret_agent_old_get_type"
c_nm_secret_agent_old_get_type :: IO B.Types.GType
instance B.Types.TypedObject SecretAgentOld where
glibType :: IO GType
glibType = IO GType
c_nm_secret_agent_old_get_type
instance B.Types.GObject SecretAgentOld
class (SP.GObject o, O.IsDescendantOf SecretAgentOld o) => IsSecretAgentOld o
instance (SP.GObject o, O.IsDescendantOf SecretAgentOld o) => IsSecretAgentOld o
instance O.HasParentTypes SecretAgentOld
type instance O.ParentTypes SecretAgentOld = '[GObject.Object.Object, Gio.AsyncInitable.AsyncInitable, Gio.Initable.Initable]
toSecretAgentOld :: (MIO.MonadIO m, IsSecretAgentOld o) => o -> m SecretAgentOld
toSecretAgentOld :: forall (m :: * -> *) o.
(MonadIO m, IsSecretAgentOld o) =>
o -> m SecretAgentOld
toSecretAgentOld = IO SecretAgentOld -> m SecretAgentOld
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO SecretAgentOld -> m SecretAgentOld)
-> (o -> IO SecretAgentOld) -> o -> m SecretAgentOld
forall b c a. (b -> c) -> (a -> b) -> a -> c
. (ManagedPtr SecretAgentOld -> SecretAgentOld)
-> o -> IO SecretAgentOld
forall o o'.
(HasCallStack, ManagedPtrNewtype o, TypedObject o,
ManagedPtrNewtype o', TypedObject o') =>
(ManagedPtr o' -> o') -> o -> IO o'
B.ManagedPtr.unsafeCastTo ManagedPtr SecretAgentOld -> SecretAgentOld
SecretAgentOld
instance B.GValue.IsGValue (Maybe SecretAgentOld) where
gvalueGType_ :: IO GType
gvalueGType_ = IO GType
c_nm_secret_agent_old_get_type
gvalueSet_ :: Ptr GValue -> Maybe SecretAgentOld -> IO ()
gvalueSet_ Ptr GValue
gv Maybe SecretAgentOld
P.Nothing = Ptr GValue -> Ptr SecretAgentOld -> IO ()
forall a. GObject a => Ptr GValue -> Ptr a -> IO ()
B.GValue.set_object Ptr GValue
gv (Ptr SecretAgentOld
forall a. Ptr a
FP.nullPtr :: FP.Ptr SecretAgentOld)
gvalueSet_ Ptr GValue
gv (P.Just SecretAgentOld
obj) = SecretAgentOld -> (Ptr SecretAgentOld -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
B.ManagedPtr.withManagedPtr SecretAgentOld
obj (Ptr GValue -> Ptr SecretAgentOld -> IO ()
forall a. GObject a => Ptr GValue -> Ptr a -> IO ()
B.GValue.set_object Ptr GValue
gv)
gvalueGet_ :: Ptr GValue -> IO (Maybe SecretAgentOld)
gvalueGet_ Ptr GValue
gv = do
Ptr SecretAgentOld
ptr <- Ptr GValue -> IO (Ptr SecretAgentOld)
forall a. GObject a => Ptr GValue -> IO (Ptr a)
B.GValue.get_object Ptr GValue
gv :: IO (FP.Ptr SecretAgentOld)
if Ptr SecretAgentOld
ptr Ptr SecretAgentOld -> Ptr SecretAgentOld -> Bool
forall a. Eq a => a -> a -> Bool
/= Ptr SecretAgentOld
forall a. Ptr a
FP.nullPtr
then SecretAgentOld -> Maybe SecretAgentOld
forall a. a -> Maybe a
P.Just (SecretAgentOld -> Maybe SecretAgentOld)
-> IO SecretAgentOld -> IO (Maybe SecretAgentOld)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> (ManagedPtr SecretAgentOld -> SecretAgentOld)
-> Ptr SecretAgentOld -> IO SecretAgentOld
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
B.ManagedPtr.newObject ManagedPtr SecretAgentOld -> SecretAgentOld
SecretAgentOld Ptr SecretAgentOld
ptr
else Maybe SecretAgentOld -> IO (Maybe SecretAgentOld)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe SecretAgentOld
forall a. Maybe a
P.Nothing
#if defined(ENABLE_OVERLOADING)
type family ResolveSecretAgentOldMethod (t :: Symbol) (o :: DK.Type) :: DK.Type where
ResolveSecretAgentOldMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo
ResolveSecretAgentOldMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo
ResolveSecretAgentOldMethod "deleteSecrets" o = SecretAgentOldDeleteSecretsMethodInfo
ResolveSecretAgentOldMethod "destroy" o = SecretAgentOldDestroyMethodInfo
ResolveSecretAgentOldMethod "enable" o = SecretAgentOldEnableMethodInfo
ResolveSecretAgentOldMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo
ResolveSecretAgentOldMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo
ResolveSecretAgentOldMethod "getv" o = GObject.Object.ObjectGetvMethodInfo
ResolveSecretAgentOldMethod "init" o = Gio.Initable.InitableInitMethodInfo
ResolveSecretAgentOldMethod "initAsync" o = Gio.AsyncInitable.AsyncInitableInitAsyncMethodInfo
ResolveSecretAgentOldMethod "initFinish" o = Gio.AsyncInitable.AsyncInitableInitFinishMethodInfo
ResolveSecretAgentOldMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo
ResolveSecretAgentOldMethod "newFinish" o = Gio.AsyncInitable.AsyncInitableNewFinishMethodInfo
ResolveSecretAgentOldMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo
ResolveSecretAgentOldMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo
ResolveSecretAgentOldMethod "ref" o = GObject.Object.ObjectRefMethodInfo
ResolveSecretAgentOldMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo
ResolveSecretAgentOldMethod "register" o = SecretAgentOldRegisterMethodInfo
ResolveSecretAgentOldMethod "registerAsync" o = SecretAgentOldRegisterAsyncMethodInfo
ResolveSecretAgentOldMethod "registerFinish" o = SecretAgentOldRegisterFinishMethodInfo
ResolveSecretAgentOldMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo
ResolveSecretAgentOldMethod "saveSecrets" o = SecretAgentOldSaveSecretsMethodInfo
ResolveSecretAgentOldMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo
ResolveSecretAgentOldMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo
ResolveSecretAgentOldMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo
ResolveSecretAgentOldMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo
ResolveSecretAgentOldMethod "unregister" o = SecretAgentOldUnregisterMethodInfo
ResolveSecretAgentOldMethod "unregisterAsync" o = SecretAgentOldUnregisterAsyncMethodInfo
ResolveSecretAgentOldMethod "unregisterFinish" o = SecretAgentOldUnregisterFinishMethodInfo
ResolveSecretAgentOldMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo
ResolveSecretAgentOldMethod "getContextBusyWatcher" o = SecretAgentOldGetContextBusyWatcherMethodInfo
ResolveSecretAgentOldMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo
ResolveSecretAgentOldMethod "getDbusConnection" o = SecretAgentOldGetDbusConnectionMethodInfo
ResolveSecretAgentOldMethod "getDbusNameOwner" o = SecretAgentOldGetDbusNameOwnerMethodInfo
ResolveSecretAgentOldMethod "getMainContext" o = SecretAgentOldGetMainContextMethodInfo
ResolveSecretAgentOldMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo
ResolveSecretAgentOldMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo
ResolveSecretAgentOldMethod "getRegistered" o = SecretAgentOldGetRegisteredMethodInfo
ResolveSecretAgentOldMethod "getSecrets" o = SecretAgentOldGetSecretsMethodInfo
ResolveSecretAgentOldMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo
ResolveSecretAgentOldMethod "setDataFull" o = GObject.Object.ObjectSetDataFullMethodInfo
ResolveSecretAgentOldMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo
ResolveSecretAgentOldMethod l o = O.MethodResolutionFailed l o
instance (info ~ ResolveSecretAgentOldMethod t SecretAgentOld, O.OverloadedMethod info SecretAgentOld p) => OL.IsLabel t (SecretAgentOld -> p) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.overloadedMethod @info
#else
fromLabel _ = O.overloadedMethod @info
#endif
#if MIN_VERSION_base(4,13,0)
instance (info ~ ResolveSecretAgentOldMethod t SecretAgentOld, O.OverloadedMethod info SecretAgentOld p, R.HasField t SecretAgentOld p) => R.HasField t SecretAgentOld p where
getField = O.overloadedMethod @info
#endif
instance (info ~ ResolveSecretAgentOldMethod t SecretAgentOld, O.OverloadedMethodInfo info SecretAgentOld) => OL.IsLabel t (O.MethodProxy info SecretAgentOld) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.MethodProxy
#else
fromLabel _ = O.MethodProxy
#endif
#endif
getSecretAgentOldAutoRegister :: (MonadIO m, IsSecretAgentOld o) => o -> m Bool
getSecretAgentOldAutoRegister :: forall (m :: * -> *) o.
(MonadIO m, IsSecretAgentOld o) =>
o -> m Bool
getSecretAgentOldAutoRegister o
obj = IO Bool -> m Bool
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO Bool -> m Bool) -> IO Bool -> m Bool
forall a b. (a -> b) -> a -> b
$ o -> String -> IO Bool
forall a. GObject a => a -> String -> IO Bool
B.Properties.getObjectPropertyBool o
obj String
"auto-register"
setSecretAgentOldAutoRegister :: (MonadIO m, IsSecretAgentOld o) => o -> Bool -> m ()
setSecretAgentOldAutoRegister :: forall (m :: * -> *) o.
(MonadIO m, IsSecretAgentOld o) =>
o -> Bool -> m ()
setSecretAgentOldAutoRegister o
obj Bool
val = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
o -> String -> Bool -> IO ()
forall a. GObject a => a -> String -> Bool -> IO ()
B.Properties.setObjectPropertyBool o
obj String
"auto-register" Bool
val
constructSecretAgentOldAutoRegister :: (IsSecretAgentOld o, MIO.MonadIO m) => Bool -> m (GValueConstruct o)
constructSecretAgentOldAutoRegister :: forall o (m :: * -> *).
(IsSecretAgentOld o, MonadIO m) =>
Bool -> m (GValueConstruct o)
constructSecretAgentOldAutoRegister Bool
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a. IO a -> IO a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> Bool -> IO (GValueConstruct o)
forall o. String -> Bool -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyBool String
"auto-register" Bool
val
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldAutoRegisterPropertyInfo
instance AttrInfo SecretAgentOldAutoRegisterPropertyInfo where
type AttrAllowedOps SecretAgentOldAutoRegisterPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
type AttrBaseTypeConstraint SecretAgentOldAutoRegisterPropertyInfo = IsSecretAgentOld
type AttrSetTypeConstraint SecretAgentOldAutoRegisterPropertyInfo = (~) Bool
type AttrTransferTypeConstraint SecretAgentOldAutoRegisterPropertyInfo = (~) Bool
type AttrTransferType SecretAgentOldAutoRegisterPropertyInfo = Bool
type AttrGetType SecretAgentOldAutoRegisterPropertyInfo = Bool
type AttrLabel SecretAgentOldAutoRegisterPropertyInfo = "auto-register"
type AttrOrigin SecretAgentOldAutoRegisterPropertyInfo = SecretAgentOld
attrGet = getSecretAgentOldAutoRegister
attrSet = setSecretAgentOldAutoRegister
attrTransfer _ v = do
return v
attrConstruct = constructSecretAgentOldAutoRegister
attrClear = undefined
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.autoRegister"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#g:attr:autoRegister"
})
#endif
getSecretAgentOldCapabilities :: (MonadIO m, IsSecretAgentOld o) => o -> m [NM.Flags.SecretAgentCapabilities]
getSecretAgentOldCapabilities :: forall (m :: * -> *) o.
(MonadIO m, IsSecretAgentOld o) =>
o -> m [SecretAgentCapabilities]
getSecretAgentOldCapabilities o
obj = IO [SecretAgentCapabilities] -> m [SecretAgentCapabilities]
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO [SecretAgentCapabilities] -> m [SecretAgentCapabilities])
-> IO [SecretAgentCapabilities] -> m [SecretAgentCapabilities]
forall a b. (a -> b) -> a -> b
$ o -> String -> IO [SecretAgentCapabilities]
forall a b.
(GObject a, IsGFlag b, BoxedFlags b) =>
a -> String -> IO [b]
B.Properties.getObjectPropertyFlags o
obj String
"capabilities"
setSecretAgentOldCapabilities :: (MonadIO m, IsSecretAgentOld o) => o -> [NM.Flags.SecretAgentCapabilities] -> m ()
setSecretAgentOldCapabilities :: forall (m :: * -> *) o.
(MonadIO m, IsSecretAgentOld o) =>
o -> [SecretAgentCapabilities] -> m ()
setSecretAgentOldCapabilities o
obj [SecretAgentCapabilities]
val = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
o -> String -> [SecretAgentCapabilities] -> IO ()
forall a b.
(IsGFlag b, BoxedFlags b, GObject a) =>
a -> String -> [b] -> IO ()
B.Properties.setObjectPropertyFlags o
obj String
"capabilities" [SecretAgentCapabilities]
val
constructSecretAgentOldCapabilities :: (IsSecretAgentOld o, MIO.MonadIO m) => [NM.Flags.SecretAgentCapabilities] -> m (GValueConstruct o)
constructSecretAgentOldCapabilities :: forall o (m :: * -> *).
(IsSecretAgentOld o, MonadIO m) =>
[SecretAgentCapabilities] -> m (GValueConstruct o)
constructSecretAgentOldCapabilities [SecretAgentCapabilities]
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a. IO a -> IO a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> [SecretAgentCapabilities] -> IO (GValueConstruct o)
forall a o.
(IsGFlag a, BoxedFlags a) =>
String -> [a] -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyFlags String
"capabilities" [SecretAgentCapabilities]
val
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldCapabilitiesPropertyInfo
instance AttrInfo SecretAgentOldCapabilitiesPropertyInfo where
type AttrAllowedOps SecretAgentOldCapabilitiesPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
type AttrBaseTypeConstraint SecretAgentOldCapabilitiesPropertyInfo = IsSecretAgentOld
type AttrSetTypeConstraint SecretAgentOldCapabilitiesPropertyInfo = (~) [NM.Flags.SecretAgentCapabilities]
type AttrTransferTypeConstraint SecretAgentOldCapabilitiesPropertyInfo = (~) [NM.Flags.SecretAgentCapabilities]
type AttrTransferType SecretAgentOldCapabilitiesPropertyInfo = [NM.Flags.SecretAgentCapabilities]
type AttrGetType SecretAgentOldCapabilitiesPropertyInfo = [NM.Flags.SecretAgentCapabilities]
type AttrLabel SecretAgentOldCapabilitiesPropertyInfo = "capabilities"
type AttrOrigin SecretAgentOldCapabilitiesPropertyInfo = SecretAgentOld
attrGet = getSecretAgentOldCapabilities
attrSet = setSecretAgentOldCapabilities
attrTransfer _ v = do
return v
attrConstruct = constructSecretAgentOldCapabilities
attrClear = undefined
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.capabilities"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#g:attr:capabilities"
})
#endif
getSecretAgentOldDbusConnection :: (MonadIO m, IsSecretAgentOld o) => o -> m Gio.DBusConnection.DBusConnection
getSecretAgentOldDbusConnection :: forall (m :: * -> *) o.
(MonadIO m, IsSecretAgentOld o) =>
o -> m DBusConnection
getSecretAgentOldDbusConnection o
obj = IO DBusConnection -> m DBusConnection
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO DBusConnection -> m DBusConnection)
-> IO DBusConnection -> m DBusConnection
forall a b. (a -> b) -> a -> b
$ Text -> IO (Maybe DBusConnection) -> IO DBusConnection
forall a. HasCallStack => Text -> IO (Maybe a) -> IO a
checkUnexpectedNothing Text
"getSecretAgentOldDbusConnection" (IO (Maybe DBusConnection) -> IO DBusConnection)
-> IO (Maybe DBusConnection) -> IO DBusConnection
forall a b. (a -> b) -> a -> b
$ o
-> String
-> (ManagedPtr DBusConnection -> DBusConnection)
-> IO (Maybe DBusConnection)
forall a b.
(GObject a, GObject b) =>
a -> String -> (ManagedPtr b -> b) -> IO (Maybe b)
B.Properties.getObjectPropertyObject o
obj String
"dbus-connection" ManagedPtr DBusConnection -> DBusConnection
Gio.DBusConnection.DBusConnection
constructSecretAgentOldDbusConnection :: (IsSecretAgentOld o, MIO.MonadIO m, Gio.DBusConnection.IsDBusConnection a) => a -> m (GValueConstruct o)
constructSecretAgentOldDbusConnection :: forall o (m :: * -> *) a.
(IsSecretAgentOld o, MonadIO m, IsDBusConnection a) =>
a -> m (GValueConstruct o)
constructSecretAgentOldDbusConnection a
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a. IO a -> IO a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> Maybe a -> IO (GValueConstruct o)
forall a o.
GObject a =>
String -> Maybe a -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyObject String
"dbus-connection" (a -> Maybe a
forall a. a -> Maybe a
P.Just a
val)
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldDbusConnectionPropertyInfo
instance AttrInfo SecretAgentOldDbusConnectionPropertyInfo where
type AttrAllowedOps SecretAgentOldDbusConnectionPropertyInfo = '[ 'AttrConstruct, 'AttrGet, 'AttrClear]
type AttrBaseTypeConstraint SecretAgentOldDbusConnectionPropertyInfo = IsSecretAgentOld
type AttrSetTypeConstraint SecretAgentOldDbusConnectionPropertyInfo = Gio.DBusConnection.IsDBusConnection
type AttrTransferTypeConstraint SecretAgentOldDbusConnectionPropertyInfo = Gio.DBusConnection.IsDBusConnection
type AttrTransferType SecretAgentOldDbusConnectionPropertyInfo = Gio.DBusConnection.DBusConnection
type AttrGetType SecretAgentOldDbusConnectionPropertyInfo = Gio.DBusConnection.DBusConnection
type AttrLabel SecretAgentOldDbusConnectionPropertyInfo = "dbus-connection"
type AttrOrigin SecretAgentOldDbusConnectionPropertyInfo = SecretAgentOld
attrGet = getSecretAgentOldDbusConnection
attrSet = undefined
attrTransfer _ v = do
unsafeCastTo Gio.DBusConnection.DBusConnection v
attrConstruct = constructSecretAgentOldDbusConnection
attrClear = undefined
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.dbusConnection"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#g:attr:dbusConnection"
})
#endif
getSecretAgentOldIdentifier :: (MonadIO m, IsSecretAgentOld o) => o -> m (Maybe T.Text)
getSecretAgentOldIdentifier :: forall (m :: * -> *) o.
(MonadIO m, IsSecretAgentOld o) =>
o -> m (Maybe Text)
getSecretAgentOldIdentifier o
obj = IO (Maybe Text) -> m (Maybe Text)
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (Maybe Text) -> m (Maybe Text))
-> IO (Maybe Text) -> m (Maybe Text)
forall a b. (a -> b) -> a -> b
$ o -> String -> IO (Maybe Text)
forall a. GObject a => a -> String -> IO (Maybe Text)
B.Properties.getObjectPropertyString o
obj String
"identifier"
constructSecretAgentOldIdentifier :: (IsSecretAgentOld o, MIO.MonadIO m) => T.Text -> m (GValueConstruct o)
constructSecretAgentOldIdentifier :: forall o (m :: * -> *).
(IsSecretAgentOld o, MonadIO m) =>
Text -> m (GValueConstruct o)
constructSecretAgentOldIdentifier Text
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a. IO a -> IO a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> Maybe Text -> IO (GValueConstruct o)
forall o. String -> Maybe Text -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyString String
"identifier" (Text -> Maybe Text
forall a. a -> Maybe a
P.Just Text
val)
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldIdentifierPropertyInfo
instance AttrInfo SecretAgentOldIdentifierPropertyInfo where
type AttrAllowedOps SecretAgentOldIdentifierPropertyInfo = '[ 'AttrConstruct, 'AttrGet, 'AttrClear]
type AttrBaseTypeConstraint SecretAgentOldIdentifierPropertyInfo = IsSecretAgentOld
type AttrSetTypeConstraint SecretAgentOldIdentifierPropertyInfo = (~) T.Text
type AttrTransferTypeConstraint SecretAgentOldIdentifierPropertyInfo = (~) T.Text
type AttrTransferType SecretAgentOldIdentifierPropertyInfo = T.Text
type AttrGetType SecretAgentOldIdentifierPropertyInfo = (Maybe T.Text)
type AttrLabel SecretAgentOldIdentifierPropertyInfo = "identifier"
type AttrOrigin SecretAgentOldIdentifierPropertyInfo = SecretAgentOld
attrGet = getSecretAgentOldIdentifier
attrSet = undefined
attrTransfer _ v = do
return v
attrConstruct = constructSecretAgentOldIdentifier
attrClear = undefined
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.identifier"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#g:attr:identifier"
})
#endif
getSecretAgentOldRegistered :: (MonadIO m, IsSecretAgentOld o) => o -> m Bool
getSecretAgentOldRegistered :: forall (m :: * -> *) o.
(MonadIO m, IsSecretAgentOld o) =>
o -> m Bool
getSecretAgentOldRegistered o
obj = IO Bool -> m Bool
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO Bool -> m Bool) -> IO Bool -> m Bool
forall a b. (a -> b) -> a -> b
$ o -> String -> IO Bool
forall a. GObject a => a -> String -> IO Bool
B.Properties.getObjectPropertyBool o
obj String
"registered"
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldRegisteredPropertyInfo
instance AttrInfo SecretAgentOldRegisteredPropertyInfo where
type AttrAllowedOps SecretAgentOldRegisteredPropertyInfo = '[ 'AttrGet]
type AttrBaseTypeConstraint SecretAgentOldRegisteredPropertyInfo = IsSecretAgentOld
type AttrSetTypeConstraint SecretAgentOldRegisteredPropertyInfo = (~) ()
type AttrTransferTypeConstraint SecretAgentOldRegisteredPropertyInfo = (~) ()
type AttrTransferType SecretAgentOldRegisteredPropertyInfo = ()
type AttrGetType SecretAgentOldRegisteredPropertyInfo = Bool
type AttrLabel SecretAgentOldRegisteredPropertyInfo = "registered"
type AttrOrigin SecretAgentOldRegisteredPropertyInfo = SecretAgentOld
attrGet = getSecretAgentOldRegistered
attrSet = undefined
attrTransfer _ = undefined
attrConstruct = undefined
attrClear = undefined
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.registered"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#g:attr:registered"
})
#endif
#if defined(ENABLE_OVERLOADING)
instance O.HasAttributeList SecretAgentOld
type instance O.AttributeList SecretAgentOld = SecretAgentOldAttributeList
type SecretAgentOldAttributeList = ('[ '("autoRegister", SecretAgentOldAutoRegisterPropertyInfo), '("capabilities", SecretAgentOldCapabilitiesPropertyInfo), '("dbusConnection", SecretAgentOldDbusConnectionPropertyInfo), '("identifier", SecretAgentOldIdentifierPropertyInfo), '("registered", SecretAgentOldRegisteredPropertyInfo)] :: [(Symbol, DK.Type)])
#endif
#if defined(ENABLE_OVERLOADING)
secretAgentOldAutoRegister :: AttrLabelProxy "autoRegister"
secretAgentOldAutoRegister = AttrLabelProxy
secretAgentOldCapabilities :: AttrLabelProxy "capabilities"
secretAgentOldCapabilities = AttrLabelProxy
secretAgentOldDbusConnection :: AttrLabelProxy "dbusConnection"
secretAgentOldDbusConnection = AttrLabelProxy
secretAgentOldIdentifier :: AttrLabelProxy "identifier"
secretAgentOldIdentifier = AttrLabelProxy
secretAgentOldRegistered :: AttrLabelProxy "registered"
secretAgentOldRegistered = AttrLabelProxy
#endif
#if defined(ENABLE_OVERLOADING)
type instance O.SignalList SecretAgentOld = SecretAgentOldSignalList
type SecretAgentOldSignalList = ('[ '("notify", GObject.Object.ObjectNotifySignalInfo)] :: [(Symbol, DK.Type)])
#endif
foreign import ccall "nm_secret_agent_old_delete_secrets" nm_secret_agent_old_delete_secrets ::
Ptr SecretAgentOld ->
Ptr NM.Connection.Connection ->
FunPtr NM.Callbacks.C_SecretAgentOldDeleteSecretsFunc ->
Ptr () ->
IO ()
secretAgentOldDeleteSecrets ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a, NM.Connection.IsConnection b) =>
a
-> b
-> NM.Callbacks.SecretAgentOldDeleteSecretsFunc
-> m ()
secretAgentOldDeleteSecrets :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsSecretAgentOld a, IsConnection b) =>
a -> b -> SecretAgentOldDeleteSecretsFunc -> m ()
secretAgentOldDeleteSecrets a
self b
connection SecretAgentOldDeleteSecretsFunc
callback = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr Connection
connection' <- b -> IO (Ptr Connection)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr b
connection
Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc)
ptrcallback <- IO (Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc))
forall a. Storable a => IO (Ptr a)
callocMem :: IO (Ptr (FunPtr NM.Callbacks.C_SecretAgentOldDeleteSecretsFunc))
FunPtr C_SecretAgentOldDeleteSecretsFunc
callback' <- C_SecretAgentOldDeleteSecretsFunc
-> IO (FunPtr C_SecretAgentOldDeleteSecretsFunc)
NM.Callbacks.mk_SecretAgentOldDeleteSecretsFunc (Maybe (Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc))
-> SecretAgentOldDeleteSecretsFunc_WithClosures
-> C_SecretAgentOldDeleteSecretsFunc
NM.Callbacks.wrap_SecretAgentOldDeleteSecretsFunc (Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc)
-> Maybe (Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc))
forall a. a -> Maybe a
Just Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc)
ptrcallback) (SecretAgentOldDeleteSecretsFunc
-> SecretAgentOldDeleteSecretsFunc_WithClosures
NM.Callbacks.drop_closures_SecretAgentOldDeleteSecretsFunc SecretAgentOldDeleteSecretsFunc
callback))
Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc)
-> FunPtr C_SecretAgentOldDeleteSecretsFunc -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc)
ptrcallback FunPtr C_SecretAgentOldDeleteSecretsFunc
callback'
let userData :: Ptr a
userData = Ptr a
forall a. Ptr a
nullPtr
Ptr SecretAgentOld
-> Ptr Connection
-> FunPtr C_SecretAgentOldDeleteSecretsFunc
-> Ptr ()
-> IO ()
nm_secret_agent_old_delete_secrets Ptr SecretAgentOld
self' Ptr Connection
connection' FunPtr C_SecretAgentOldDeleteSecretsFunc
callback' Ptr ()
forall a. Ptr a
userData
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
b -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr b
connection
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldDeleteSecretsMethodInfo
instance (signature ~ (b -> NM.Callbacks.SecretAgentOldDeleteSecretsFunc -> m ()), MonadIO m, IsSecretAgentOld a, NM.Connection.IsConnection b) => O.OverloadedMethod SecretAgentOldDeleteSecretsMethodInfo a signature where
overloadedMethod = secretAgentOldDeleteSecrets
instance O.OverloadedMethodInfo SecretAgentOldDeleteSecretsMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldDeleteSecrets",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldDeleteSecrets"
})
#endif
foreign import ccall "nm_secret_agent_old_destroy" nm_secret_agent_old_destroy ::
Ptr SecretAgentOld ->
IO ()
secretAgentOldDestroy ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a
-> m ()
secretAgentOldDestroy :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a -> m ()
secretAgentOldDestroy a
self = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr SecretAgentOld -> IO ()
nm_secret_agent_old_destroy Ptr SecretAgentOld
self'
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldDestroyMethodInfo
instance (signature ~ (m ()), MonadIO m, IsSecretAgentOld a) => O.OverloadedMethod SecretAgentOldDestroyMethodInfo a signature where
overloadedMethod = secretAgentOldDestroy
instance O.OverloadedMethodInfo SecretAgentOldDestroyMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldDestroy",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldDestroy"
})
#endif
foreign import ccall "nm_secret_agent_old_enable" nm_secret_agent_old_enable ::
Ptr SecretAgentOld ->
CInt ->
IO ()
secretAgentOldEnable ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a
-> Bool
-> m ()
secretAgentOldEnable :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a -> Bool -> m ()
secretAgentOldEnable a
self Bool
enable = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
let enable' :: CInt
enable' = (Int -> CInt
forall a b. (Integral a, Num b) => a -> b
P.fromIntegral (Int -> CInt) -> (Bool -> Int) -> Bool -> CInt
forall b c a. (b -> c) -> (a -> b) -> a -> c
. Bool -> Int
forall a. Enum a => a -> Int
P.fromEnum) Bool
enable
Ptr SecretAgentOld -> CInt -> IO ()
nm_secret_agent_old_enable Ptr SecretAgentOld
self' CInt
enable'
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldEnableMethodInfo
instance (signature ~ (Bool -> m ()), MonadIO m, IsSecretAgentOld a) => O.OverloadedMethod SecretAgentOldEnableMethodInfo a signature where
overloadedMethod = secretAgentOldEnable
instance O.OverloadedMethodInfo SecretAgentOldEnableMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldEnable",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldEnable"
})
#endif
foreign import ccall "nm_secret_agent_old_get_context_busy_watcher" nm_secret_agent_old_get_context_busy_watcher ::
Ptr SecretAgentOld ->
IO (Ptr GObject.Object.Object)
secretAgentOldGetContextBusyWatcher ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a
-> m GObject.Object.Object
secretAgentOldGetContextBusyWatcher :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a -> m Object
secretAgentOldGetContextBusyWatcher a
self = IO Object -> m Object
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Object -> m Object) -> IO Object -> m Object
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr Object
result <- Ptr SecretAgentOld -> IO (Ptr Object)
nm_secret_agent_old_get_context_busy_watcher Ptr SecretAgentOld
self'
Text -> Ptr Object -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"secretAgentOldGetContextBusyWatcher" Ptr Object
result
Object
result' <- ((ManagedPtr Object -> Object) -> Ptr Object -> IO Object
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr Object -> Object
GObject.Object.Object) Ptr Object
result
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
Object -> IO Object
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Object
result'
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldGetContextBusyWatcherMethodInfo
instance (signature ~ (m GObject.Object.Object), MonadIO m, IsSecretAgentOld a) => O.OverloadedMethod SecretAgentOldGetContextBusyWatcherMethodInfo a signature where
overloadedMethod = secretAgentOldGetContextBusyWatcher
instance O.OverloadedMethodInfo SecretAgentOldGetContextBusyWatcherMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldGetContextBusyWatcher",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldGetContextBusyWatcher"
})
#endif
foreign import ccall "nm_secret_agent_old_get_dbus_connection" nm_secret_agent_old_get_dbus_connection ::
Ptr SecretAgentOld ->
IO (Ptr Gio.DBusConnection.DBusConnection)
secretAgentOldGetDbusConnection ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a
-> m Gio.DBusConnection.DBusConnection
secretAgentOldGetDbusConnection :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a -> m DBusConnection
secretAgentOldGetDbusConnection a
self = IO DBusConnection -> m DBusConnection
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO DBusConnection -> m DBusConnection)
-> IO DBusConnection -> m DBusConnection
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr DBusConnection
result <- Ptr SecretAgentOld -> IO (Ptr DBusConnection)
nm_secret_agent_old_get_dbus_connection Ptr SecretAgentOld
self'
Text -> Ptr DBusConnection -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"secretAgentOldGetDbusConnection" Ptr DBusConnection
result
DBusConnection
result' <- ((ManagedPtr DBusConnection -> DBusConnection)
-> Ptr DBusConnection -> IO DBusConnection
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr DBusConnection -> DBusConnection
Gio.DBusConnection.DBusConnection) Ptr DBusConnection
result
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
DBusConnection -> IO DBusConnection
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return DBusConnection
result'
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldGetDbusConnectionMethodInfo
instance (signature ~ (m Gio.DBusConnection.DBusConnection), MonadIO m, IsSecretAgentOld a) => O.OverloadedMethod SecretAgentOldGetDbusConnectionMethodInfo a signature where
overloadedMethod = secretAgentOldGetDbusConnection
instance O.OverloadedMethodInfo SecretAgentOldGetDbusConnectionMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldGetDbusConnection",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldGetDbusConnection"
})
#endif
foreign import ccall "nm_secret_agent_old_get_dbus_name_owner" nm_secret_agent_old_get_dbus_name_owner ::
Ptr SecretAgentOld ->
IO CString
secretAgentOldGetDbusNameOwner ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a
-> m T.Text
secretAgentOldGetDbusNameOwner :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a -> m Text
secretAgentOldGetDbusNameOwner a
self = IO Text -> m Text
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Text -> m Text) -> IO Text -> m Text
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
CString
result <- Ptr SecretAgentOld -> IO CString
nm_secret_agent_old_get_dbus_name_owner Ptr SecretAgentOld
self'
Text -> CString -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"secretAgentOldGetDbusNameOwner" CString
result
Text
result' <- HasCallStack => CString -> IO Text
CString -> IO Text
cstringToText CString
result
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
Text -> IO Text
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Text
result'
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldGetDbusNameOwnerMethodInfo
instance (signature ~ (m T.Text), MonadIO m, IsSecretAgentOld a) => O.OverloadedMethod SecretAgentOldGetDbusNameOwnerMethodInfo a signature where
overloadedMethod = secretAgentOldGetDbusNameOwner
instance O.OverloadedMethodInfo SecretAgentOldGetDbusNameOwnerMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldGetDbusNameOwner",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldGetDbusNameOwner"
})
#endif
foreign import ccall "nm_secret_agent_old_get_main_context" nm_secret_agent_old_get_main_context ::
Ptr SecretAgentOld ->
IO (Ptr GLib.MainContext.MainContext)
secretAgentOldGetMainContext ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a
-> m GLib.MainContext.MainContext
secretAgentOldGetMainContext :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a -> m MainContext
secretAgentOldGetMainContext a
self = IO MainContext -> m MainContext
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO MainContext -> m MainContext)
-> IO MainContext -> m MainContext
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr MainContext
result <- Ptr SecretAgentOld -> IO (Ptr MainContext)
nm_secret_agent_old_get_main_context Ptr SecretAgentOld
self'
Text -> Ptr MainContext -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"secretAgentOldGetMainContext" Ptr MainContext
result
MainContext
result' <- ((ManagedPtr MainContext -> MainContext)
-> Ptr MainContext -> IO MainContext
forall a.
(HasCallStack, GBoxed a) =>
(ManagedPtr a -> a) -> Ptr a -> IO a
newBoxed ManagedPtr MainContext -> MainContext
GLib.MainContext.MainContext) Ptr MainContext
result
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
MainContext -> IO MainContext
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return MainContext
result'
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldGetMainContextMethodInfo
instance (signature ~ (m GLib.MainContext.MainContext), MonadIO m, IsSecretAgentOld a) => O.OverloadedMethod SecretAgentOldGetMainContextMethodInfo a signature where
overloadedMethod = secretAgentOldGetMainContext
instance O.OverloadedMethodInfo SecretAgentOldGetMainContextMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldGetMainContext",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldGetMainContext"
})
#endif
foreign import ccall "nm_secret_agent_old_get_registered" nm_secret_agent_old_get_registered ::
Ptr SecretAgentOld ->
IO CInt
secretAgentOldGetRegistered ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a
-> m Bool
secretAgentOldGetRegistered :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsSecretAgentOld a) =>
a -> m Bool
secretAgentOldGetRegistered a
self = IO Bool -> m Bool
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Bool -> m Bool) -> IO Bool -> m Bool
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
CInt
result <- Ptr SecretAgentOld -> IO CInt
nm_secret_agent_old_get_registered Ptr SecretAgentOld
self'
let result' :: Bool
result' = (CInt -> CInt -> Bool
forall a. Eq a => a -> a -> Bool
/= CInt
0) CInt
result
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
Bool -> IO Bool
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Bool
result'
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldGetRegisteredMethodInfo
instance (signature ~ (m Bool), MonadIO m, IsSecretAgentOld a) => O.OverloadedMethod SecretAgentOldGetRegisteredMethodInfo a signature where
overloadedMethod = secretAgentOldGetRegistered
instance O.OverloadedMethodInfo SecretAgentOldGetRegisteredMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldGetRegistered",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldGetRegistered"
})
#endif
foreign import ccall "nm_secret_agent_old_get_secrets" nm_secret_agent_old_get_secrets ::
Ptr SecretAgentOld ->
Ptr NM.Connection.Connection ->
CString ->
Ptr CString ->
CUInt ->
FunPtr NM.Callbacks.C_SecretAgentOldGetSecretsFunc ->
Ptr () ->
IO ()
secretAgentOldGetSecrets ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a, NM.Connection.IsConnection b) =>
a
-> b
-> T.Text
-> [T.Text]
-> [NM.Flags.SecretAgentGetSecretsFlags]
-> NM.Callbacks.SecretAgentOldGetSecretsFunc
-> m ()
secretAgentOldGetSecrets :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsSecretAgentOld a, IsConnection b) =>
a
-> b
-> Text
-> [Text]
-> [SecretAgentGetSecretsFlags]
-> SecretAgentOldGetSecretsFunc
-> m ()
secretAgentOldGetSecrets a
self b
connection Text
settingName [Text]
hints [SecretAgentGetSecretsFlags]
flags SecretAgentOldGetSecretsFunc
callback = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr Connection
connection' <- b -> IO (Ptr Connection)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr b
connection
CString
settingName' <- Text -> IO CString
textToCString Text
settingName
Ptr CString
hints' <- [Text] -> IO (Ptr CString)
packZeroTerminatedUTF8CArray [Text]
hints
let flags' :: CUInt
flags' = [SecretAgentGetSecretsFlags] -> CUInt
forall b a. (Num b, IsGFlag a) => [a] -> b
gflagsToWord [SecretAgentGetSecretsFlags]
flags
Ptr (FunPtr C_SecretAgentOldGetSecretsFunc)
ptrcallback <- IO (Ptr (FunPtr C_SecretAgentOldGetSecretsFunc))
forall a. Storable a => IO (Ptr a)
callocMem :: IO (Ptr (FunPtr NM.Callbacks.C_SecretAgentOldGetSecretsFunc))
FunPtr C_SecretAgentOldGetSecretsFunc
callback' <- C_SecretAgentOldGetSecretsFunc
-> IO (FunPtr C_SecretAgentOldGetSecretsFunc)
NM.Callbacks.mk_SecretAgentOldGetSecretsFunc (Maybe (Ptr (FunPtr C_SecretAgentOldGetSecretsFunc))
-> SecretAgentOldGetSecretsFunc_WithClosures
-> C_SecretAgentOldGetSecretsFunc
NM.Callbacks.wrap_SecretAgentOldGetSecretsFunc (Ptr (FunPtr C_SecretAgentOldGetSecretsFunc)
-> Maybe (Ptr (FunPtr C_SecretAgentOldGetSecretsFunc))
forall a. a -> Maybe a
Just Ptr (FunPtr C_SecretAgentOldGetSecretsFunc)
ptrcallback) (SecretAgentOldGetSecretsFunc
-> SecretAgentOldGetSecretsFunc_WithClosures
NM.Callbacks.drop_closures_SecretAgentOldGetSecretsFunc SecretAgentOldGetSecretsFunc
callback))
Ptr (FunPtr C_SecretAgentOldGetSecretsFunc)
-> FunPtr C_SecretAgentOldGetSecretsFunc -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke Ptr (FunPtr C_SecretAgentOldGetSecretsFunc)
ptrcallback FunPtr C_SecretAgentOldGetSecretsFunc
callback'
let userData :: Ptr a
userData = Ptr a
forall a. Ptr a
nullPtr
Ptr SecretAgentOld
-> Ptr Connection
-> CString
-> Ptr CString
-> CUInt
-> FunPtr C_SecretAgentOldGetSecretsFunc
-> Ptr ()
-> IO ()
nm_secret_agent_old_get_secrets Ptr SecretAgentOld
self' Ptr Connection
connection' CString
settingName' Ptr CString
hints' CUInt
flags' FunPtr C_SecretAgentOldGetSecretsFunc
callback' Ptr ()
forall a. Ptr a
userData
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
b -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr b
connection
CString -> IO ()
forall a. Ptr a -> IO ()
freeMem CString
settingName'
(CString -> IO ()) -> Ptr CString -> IO ()
forall a b. (Ptr a -> IO b) -> Ptr (Ptr a) -> IO ()
mapZeroTerminatedCArray CString -> IO ()
forall a. Ptr a -> IO ()
freeMem Ptr CString
hints'
Ptr CString -> IO ()
forall a. Ptr a -> IO ()
freeMem Ptr CString
hints'
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldGetSecretsMethodInfo
instance (signature ~ (b -> T.Text -> [T.Text] -> [NM.Flags.SecretAgentGetSecretsFlags] -> NM.Callbacks.SecretAgentOldGetSecretsFunc -> m ()), MonadIO m, IsSecretAgentOld a, NM.Connection.IsConnection b) => O.OverloadedMethod SecretAgentOldGetSecretsMethodInfo a signature where
overloadedMethod = secretAgentOldGetSecrets
instance O.OverloadedMethodInfo SecretAgentOldGetSecretsMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldGetSecrets",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldGetSecrets"
})
#endif
foreign import ccall "nm_secret_agent_old_register" nm_secret_agent_old_register ::
Ptr SecretAgentOld ->
Ptr Gio.Cancellable.Cancellable ->
Ptr (Ptr GError) ->
IO CInt
{-# DEPRECATED secretAgentOldRegister ["(Since version 1.24)","Use 'GI.NM.Objects.SecretAgentOld.secretAgentOldEnable' or 'GI.NM.Objects.SecretAgentOld.secretAgentOldRegisterAsync'."] #-}
secretAgentOldRegister ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a, Gio.Cancellable.IsCancellable b) =>
a
-> Maybe (b)
-> m ()
secretAgentOldRegister :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsSecretAgentOld a, IsCancellable b) =>
a -> Maybe b -> m ()
secretAgentOldRegister a
self Maybe b
cancellable = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr Cancellable
maybeCancellable <- case Maybe b
cancellable of
Maybe b
Nothing -> Ptr Cancellable -> IO (Ptr Cancellable)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
forall a. Ptr a
FP.nullPtr
Just b
jCancellable -> do
Ptr Cancellable
jCancellable' <- b -> IO (Ptr Cancellable)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr b
jCancellable
Ptr Cancellable -> IO (Ptr Cancellable)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
jCancellable'
IO () -> IO () -> IO ()
forall a b. IO a -> IO b -> IO a
onException (do
CInt
_ <- (Ptr (Ptr GError) -> IO CInt) -> IO CInt
forall a. (Ptr (Ptr GError) -> IO a) -> IO a
propagateGError ((Ptr (Ptr GError) -> IO CInt) -> IO CInt)
-> (Ptr (Ptr GError) -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ Ptr SecretAgentOld
-> Ptr Cancellable -> Ptr (Ptr GError) -> IO CInt
nm_secret_agent_old_register Ptr SecretAgentOld
self' Ptr Cancellable
maybeCancellable
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
Maybe b -> (b -> IO ()) -> IO ()
forall (m :: * -> *) a. Monad m => Maybe a -> (a -> m ()) -> m ()
whenJust Maybe b
cancellable b -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
) (do
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
)
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldRegisterMethodInfo
instance (signature ~ (Maybe (b) -> m ()), MonadIO m, IsSecretAgentOld a, Gio.Cancellable.IsCancellable b) => O.OverloadedMethod SecretAgentOldRegisterMethodInfo a signature where
overloadedMethod = secretAgentOldRegister
instance O.OverloadedMethodInfo SecretAgentOldRegisterMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldRegister",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldRegister"
})
#endif
foreign import ccall "nm_secret_agent_old_register_async" nm_secret_agent_old_register_async ::
Ptr SecretAgentOld ->
Ptr Gio.Cancellable.Cancellable ->
FunPtr Gio.Callbacks.C_AsyncReadyCallback ->
Ptr () ->
IO ()
secretAgentOldRegisterAsync ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a, Gio.Cancellable.IsCancellable b) =>
a
-> Maybe (b)
-> Maybe (Gio.Callbacks.AsyncReadyCallback)
-> m ()
secretAgentOldRegisterAsync :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsSecretAgentOld a, IsCancellable b) =>
a -> Maybe b -> Maybe AsyncReadyCallback -> m ()
secretAgentOldRegisterAsync a
self Maybe b
cancellable Maybe AsyncReadyCallback
callback = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr Cancellable
maybeCancellable <- case Maybe b
cancellable of
Maybe b
Nothing -> Ptr Cancellable -> IO (Ptr Cancellable)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
forall a. Ptr a
FP.nullPtr
Just b
jCancellable -> do
Ptr Cancellable
jCancellable' <- b -> IO (Ptr Cancellable)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr b
jCancellable
Ptr Cancellable -> IO (Ptr Cancellable)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
jCancellable'
FunPtr C_AsyncReadyCallback
maybeCallback <- case Maybe AsyncReadyCallback
callback of
Maybe AsyncReadyCallback
Nothing -> FunPtr C_AsyncReadyCallback -> IO (FunPtr C_AsyncReadyCallback)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return FunPtr C_AsyncReadyCallback
forall a. FunPtr a
FP.nullFunPtr
Just AsyncReadyCallback
jCallback -> do
Ptr (FunPtr C_AsyncReadyCallback)
ptrcallback <- IO (Ptr (FunPtr C_AsyncReadyCallback))
forall a. Storable a => IO (Ptr a)
callocMem :: IO (Ptr (FunPtr Gio.Callbacks.C_AsyncReadyCallback))
FunPtr C_AsyncReadyCallback
jCallback' <- C_AsyncReadyCallback -> IO (FunPtr C_AsyncReadyCallback)
Gio.Callbacks.mk_AsyncReadyCallback (Maybe (Ptr (FunPtr C_AsyncReadyCallback))
-> AsyncReadyCallback_WithClosures -> C_AsyncReadyCallback
Gio.Callbacks.wrap_AsyncReadyCallback (Ptr (FunPtr C_AsyncReadyCallback)
-> Maybe (Ptr (FunPtr C_AsyncReadyCallback))
forall a. a -> Maybe a
Just Ptr (FunPtr C_AsyncReadyCallback)
ptrcallback) (AsyncReadyCallback -> AsyncReadyCallback_WithClosures
Gio.Callbacks.drop_closures_AsyncReadyCallback AsyncReadyCallback
jCallback))
Ptr (FunPtr C_AsyncReadyCallback)
-> FunPtr C_AsyncReadyCallback -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke Ptr (FunPtr C_AsyncReadyCallback)
ptrcallback FunPtr C_AsyncReadyCallback
jCallback'
FunPtr C_AsyncReadyCallback -> IO (FunPtr C_AsyncReadyCallback)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return FunPtr C_AsyncReadyCallback
jCallback'
let userData :: Ptr a
userData = Ptr a
forall a. Ptr a
nullPtr
Ptr SecretAgentOld
-> Ptr Cancellable
-> FunPtr C_AsyncReadyCallback
-> Ptr ()
-> IO ()
nm_secret_agent_old_register_async Ptr SecretAgentOld
self' Ptr Cancellable
maybeCancellable FunPtr C_AsyncReadyCallback
maybeCallback Ptr ()
forall a. Ptr a
userData
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
Maybe b -> (b -> IO ()) -> IO ()
forall (m :: * -> *) a. Monad m => Maybe a -> (a -> m ()) -> m ()
whenJust Maybe b
cancellable b -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldRegisterAsyncMethodInfo
instance (signature ~ (Maybe (b) -> Maybe (Gio.Callbacks.AsyncReadyCallback) -> m ()), MonadIO m, IsSecretAgentOld a, Gio.Cancellable.IsCancellable b) => O.OverloadedMethod SecretAgentOldRegisterAsyncMethodInfo a signature where
overloadedMethod = secretAgentOldRegisterAsync
instance O.OverloadedMethodInfo SecretAgentOldRegisterAsyncMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldRegisterAsync",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldRegisterAsync"
})
#endif
foreign import ccall "nm_secret_agent_old_register_finish" nm_secret_agent_old_register_finish ::
Ptr SecretAgentOld ->
Ptr Gio.AsyncResult.AsyncResult ->
Ptr (Ptr GError) ->
IO CInt
secretAgentOldRegisterFinish ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a, Gio.AsyncResult.IsAsyncResult b) =>
a
-> b
-> m ()
secretAgentOldRegisterFinish :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsSecretAgentOld a, IsAsyncResult b) =>
a -> b -> m ()
secretAgentOldRegisterFinish a
self b
result_ = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr AsyncResult
result_' <- b -> IO (Ptr AsyncResult)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr b
result_
IO () -> IO () -> IO ()
forall a b. IO a -> IO b -> IO a
onException (do
CInt
_ <- (Ptr (Ptr GError) -> IO CInt) -> IO CInt
forall a. (Ptr (Ptr GError) -> IO a) -> IO a
propagateGError ((Ptr (Ptr GError) -> IO CInt) -> IO CInt)
-> (Ptr (Ptr GError) -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ Ptr SecretAgentOld
-> Ptr AsyncResult -> Ptr (Ptr GError) -> IO CInt
nm_secret_agent_old_register_finish Ptr SecretAgentOld
self' Ptr AsyncResult
result_'
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
b -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr b
result_
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
) (do
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
)
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldRegisterFinishMethodInfo
instance (signature ~ (b -> m ()), MonadIO m, IsSecretAgentOld a, Gio.AsyncResult.IsAsyncResult b) => O.OverloadedMethod SecretAgentOldRegisterFinishMethodInfo a signature where
overloadedMethod = secretAgentOldRegisterFinish
instance O.OverloadedMethodInfo SecretAgentOldRegisterFinishMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldRegisterFinish",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldRegisterFinish"
})
#endif
foreign import ccall "nm_secret_agent_old_save_secrets" nm_secret_agent_old_save_secrets ::
Ptr SecretAgentOld ->
Ptr NM.Connection.Connection ->
FunPtr NM.Callbacks.C_SecretAgentOldSaveSecretsFunc ->
Ptr () ->
IO ()
secretAgentOldSaveSecrets ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a, NM.Connection.IsConnection b) =>
a
-> b
-> NM.Callbacks.SecretAgentOldSaveSecretsFunc
-> m ()
secretAgentOldSaveSecrets :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsSecretAgentOld a, IsConnection b) =>
a -> b -> SecretAgentOldDeleteSecretsFunc -> m ()
secretAgentOldSaveSecrets a
self b
connection SecretAgentOldDeleteSecretsFunc
callback = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr Connection
connection' <- b -> IO (Ptr Connection)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr b
connection
Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc)
ptrcallback <- IO (Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc))
forall a. Storable a => IO (Ptr a)
callocMem :: IO (Ptr (FunPtr NM.Callbacks.C_SecretAgentOldSaveSecretsFunc))
FunPtr C_SecretAgentOldDeleteSecretsFunc
callback' <- C_SecretAgentOldDeleteSecretsFunc
-> IO (FunPtr C_SecretAgentOldDeleteSecretsFunc)
NM.Callbacks.mk_SecretAgentOldSaveSecretsFunc (Maybe (Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc))
-> SecretAgentOldDeleteSecretsFunc_WithClosures
-> C_SecretAgentOldDeleteSecretsFunc
NM.Callbacks.wrap_SecretAgentOldSaveSecretsFunc (Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc)
-> Maybe (Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc))
forall a. a -> Maybe a
Just Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc)
ptrcallback) (SecretAgentOldDeleteSecretsFunc
-> SecretAgentOldDeleteSecretsFunc_WithClosures
NM.Callbacks.drop_closures_SecretAgentOldSaveSecretsFunc SecretAgentOldDeleteSecretsFunc
callback))
Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc)
-> FunPtr C_SecretAgentOldDeleteSecretsFunc -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke Ptr (FunPtr C_SecretAgentOldDeleteSecretsFunc)
ptrcallback FunPtr C_SecretAgentOldDeleteSecretsFunc
callback'
let userData :: Ptr a
userData = Ptr a
forall a. Ptr a
nullPtr
Ptr SecretAgentOld
-> Ptr Connection
-> FunPtr C_SecretAgentOldDeleteSecretsFunc
-> Ptr ()
-> IO ()
nm_secret_agent_old_save_secrets Ptr SecretAgentOld
self' Ptr Connection
connection' FunPtr C_SecretAgentOldDeleteSecretsFunc
callback' Ptr ()
forall a. Ptr a
userData
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
b -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr b
connection
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldSaveSecretsMethodInfo
instance (signature ~ (b -> NM.Callbacks.SecretAgentOldSaveSecretsFunc -> m ()), MonadIO m, IsSecretAgentOld a, NM.Connection.IsConnection b) => O.OverloadedMethod SecretAgentOldSaveSecretsMethodInfo a signature where
overloadedMethod = secretAgentOldSaveSecrets
instance O.OverloadedMethodInfo SecretAgentOldSaveSecretsMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldSaveSecrets",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldSaveSecrets"
})
#endif
foreign import ccall "nm_secret_agent_old_unregister" nm_secret_agent_old_unregister ::
Ptr SecretAgentOld ->
Ptr Gio.Cancellable.Cancellable ->
Ptr (Ptr GError) ->
IO CInt
{-# DEPRECATED secretAgentOldUnregister ["(Since version 1.24)","Use 'GI.NM.Objects.SecretAgentOld.secretAgentOldEnable'."] #-}
secretAgentOldUnregister ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a, Gio.Cancellable.IsCancellable b) =>
a
-> Maybe (b)
-> m ()
secretAgentOldUnregister :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsSecretAgentOld a, IsCancellable b) =>
a -> Maybe b -> m ()
secretAgentOldUnregister a
self Maybe b
cancellable = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr Cancellable
maybeCancellable <- case Maybe b
cancellable of
Maybe b
Nothing -> Ptr Cancellable -> IO (Ptr Cancellable)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
forall a. Ptr a
FP.nullPtr
Just b
jCancellable -> do
Ptr Cancellable
jCancellable' <- b -> IO (Ptr Cancellable)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr b
jCancellable
Ptr Cancellable -> IO (Ptr Cancellable)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
jCancellable'
IO () -> IO () -> IO ()
forall a b. IO a -> IO b -> IO a
onException (do
CInt
_ <- (Ptr (Ptr GError) -> IO CInt) -> IO CInt
forall a. (Ptr (Ptr GError) -> IO a) -> IO a
propagateGError ((Ptr (Ptr GError) -> IO CInt) -> IO CInt)
-> (Ptr (Ptr GError) -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ Ptr SecretAgentOld
-> Ptr Cancellable -> Ptr (Ptr GError) -> IO CInt
nm_secret_agent_old_unregister Ptr SecretAgentOld
self' Ptr Cancellable
maybeCancellable
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
Maybe b -> (b -> IO ()) -> IO ()
forall (m :: * -> *) a. Monad m => Maybe a -> (a -> m ()) -> m ()
whenJust Maybe b
cancellable b -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
) (do
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
)
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldUnregisterMethodInfo
instance (signature ~ (Maybe (b) -> m ()), MonadIO m, IsSecretAgentOld a, Gio.Cancellable.IsCancellable b) => O.OverloadedMethod SecretAgentOldUnregisterMethodInfo a signature where
overloadedMethod = secretAgentOldUnregister
instance O.OverloadedMethodInfo SecretAgentOldUnregisterMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldUnregister",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldUnregister"
})
#endif
foreign import ccall "nm_secret_agent_old_unregister_async" nm_secret_agent_old_unregister_async ::
Ptr SecretAgentOld ->
Ptr Gio.Cancellable.Cancellable ->
FunPtr Gio.Callbacks.C_AsyncReadyCallback ->
Ptr () ->
IO ()
{-# DEPRECATED secretAgentOldUnregisterAsync ["(Since version 1.24)","Use 'GI.NM.Objects.SecretAgentOld.secretAgentOldEnable'."] #-}
secretAgentOldUnregisterAsync ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a, Gio.Cancellable.IsCancellable b) =>
a
-> Maybe (b)
-> Maybe (Gio.Callbacks.AsyncReadyCallback)
-> m ()
secretAgentOldUnregisterAsync :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsSecretAgentOld a, IsCancellable b) =>
a -> Maybe b -> Maybe AsyncReadyCallback -> m ()
secretAgentOldUnregisterAsync a
self Maybe b
cancellable Maybe AsyncReadyCallback
callback = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr Cancellable
maybeCancellable <- case Maybe b
cancellable of
Maybe b
Nothing -> Ptr Cancellable -> IO (Ptr Cancellable)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
forall a. Ptr a
FP.nullPtr
Just b
jCancellable -> do
Ptr Cancellable
jCancellable' <- b -> IO (Ptr Cancellable)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr b
jCancellable
Ptr Cancellable -> IO (Ptr Cancellable)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
jCancellable'
FunPtr C_AsyncReadyCallback
maybeCallback <- case Maybe AsyncReadyCallback
callback of
Maybe AsyncReadyCallback
Nothing -> FunPtr C_AsyncReadyCallback -> IO (FunPtr C_AsyncReadyCallback)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return FunPtr C_AsyncReadyCallback
forall a. FunPtr a
FP.nullFunPtr
Just AsyncReadyCallback
jCallback -> do
Ptr (FunPtr C_AsyncReadyCallback)
ptrcallback <- IO (Ptr (FunPtr C_AsyncReadyCallback))
forall a. Storable a => IO (Ptr a)
callocMem :: IO (Ptr (FunPtr Gio.Callbacks.C_AsyncReadyCallback))
FunPtr C_AsyncReadyCallback
jCallback' <- C_AsyncReadyCallback -> IO (FunPtr C_AsyncReadyCallback)
Gio.Callbacks.mk_AsyncReadyCallback (Maybe (Ptr (FunPtr C_AsyncReadyCallback))
-> AsyncReadyCallback_WithClosures -> C_AsyncReadyCallback
Gio.Callbacks.wrap_AsyncReadyCallback (Ptr (FunPtr C_AsyncReadyCallback)
-> Maybe (Ptr (FunPtr C_AsyncReadyCallback))
forall a. a -> Maybe a
Just Ptr (FunPtr C_AsyncReadyCallback)
ptrcallback) (AsyncReadyCallback -> AsyncReadyCallback_WithClosures
Gio.Callbacks.drop_closures_AsyncReadyCallback AsyncReadyCallback
jCallback))
Ptr (FunPtr C_AsyncReadyCallback)
-> FunPtr C_AsyncReadyCallback -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke Ptr (FunPtr C_AsyncReadyCallback)
ptrcallback FunPtr C_AsyncReadyCallback
jCallback'
FunPtr C_AsyncReadyCallback -> IO (FunPtr C_AsyncReadyCallback)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return FunPtr C_AsyncReadyCallback
jCallback'
let userData :: Ptr a
userData = Ptr a
forall a. Ptr a
nullPtr
Ptr SecretAgentOld
-> Ptr Cancellable
-> FunPtr C_AsyncReadyCallback
-> Ptr ()
-> IO ()
nm_secret_agent_old_unregister_async Ptr SecretAgentOld
self' Ptr Cancellable
maybeCancellable FunPtr C_AsyncReadyCallback
maybeCallback Ptr ()
forall a. Ptr a
userData
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
Maybe b -> (b -> IO ()) -> IO ()
forall (m :: * -> *) a. Monad m => Maybe a -> (a -> m ()) -> m ()
whenJust Maybe b
cancellable b -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldUnregisterAsyncMethodInfo
instance (signature ~ (Maybe (b) -> Maybe (Gio.Callbacks.AsyncReadyCallback) -> m ()), MonadIO m, IsSecretAgentOld a, Gio.Cancellable.IsCancellable b) => O.OverloadedMethod SecretAgentOldUnregisterAsyncMethodInfo a signature where
overloadedMethod = secretAgentOldUnregisterAsync
instance O.OverloadedMethodInfo SecretAgentOldUnregisterAsyncMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldUnregisterAsync",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldUnregisterAsync"
})
#endif
foreign import ccall "nm_secret_agent_old_unregister_finish" nm_secret_agent_old_unregister_finish ::
Ptr SecretAgentOld ->
Ptr Gio.AsyncResult.AsyncResult ->
Ptr (Ptr GError) ->
IO CInt
{-# DEPRECATED secretAgentOldUnregisterFinish ["(Since version 1.24)","Use 'GI.NM.Objects.SecretAgentOld.secretAgentOldEnable'."] #-}
secretAgentOldUnregisterFinish ::
(B.CallStack.HasCallStack, MonadIO m, IsSecretAgentOld a, Gio.AsyncResult.IsAsyncResult b) =>
a
-> b
-> m ()
secretAgentOldUnregisterFinish :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsSecretAgentOld a, IsAsyncResult b) =>
a -> b -> m ()
secretAgentOldUnregisterFinish a
self b
result_ = IO () -> m ()
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr SecretAgentOld
self' <- a -> IO (Ptr SecretAgentOld)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr AsyncResult
result_' <- b -> IO (Ptr AsyncResult)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr b
result_
IO () -> IO () -> IO ()
forall a b. IO a -> IO b -> IO a
onException (do
CInt
_ <- (Ptr (Ptr GError) -> IO CInt) -> IO CInt
forall a. (Ptr (Ptr GError) -> IO a) -> IO a
propagateGError ((Ptr (Ptr GError) -> IO CInt) -> IO CInt)
-> (Ptr (Ptr GError) -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ Ptr SecretAgentOld
-> Ptr AsyncResult -> Ptr (Ptr GError) -> IO CInt
nm_secret_agent_old_unregister_finish Ptr SecretAgentOld
self' Ptr AsyncResult
result_'
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
b -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr b
result_
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
) (do
() -> IO ()
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return ()
)
#if defined(ENABLE_OVERLOADING)
data SecretAgentOldUnregisterFinishMethodInfo
instance (signature ~ (b -> m ()), MonadIO m, IsSecretAgentOld a, Gio.AsyncResult.IsAsyncResult b) => O.OverloadedMethod SecretAgentOldUnregisterFinishMethodInfo a signature where
overloadedMethod = secretAgentOldUnregisterFinish
instance O.OverloadedMethodInfo SecretAgentOldUnregisterFinishMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.NM.Objects.SecretAgentOld.secretAgentOldUnregisterFinish",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-nm-1.0.1/docs/GI-NM-Objects-SecretAgentOld.html#v:secretAgentOldUnregisterFinish"
})
#endif