{-# LANGUAGE TypeApplications #-}
#if (MIN_VERSION_haskell_gi_overloading(1,0,0) && !defined(__HADDOCK_VERSION__))
#define ENABLE_OVERLOADING
#endif
module GI.OSTree.Objects.RepoFile
(
#if defined(ENABLE_OVERLOADING)
RepoFileTreeFindChildMethodInfo ,
#endif
RepoFile(..) ,
IsRepoFile ,
toRepoFile ,
#if defined(ENABLE_OVERLOADING)
ResolveRepoFileMethod ,
#endif
#if defined(ENABLE_OVERLOADING)
RepoFileEnsureResolvedMethodInfo ,
#endif
repoFileEnsureResolved ,
#if defined(ENABLE_OVERLOADING)
RepoFileGetChecksumMethodInfo ,
#endif
repoFileGetChecksum ,
#if defined(ENABLE_OVERLOADING)
RepoFileGetRepoMethodInfo ,
#endif
repoFileGetRepo ,
#if defined(ENABLE_OVERLOADING)
RepoFileGetRootMethodInfo ,
#endif
repoFileGetRoot ,
#if defined(ENABLE_OVERLOADING)
RepoFileGetXattrsMethodInfo ,
#endif
repoFileGetXattrs ,
#if defined(ENABLE_OVERLOADING)
RepoFileTreeGetContentsMethodInfo ,
#endif
repoFileTreeGetContents ,
#if defined(ENABLE_OVERLOADING)
RepoFileTreeGetContentsChecksumMethodInfo,
#endif
repoFileTreeGetContentsChecksum ,
#if defined(ENABLE_OVERLOADING)
RepoFileTreeGetMetadataMethodInfo ,
#endif
repoFileTreeGetMetadata ,
#if defined(ENABLE_OVERLOADING)
RepoFileTreeGetMetadataChecksumMethodInfo,
#endif
repoFileTreeGetMetadataChecksum ,
#if defined(ENABLE_OVERLOADING)
RepoFileTreeQueryChildMethodInfo ,
#endif
repoFileTreeQueryChild ,
#if defined(ENABLE_OVERLOADING)
RepoFileTreeSetMetadataMethodInfo ,
#endif
repoFileTreeSetMetadata ,
) 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.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.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 GI.GObject.Objects.Object as GObject.Object
import qualified GI.Gio.Flags as Gio.Flags
import qualified GI.Gio.Interfaces.File as Gio.File
import qualified GI.Gio.Objects.Cancellable as Gio.Cancellable
import qualified GI.Gio.Objects.FileInfo as Gio.FileInfo
import {-# SOURCE #-} qualified GI.OSTree.Objects.Repo as OSTree.Repo
newtype RepoFile = RepoFile (SP.ManagedPtr RepoFile)
deriving (RepoFile -> RepoFile -> Bool
(RepoFile -> RepoFile -> Bool)
-> (RepoFile -> RepoFile -> Bool) -> Eq RepoFile
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: RepoFile -> RepoFile -> Bool
$c/= :: RepoFile -> RepoFile -> Bool
== :: RepoFile -> RepoFile -> Bool
$c== :: RepoFile -> RepoFile -> Bool
Eq)
instance SP.ManagedPtrNewtype RepoFile where
toManagedPtr :: RepoFile -> ManagedPtr RepoFile
toManagedPtr (RepoFile ManagedPtr RepoFile
p) = ManagedPtr RepoFile
p
foreign import ccall "ostree_repo_file_get_type"
c_ostree_repo_file_get_type :: IO B.Types.GType
instance B.Types.TypedObject RepoFile where
glibType :: IO GType
glibType = IO GType
c_ostree_repo_file_get_type
instance B.Types.GObject RepoFile
class (SP.GObject o, O.IsDescendantOf RepoFile o) => IsRepoFile o
instance (SP.GObject o, O.IsDescendantOf RepoFile o) => IsRepoFile o
instance O.HasParentTypes RepoFile
type instance O.ParentTypes RepoFile = '[GObject.Object.Object, Gio.File.File]
toRepoFile :: (MIO.MonadIO m, IsRepoFile o) => o -> m RepoFile
toRepoFile :: forall (m :: * -> *) o.
(MonadIO m, IsRepoFile o) =>
o -> m RepoFile
toRepoFile = IO RepoFile -> m RepoFile
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO RepoFile -> m RepoFile)
-> (o -> IO RepoFile) -> o -> m RepoFile
forall b c a. (b -> c) -> (a -> b) -> a -> c
. (ManagedPtr RepoFile -> RepoFile) -> o -> IO RepoFile
forall o o'.
(HasCallStack, ManagedPtrNewtype o, TypedObject o,
ManagedPtrNewtype o', TypedObject o') =>
(ManagedPtr o' -> o') -> o -> IO o'
B.ManagedPtr.unsafeCastTo ManagedPtr RepoFile -> RepoFile
RepoFile
instance B.GValue.IsGValue (Maybe RepoFile) where
gvalueGType_ :: IO GType
gvalueGType_ = IO GType
c_ostree_repo_file_get_type
gvalueSet_ :: Ptr GValue -> Maybe RepoFile -> IO ()
gvalueSet_ Ptr GValue
gv Maybe RepoFile
P.Nothing = Ptr GValue -> Ptr RepoFile -> IO ()
forall a. GObject a => Ptr GValue -> Ptr a -> IO ()
B.GValue.set_object Ptr GValue
gv (Ptr RepoFile
forall a. Ptr a
FP.nullPtr :: FP.Ptr RepoFile)
gvalueSet_ Ptr GValue
gv (P.Just RepoFile
obj) = RepoFile -> (Ptr RepoFile -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
B.ManagedPtr.withManagedPtr RepoFile
obj (Ptr GValue -> Ptr RepoFile -> IO ()
forall a. GObject a => Ptr GValue -> Ptr a -> IO ()
B.GValue.set_object Ptr GValue
gv)
gvalueGet_ :: Ptr GValue -> IO (Maybe RepoFile)
gvalueGet_ Ptr GValue
gv = do
Ptr RepoFile
ptr <- Ptr GValue -> IO (Ptr RepoFile)
forall a. GObject a => Ptr GValue -> IO (Ptr a)
B.GValue.get_object Ptr GValue
gv :: IO (FP.Ptr RepoFile)
if Ptr RepoFile
ptr Ptr RepoFile -> Ptr RepoFile -> Bool
forall a. Eq a => a -> a -> Bool
/= Ptr RepoFile
forall a. Ptr a
FP.nullPtr
then RepoFile -> Maybe RepoFile
forall a. a -> Maybe a
P.Just (RepoFile -> Maybe RepoFile) -> IO RepoFile -> IO (Maybe RepoFile)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> (ManagedPtr RepoFile -> RepoFile) -> Ptr RepoFile -> IO RepoFile
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
B.ManagedPtr.newObject ManagedPtr RepoFile -> RepoFile
RepoFile Ptr RepoFile
ptr
else Maybe RepoFile -> IO (Maybe RepoFile)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe RepoFile
forall a. Maybe a
P.Nothing
#if defined(ENABLE_OVERLOADING)
type family ResolveRepoFileMethod (t :: Symbol) (o :: *) :: * where
ResolveRepoFileMethod "appendTo" o = Gio.File.FileAppendToMethodInfo
ResolveRepoFileMethod "appendToAsync" o = Gio.File.FileAppendToAsyncMethodInfo
ResolveRepoFileMethod "appendToFinish" o = Gio.File.FileAppendToFinishMethodInfo
ResolveRepoFileMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo
ResolveRepoFileMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo
ResolveRepoFileMethod "buildAttributeListForCopy" o = Gio.File.FileBuildAttributeListForCopyMethodInfo
ResolveRepoFileMethod "copy" o = Gio.File.FileCopyMethodInfo
ResolveRepoFileMethod "copyAsync" o = Gio.File.FileCopyAsyncMethodInfo
ResolveRepoFileMethod "copyAttributes" o = Gio.File.FileCopyAttributesMethodInfo
ResolveRepoFileMethod "copyFinish" o = Gio.File.FileCopyFinishMethodInfo
ResolveRepoFileMethod "create" o = Gio.File.FileCreateMethodInfo
ResolveRepoFileMethod "createAsync" o = Gio.File.FileCreateAsyncMethodInfo
ResolveRepoFileMethod "createFinish" o = Gio.File.FileCreateFinishMethodInfo
ResolveRepoFileMethod "createReadwrite" o = Gio.File.FileCreateReadwriteMethodInfo
ResolveRepoFileMethod "createReadwriteAsync" o = Gio.File.FileCreateReadwriteAsyncMethodInfo
ResolveRepoFileMethod "createReadwriteFinish" o = Gio.File.FileCreateReadwriteFinishMethodInfo
ResolveRepoFileMethod "delete" o = Gio.File.FileDeleteMethodInfo
ResolveRepoFileMethod "deleteAsync" o = Gio.File.FileDeleteAsyncMethodInfo
ResolveRepoFileMethod "deleteFinish" o = Gio.File.FileDeleteFinishMethodInfo
ResolveRepoFileMethod "dup" o = Gio.File.FileDupMethodInfo
ResolveRepoFileMethod "ejectMountable" o = Gio.File.FileEjectMountableMethodInfo
ResolveRepoFileMethod "ejectMountableFinish" o = Gio.File.FileEjectMountableFinishMethodInfo
ResolveRepoFileMethod "ejectMountableWithOperation" o = Gio.File.FileEjectMountableWithOperationMethodInfo
ResolveRepoFileMethod "ejectMountableWithOperationFinish" o = Gio.File.FileEjectMountableWithOperationFinishMethodInfo
ResolveRepoFileMethod "ensureResolved" o = RepoFileEnsureResolvedMethodInfo
ResolveRepoFileMethod "enumerateChildren" o = Gio.File.FileEnumerateChildrenMethodInfo
ResolveRepoFileMethod "enumerateChildrenAsync" o = Gio.File.FileEnumerateChildrenAsyncMethodInfo
ResolveRepoFileMethod "enumerateChildrenFinish" o = Gio.File.FileEnumerateChildrenFinishMethodInfo
ResolveRepoFileMethod "equal" o = Gio.File.FileEqualMethodInfo
ResolveRepoFileMethod "findEnclosingMount" o = Gio.File.FileFindEnclosingMountMethodInfo
ResolveRepoFileMethod "findEnclosingMountAsync" o = Gio.File.FileFindEnclosingMountAsyncMethodInfo
ResolveRepoFileMethod "findEnclosingMountFinish" o = Gio.File.FileFindEnclosingMountFinishMethodInfo
ResolveRepoFileMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo
ResolveRepoFileMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo
ResolveRepoFileMethod "getv" o = GObject.Object.ObjectGetvMethodInfo
ResolveRepoFileMethod "hasParent" o = Gio.File.FileHasParentMethodInfo
ResolveRepoFileMethod "hasPrefix" o = Gio.File.FileHasPrefixMethodInfo
ResolveRepoFileMethod "hasUriScheme" o = Gio.File.FileHasUriSchemeMethodInfo
ResolveRepoFileMethod "hash" o = Gio.File.FileHashMethodInfo
ResolveRepoFileMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo
ResolveRepoFileMethod "isNative" o = Gio.File.FileIsNativeMethodInfo
ResolveRepoFileMethod "loadBytes" o = Gio.File.FileLoadBytesMethodInfo
ResolveRepoFileMethod "loadBytesAsync" o = Gio.File.FileLoadBytesAsyncMethodInfo
ResolveRepoFileMethod "loadBytesFinish" o = Gio.File.FileLoadBytesFinishMethodInfo
ResolveRepoFileMethod "loadContents" o = Gio.File.FileLoadContentsMethodInfo
ResolveRepoFileMethod "loadContentsAsync" o = Gio.File.FileLoadContentsAsyncMethodInfo
ResolveRepoFileMethod "loadContentsFinish" o = Gio.File.FileLoadContentsFinishMethodInfo
ResolveRepoFileMethod "loadPartialContentsFinish" o = Gio.File.FileLoadPartialContentsFinishMethodInfo
ResolveRepoFileMethod "makeDirectory" o = Gio.File.FileMakeDirectoryMethodInfo
ResolveRepoFileMethod "makeDirectoryAsync" o = Gio.File.FileMakeDirectoryAsyncMethodInfo
ResolveRepoFileMethod "makeDirectoryFinish" o = Gio.File.FileMakeDirectoryFinishMethodInfo
ResolveRepoFileMethod "makeDirectoryWithParents" o = Gio.File.FileMakeDirectoryWithParentsMethodInfo
ResolveRepoFileMethod "makeSymbolicLink" o = Gio.File.FileMakeSymbolicLinkMethodInfo
ResolveRepoFileMethod "measureDiskUsageFinish" o = Gio.File.FileMeasureDiskUsageFinishMethodInfo
ResolveRepoFileMethod "monitor" o = Gio.File.FileMonitorMethodInfo
ResolveRepoFileMethod "monitorDirectory" o = Gio.File.FileMonitorDirectoryMethodInfo
ResolveRepoFileMethod "monitorFile" o = Gio.File.FileMonitorFileMethodInfo
ResolveRepoFileMethod "mountEnclosingVolume" o = Gio.File.FileMountEnclosingVolumeMethodInfo
ResolveRepoFileMethod "mountEnclosingVolumeFinish" o = Gio.File.FileMountEnclosingVolumeFinishMethodInfo
ResolveRepoFileMethod "mountMountable" o = Gio.File.FileMountMountableMethodInfo
ResolveRepoFileMethod "mountMountableFinish" o = Gio.File.FileMountMountableFinishMethodInfo
ResolveRepoFileMethod "move" o = Gio.File.FileMoveMethodInfo
ResolveRepoFileMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo
ResolveRepoFileMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo
ResolveRepoFileMethod "openReadwrite" o = Gio.File.FileOpenReadwriteMethodInfo
ResolveRepoFileMethod "openReadwriteAsync" o = Gio.File.FileOpenReadwriteAsyncMethodInfo
ResolveRepoFileMethod "openReadwriteFinish" o = Gio.File.FileOpenReadwriteFinishMethodInfo
ResolveRepoFileMethod "peekPath" o = Gio.File.FilePeekPathMethodInfo
ResolveRepoFileMethod "pollMountable" o = Gio.File.FilePollMountableMethodInfo
ResolveRepoFileMethod "pollMountableFinish" o = Gio.File.FilePollMountableFinishMethodInfo
ResolveRepoFileMethod "queryDefaultHandler" o = Gio.File.FileQueryDefaultHandlerMethodInfo
ResolveRepoFileMethod "queryDefaultHandlerAsync" o = Gio.File.FileQueryDefaultHandlerAsyncMethodInfo
ResolveRepoFileMethod "queryDefaultHandlerFinish" o = Gio.File.FileQueryDefaultHandlerFinishMethodInfo
ResolveRepoFileMethod "queryExists" o = Gio.File.FileQueryExistsMethodInfo
ResolveRepoFileMethod "queryFileType" o = Gio.File.FileQueryFileTypeMethodInfo
ResolveRepoFileMethod "queryFilesystemInfo" o = Gio.File.FileQueryFilesystemInfoMethodInfo
ResolveRepoFileMethod "queryFilesystemInfoAsync" o = Gio.File.FileQueryFilesystemInfoAsyncMethodInfo
ResolveRepoFileMethod "queryFilesystemInfoFinish" o = Gio.File.FileQueryFilesystemInfoFinishMethodInfo
ResolveRepoFileMethod "queryInfo" o = Gio.File.FileQueryInfoMethodInfo
ResolveRepoFileMethod "queryInfoAsync" o = Gio.File.FileQueryInfoAsyncMethodInfo
ResolveRepoFileMethod "queryInfoFinish" o = Gio.File.FileQueryInfoFinishMethodInfo
ResolveRepoFileMethod "querySettableAttributes" o = Gio.File.FileQuerySettableAttributesMethodInfo
ResolveRepoFileMethod "queryWritableNamespaces" o = Gio.File.FileQueryWritableNamespacesMethodInfo
ResolveRepoFileMethod "read" o = Gio.File.FileReadMethodInfo
ResolveRepoFileMethod "readAsync" o = Gio.File.FileReadAsyncMethodInfo
ResolveRepoFileMethod "readFinish" o = Gio.File.FileReadFinishMethodInfo
ResolveRepoFileMethod "ref" o = GObject.Object.ObjectRefMethodInfo
ResolveRepoFileMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo
ResolveRepoFileMethod "replace" o = Gio.File.FileReplaceMethodInfo
ResolveRepoFileMethod "replaceAsync" o = Gio.File.FileReplaceAsyncMethodInfo
ResolveRepoFileMethod "replaceContents" o = Gio.File.FileReplaceContentsMethodInfo
ResolveRepoFileMethod "replaceContentsAsync" o = Gio.File.FileReplaceContentsAsyncMethodInfo
ResolveRepoFileMethod "replaceContentsBytesAsync" o = Gio.File.FileReplaceContentsBytesAsyncMethodInfo
ResolveRepoFileMethod "replaceContentsFinish" o = Gio.File.FileReplaceContentsFinishMethodInfo
ResolveRepoFileMethod "replaceFinish" o = Gio.File.FileReplaceFinishMethodInfo
ResolveRepoFileMethod "replaceReadwrite" o = Gio.File.FileReplaceReadwriteMethodInfo
ResolveRepoFileMethod "replaceReadwriteAsync" o = Gio.File.FileReplaceReadwriteAsyncMethodInfo
ResolveRepoFileMethod "replaceReadwriteFinish" o = Gio.File.FileReplaceReadwriteFinishMethodInfo
ResolveRepoFileMethod "resolveRelativePath" o = Gio.File.FileResolveRelativePathMethodInfo
ResolveRepoFileMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo
ResolveRepoFileMethod "startMountable" o = Gio.File.FileStartMountableMethodInfo
ResolveRepoFileMethod "startMountableFinish" o = Gio.File.FileStartMountableFinishMethodInfo
ResolveRepoFileMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo
ResolveRepoFileMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo
ResolveRepoFileMethod "stopMountable" o = Gio.File.FileStopMountableMethodInfo
ResolveRepoFileMethod "stopMountableFinish" o = Gio.File.FileStopMountableFinishMethodInfo
ResolveRepoFileMethod "supportsThreadContexts" o = Gio.File.FileSupportsThreadContextsMethodInfo
ResolveRepoFileMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo
ResolveRepoFileMethod "trash" o = Gio.File.FileTrashMethodInfo
ResolveRepoFileMethod "trashAsync" o = Gio.File.FileTrashAsyncMethodInfo
ResolveRepoFileMethod "trashFinish" o = Gio.File.FileTrashFinishMethodInfo
ResolveRepoFileMethod "treeFindChild" o = RepoFileTreeFindChildMethodInfo
ResolveRepoFileMethod "treeGetContents" o = RepoFileTreeGetContentsMethodInfo
ResolveRepoFileMethod "treeGetContentsChecksum" o = RepoFileTreeGetContentsChecksumMethodInfo
ResolveRepoFileMethod "treeGetMetadata" o = RepoFileTreeGetMetadataMethodInfo
ResolveRepoFileMethod "treeGetMetadataChecksum" o = RepoFileTreeGetMetadataChecksumMethodInfo
ResolveRepoFileMethod "treeQueryChild" o = RepoFileTreeQueryChildMethodInfo
ResolveRepoFileMethod "treeSetMetadata" o = RepoFileTreeSetMetadataMethodInfo
ResolveRepoFileMethod "unmountMountable" o = Gio.File.FileUnmountMountableMethodInfo
ResolveRepoFileMethod "unmountMountableFinish" o = Gio.File.FileUnmountMountableFinishMethodInfo
ResolveRepoFileMethod "unmountMountableWithOperation" o = Gio.File.FileUnmountMountableWithOperationMethodInfo
ResolveRepoFileMethod "unmountMountableWithOperationFinish" o = Gio.File.FileUnmountMountableWithOperationFinishMethodInfo
ResolveRepoFileMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo
ResolveRepoFileMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo
ResolveRepoFileMethod "getBasename" o = Gio.File.FileGetBasenameMethodInfo
ResolveRepoFileMethod "getChecksum" o = RepoFileGetChecksumMethodInfo
ResolveRepoFileMethod "getChild" o = Gio.File.FileGetChildMethodInfo
ResolveRepoFileMethod "getChildForDisplayName" o = Gio.File.FileGetChildForDisplayNameMethodInfo
ResolveRepoFileMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo
ResolveRepoFileMethod "getParent" o = Gio.File.FileGetParentMethodInfo
ResolveRepoFileMethod "getParseName" o = Gio.File.FileGetParseNameMethodInfo
ResolveRepoFileMethod "getPath" o = Gio.File.FileGetPathMethodInfo
ResolveRepoFileMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo
ResolveRepoFileMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo
ResolveRepoFileMethod "getRelativePath" o = Gio.File.FileGetRelativePathMethodInfo
ResolveRepoFileMethod "getRepo" o = RepoFileGetRepoMethodInfo
ResolveRepoFileMethod "getRoot" o = RepoFileGetRootMethodInfo
ResolveRepoFileMethod "getUri" o = Gio.File.FileGetUriMethodInfo
ResolveRepoFileMethod "getUriScheme" o = Gio.File.FileGetUriSchemeMethodInfo
ResolveRepoFileMethod "getXattrs" o = RepoFileGetXattrsMethodInfo
ResolveRepoFileMethod "setAttribute" o = Gio.File.FileSetAttributeMethodInfo
ResolveRepoFileMethod "setAttributeByteString" o = Gio.File.FileSetAttributeByteStringMethodInfo
ResolveRepoFileMethod "setAttributeInt32" o = Gio.File.FileSetAttributeInt32MethodInfo
ResolveRepoFileMethod "setAttributeInt64" o = Gio.File.FileSetAttributeInt64MethodInfo
ResolveRepoFileMethod "setAttributeString" o = Gio.File.FileSetAttributeStringMethodInfo
ResolveRepoFileMethod "setAttributeUint32" o = Gio.File.FileSetAttributeUint32MethodInfo
ResolveRepoFileMethod "setAttributeUint64" o = Gio.File.FileSetAttributeUint64MethodInfo
ResolveRepoFileMethod "setAttributesAsync" o = Gio.File.FileSetAttributesAsyncMethodInfo
ResolveRepoFileMethod "setAttributesFinish" o = Gio.File.FileSetAttributesFinishMethodInfo
ResolveRepoFileMethod "setAttributesFromInfo" o = Gio.File.FileSetAttributesFromInfoMethodInfo
ResolveRepoFileMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo
ResolveRepoFileMethod "setDataFull" o = GObject.Object.ObjectSetDataFullMethodInfo
ResolveRepoFileMethod "setDisplayName" o = Gio.File.FileSetDisplayNameMethodInfo
ResolveRepoFileMethod "setDisplayNameAsync" o = Gio.File.FileSetDisplayNameAsyncMethodInfo
ResolveRepoFileMethod "setDisplayNameFinish" o = Gio.File.FileSetDisplayNameFinishMethodInfo
ResolveRepoFileMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo
ResolveRepoFileMethod l o = O.MethodResolutionFailed l o
instance (info ~ ResolveRepoFileMethod t RepoFile, O.OverloadedMethod info RepoFile p) => OL.IsLabel t (RepoFile -> 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 ~ ResolveRepoFileMethod t RepoFile, O.OverloadedMethod info RepoFile p, R.HasField t RepoFile p) => R.HasField t RepoFile p where
getField = O.overloadedMethod @info
#endif
instance (info ~ ResolveRepoFileMethod t RepoFile, O.OverloadedMethodInfo info RepoFile) => OL.IsLabel t (O.MethodProxy info RepoFile) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.MethodProxy
#else
fromLabel _ = O.MethodProxy
#endif
#endif
#if defined(ENABLE_OVERLOADING)
instance O.HasAttributeList RepoFile
type instance O.AttributeList RepoFile = RepoFileAttributeList
type RepoFileAttributeList = ('[ ] :: [(Symbol, *)])
#endif
#if defined(ENABLE_OVERLOADING)
#endif
#if defined(ENABLE_OVERLOADING)
type instance O.SignalList RepoFile = RepoFileSignalList
type RepoFileSignalList = ('[ '("notify", GObject.Object.ObjectNotifySignalInfo)] :: [(Symbol, *)])
#endif
foreign import ccall "ostree_repo_file_ensure_resolved" ostree_repo_file_ensure_resolved ::
Ptr RepoFile ->
Ptr (Ptr GError) ->
IO CInt
repoFileEnsureResolved ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a) =>
a
-> m ()
repoFileEnsureResolved :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsRepoFile a) =>
a -> m ()
repoFileEnsureResolved a
self = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
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 RepoFile -> Ptr (Ptr GError) -> IO CInt
ostree_repo_file_ensure_resolved Ptr RepoFile
self'
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
() -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()
) (do
() -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()
)
#if defined(ENABLE_OVERLOADING)
data RepoFileEnsureResolvedMethodInfo
instance (signature ~ (m ()), MonadIO m, IsRepoFile a) => O.OverloadedMethod RepoFileEnsureResolvedMethodInfo a signature where
overloadedMethod = repoFileEnsureResolved
instance O.OverloadedMethodInfo RepoFileEnsureResolvedMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileEnsureResolved",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileEnsureResolved"
})
#endif
foreign import ccall "ostree_repo_file_get_checksum" ostree_repo_file_get_checksum ::
Ptr RepoFile ->
IO CString
repoFileGetChecksum ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a) =>
a
-> m T.Text
repoFileGetChecksum :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsRepoFile a) =>
a -> m Text
repoFileGetChecksum a
self = IO Text -> m Text
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 RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
CString
result <- Ptr RepoFile -> IO CString
ostree_repo_file_get_checksum Ptr RepoFile
self'
Text -> CString -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"repoFileGetChecksum" 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 (m :: * -> *) a. Monad m => a -> m a
return Text
result'
#if defined(ENABLE_OVERLOADING)
data RepoFileGetChecksumMethodInfo
instance (signature ~ (m T.Text), MonadIO m, IsRepoFile a) => O.OverloadedMethod RepoFileGetChecksumMethodInfo a signature where
overloadedMethod = repoFileGetChecksum
instance O.OverloadedMethodInfo RepoFileGetChecksumMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileGetChecksum",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileGetChecksum"
})
#endif
foreign import ccall "ostree_repo_file_get_repo" ostree_repo_file_get_repo ::
Ptr RepoFile ->
IO (Ptr OSTree.Repo.Repo)
repoFileGetRepo ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a) =>
a
-> m OSTree.Repo.Repo
repoFileGetRepo :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsRepoFile a) =>
a -> m Repo
repoFileGetRepo a
self = IO Repo -> m Repo
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Repo -> m Repo) -> IO Repo -> m Repo
forall a b. (a -> b) -> a -> b
$ do
Ptr RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr Repo
result <- Ptr RepoFile -> IO (Ptr Repo)
ostree_repo_file_get_repo Ptr RepoFile
self'
Text -> Ptr Repo -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"repoFileGetRepo" Ptr Repo
result
Repo
result' <- ((ManagedPtr Repo -> Repo) -> Ptr Repo -> IO Repo
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr Repo -> Repo
OSTree.Repo.Repo) Ptr Repo
result
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
Repo -> IO Repo
forall (m :: * -> *) a. Monad m => a -> m a
return Repo
result'
#if defined(ENABLE_OVERLOADING)
data RepoFileGetRepoMethodInfo
instance (signature ~ (m OSTree.Repo.Repo), MonadIO m, IsRepoFile a) => O.OverloadedMethod RepoFileGetRepoMethodInfo a signature where
overloadedMethod = repoFileGetRepo
instance O.OverloadedMethodInfo RepoFileGetRepoMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileGetRepo",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileGetRepo"
})
#endif
foreign import ccall "ostree_repo_file_get_root" ostree_repo_file_get_root ::
Ptr RepoFile ->
IO (Ptr RepoFile)
repoFileGetRoot ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a) =>
a
-> m RepoFile
repoFileGetRoot :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsRepoFile a) =>
a -> m RepoFile
repoFileGetRoot a
self = IO RepoFile -> m RepoFile
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO RepoFile -> m RepoFile) -> IO RepoFile -> m RepoFile
forall a b. (a -> b) -> a -> b
$ do
Ptr RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr RepoFile
result <- Ptr RepoFile -> IO (Ptr RepoFile)
ostree_repo_file_get_root Ptr RepoFile
self'
Text -> Ptr RepoFile -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"repoFileGetRoot" Ptr RepoFile
result
RepoFile
result' <- ((ManagedPtr RepoFile -> RepoFile) -> Ptr RepoFile -> IO RepoFile
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr RepoFile -> RepoFile
RepoFile) Ptr RepoFile
result
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
RepoFile -> IO RepoFile
forall (m :: * -> *) a. Monad m => a -> m a
return RepoFile
result'
#if defined(ENABLE_OVERLOADING)
data RepoFileGetRootMethodInfo
instance (signature ~ (m RepoFile), MonadIO m, IsRepoFile a) => O.OverloadedMethod RepoFileGetRootMethodInfo a signature where
overloadedMethod = repoFileGetRoot
instance O.OverloadedMethodInfo RepoFileGetRootMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileGetRoot",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileGetRoot"
})
#endif
foreign import ccall "ostree_repo_file_get_xattrs" ostree_repo_file_get_xattrs ::
Ptr RepoFile ->
Ptr (Ptr GVariant) ->
Ptr Gio.Cancellable.Cancellable ->
Ptr (Ptr GError) ->
IO CInt
repoFileGetXattrs ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a, Gio.Cancellable.IsCancellable b) =>
a
-> Maybe (b)
-> m (GVariant)
repoFileGetXattrs :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsRepoFile a, IsCancellable b) =>
a -> Maybe b -> m GVariant
repoFileGetXattrs a
self Maybe b
cancellable = IO GVariant -> m GVariant
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO GVariant -> m GVariant) -> IO GVariant -> m GVariant
forall a b. (a -> b) -> a -> b
$ do
Ptr RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr (Ptr GVariant)
outXattrs <- IO (Ptr (Ptr GVariant))
forall a. Storable a => IO (Ptr a)
callocMem :: IO (Ptr (Ptr GVariant))
Ptr Cancellable
maybeCancellable <- case Maybe b
cancellable of
Maybe b
Nothing -> Ptr Cancellable -> IO (Ptr Cancellable)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
forall a. Ptr a
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 (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
jCancellable'
IO GVariant -> IO () -> IO GVariant
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 RepoFile
-> Ptr (Ptr GVariant)
-> Ptr Cancellable
-> Ptr (Ptr GError)
-> IO CInt
ostree_repo_file_get_xattrs Ptr RepoFile
self' Ptr (Ptr GVariant)
outXattrs Ptr Cancellable
maybeCancellable
Ptr GVariant
outXattrs' <- Ptr (Ptr GVariant) -> IO (Ptr GVariant)
forall a. Storable a => Ptr a -> IO a
peek Ptr (Ptr GVariant)
outXattrs
GVariant
outXattrs'' <- Ptr GVariant -> IO GVariant
B.GVariant.wrapGVariantPtr Ptr GVariant
outXattrs'
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
Ptr (Ptr GVariant) -> IO ()
forall a. Ptr a -> IO ()
freeMem Ptr (Ptr GVariant)
outXattrs
GVariant -> IO GVariant
forall (m :: * -> *) a. Monad m => a -> m a
return GVariant
outXattrs''
) (do
Ptr (Ptr GVariant) -> IO ()
forall a. Ptr a -> IO ()
freeMem Ptr (Ptr GVariant)
outXattrs
)
#if defined(ENABLE_OVERLOADING)
data RepoFileGetXattrsMethodInfo
instance (signature ~ (Maybe (b) -> m (GVariant)), MonadIO m, IsRepoFile a, Gio.Cancellable.IsCancellable b) => O.OverloadedMethod RepoFileGetXattrsMethodInfo a signature where
overloadedMethod = repoFileGetXattrs
instance O.OverloadedMethodInfo RepoFileGetXattrsMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileGetXattrs",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileGetXattrs"
})
#endif
#if defined(ENABLE_OVERLOADING)
data RepoFileTreeFindChildMethodInfo
instance (p ~ (), o ~ O.UnsupportedMethodError "treeFindChild" RepoFile) => O.OverloadedMethod RepoFileTreeFindChildMethodInfo o p where
overloadedMethod = undefined
instance (o ~ O.UnsupportedMethodError "treeFindChild" RepoFile) => O.OverloadedMethodInfo RepoFileTreeFindChildMethodInfo o where
overloadedMethodInfo = undefined
#endif
foreign import ccall "ostree_repo_file_tree_get_contents" ostree_repo_file_tree_get_contents ::
Ptr RepoFile ->
IO (Ptr GVariant)
repoFileTreeGetContents ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a) =>
a
-> m GVariant
repoFileTreeGetContents :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsRepoFile a) =>
a -> m GVariant
repoFileTreeGetContents a
self = IO GVariant -> m GVariant
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO GVariant -> m GVariant) -> IO GVariant -> m GVariant
forall a b. (a -> b) -> a -> b
$ do
Ptr RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr GVariant
result <- Ptr RepoFile -> IO (Ptr GVariant)
ostree_repo_file_tree_get_contents Ptr RepoFile
self'
Text -> Ptr GVariant -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"repoFileTreeGetContents" Ptr GVariant
result
GVariant
result' <- Ptr GVariant -> IO GVariant
B.GVariant.wrapGVariantPtr Ptr GVariant
result
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
GVariant -> IO GVariant
forall (m :: * -> *) a. Monad m => a -> m a
return GVariant
result'
#if defined(ENABLE_OVERLOADING)
data RepoFileTreeGetContentsMethodInfo
instance (signature ~ (m GVariant), MonadIO m, IsRepoFile a) => O.OverloadedMethod RepoFileTreeGetContentsMethodInfo a signature where
overloadedMethod = repoFileTreeGetContents
instance O.OverloadedMethodInfo RepoFileTreeGetContentsMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileTreeGetContents",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileTreeGetContents"
})
#endif
foreign import ccall "ostree_repo_file_tree_get_contents_checksum" ostree_repo_file_tree_get_contents_checksum ::
Ptr RepoFile ->
IO CString
repoFileTreeGetContentsChecksum ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a) =>
a
-> m T.Text
repoFileTreeGetContentsChecksum :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsRepoFile a) =>
a -> m Text
repoFileTreeGetContentsChecksum a
self = IO Text -> m Text
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 RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
CString
result <- Ptr RepoFile -> IO CString
ostree_repo_file_tree_get_contents_checksum Ptr RepoFile
self'
Text -> CString -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"repoFileTreeGetContentsChecksum" 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 (m :: * -> *) a. Monad m => a -> m a
return Text
result'
#if defined(ENABLE_OVERLOADING)
data RepoFileTreeGetContentsChecksumMethodInfo
instance (signature ~ (m T.Text), MonadIO m, IsRepoFile a) => O.OverloadedMethod RepoFileTreeGetContentsChecksumMethodInfo a signature where
overloadedMethod = repoFileTreeGetContentsChecksum
instance O.OverloadedMethodInfo RepoFileTreeGetContentsChecksumMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileTreeGetContentsChecksum",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileTreeGetContentsChecksum"
})
#endif
foreign import ccall "ostree_repo_file_tree_get_metadata" ostree_repo_file_tree_get_metadata ::
Ptr RepoFile ->
IO (Ptr GVariant)
repoFileTreeGetMetadata ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a) =>
a
-> m GVariant
repoFileTreeGetMetadata :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsRepoFile a) =>
a -> m GVariant
repoFileTreeGetMetadata a
self = IO GVariant -> m GVariant
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO GVariant -> m GVariant) -> IO GVariant -> m GVariant
forall a b. (a -> b) -> a -> b
$ do
Ptr RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
Ptr GVariant
result <- Ptr RepoFile -> IO (Ptr GVariant)
ostree_repo_file_tree_get_metadata Ptr RepoFile
self'
Text -> Ptr GVariant -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"repoFileTreeGetMetadata" Ptr GVariant
result
GVariant
result' <- Ptr GVariant -> IO GVariant
B.GVariant.wrapGVariantPtr Ptr GVariant
result
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
GVariant -> IO GVariant
forall (m :: * -> *) a. Monad m => a -> m a
return GVariant
result'
#if defined(ENABLE_OVERLOADING)
data RepoFileTreeGetMetadataMethodInfo
instance (signature ~ (m GVariant), MonadIO m, IsRepoFile a) => O.OverloadedMethod RepoFileTreeGetMetadataMethodInfo a signature where
overloadedMethod = repoFileTreeGetMetadata
instance O.OverloadedMethodInfo RepoFileTreeGetMetadataMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileTreeGetMetadata",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileTreeGetMetadata"
})
#endif
foreign import ccall "ostree_repo_file_tree_get_metadata_checksum" ostree_repo_file_tree_get_metadata_checksum ::
Ptr RepoFile ->
IO CString
repoFileTreeGetMetadataChecksum ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a) =>
a
-> m T.Text
repoFileTreeGetMetadataChecksum :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsRepoFile a) =>
a -> m Text
repoFileTreeGetMetadataChecksum a
self = IO Text -> m Text
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 RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
CString
result <- Ptr RepoFile -> IO CString
ostree_repo_file_tree_get_metadata_checksum Ptr RepoFile
self'
Text -> CString -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"repoFileTreeGetMetadataChecksum" 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 (m :: * -> *) a. Monad m => a -> m a
return Text
result'
#if defined(ENABLE_OVERLOADING)
data RepoFileTreeGetMetadataChecksumMethodInfo
instance (signature ~ (m T.Text), MonadIO m, IsRepoFile a) => O.OverloadedMethod RepoFileTreeGetMetadataChecksumMethodInfo a signature where
overloadedMethod = repoFileTreeGetMetadataChecksum
instance O.OverloadedMethodInfo RepoFileTreeGetMetadataChecksumMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileTreeGetMetadataChecksum",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileTreeGetMetadataChecksum"
})
#endif
foreign import ccall "ostree_repo_file_tree_query_child" ostree_repo_file_tree_query_child ::
Ptr RepoFile ->
Int32 ->
CString ->
CUInt ->
Ptr (Ptr Gio.FileInfo.FileInfo) ->
Ptr Gio.Cancellable.Cancellable ->
Ptr (Ptr GError) ->
IO CInt
repoFileTreeQueryChild ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a, Gio.Cancellable.IsCancellable b) =>
a
-> Int32
-> T.Text
-> [Gio.Flags.FileQueryInfoFlags]
-> Maybe (b)
-> m (Gio.FileInfo.FileInfo)
repoFileTreeQueryChild :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsRepoFile a, IsCancellable b) =>
a -> Int32 -> Text -> [FileQueryInfoFlags] -> Maybe b -> m FileInfo
repoFileTreeQueryChild a
self Int32
n Text
attributes [FileQueryInfoFlags]
flags Maybe b
cancellable = IO FileInfo -> m FileInfo
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO FileInfo -> m FileInfo) -> IO FileInfo -> m FileInfo
forall a b. (a -> b) -> a -> b
$ do
Ptr RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
CString
attributes' <- Text -> IO CString
textToCString Text
attributes
let flags' :: CUInt
flags' = [FileQueryInfoFlags] -> CUInt
forall b a. (Num b, IsGFlag a) => [a] -> b
gflagsToWord [FileQueryInfoFlags]
flags
Ptr (Ptr FileInfo)
outInfo <- IO (Ptr (Ptr FileInfo))
forall a. Storable a => IO (Ptr a)
callocMem :: IO (Ptr (Ptr Gio.FileInfo.FileInfo))
Ptr Cancellable
maybeCancellable <- case Maybe b
cancellable of
Maybe b
Nothing -> Ptr Cancellable -> IO (Ptr Cancellable)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
forall a. Ptr a
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 (m :: * -> *) a. Monad m => a -> m a
return Ptr Cancellable
jCancellable'
IO FileInfo -> IO () -> IO FileInfo
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 RepoFile
-> Int32
-> CString
-> CUInt
-> Ptr (Ptr FileInfo)
-> Ptr Cancellable
-> Ptr (Ptr GError)
-> IO CInt
ostree_repo_file_tree_query_child Ptr RepoFile
self' Int32
n CString
attributes' CUInt
flags' Ptr (Ptr FileInfo)
outInfo Ptr Cancellable
maybeCancellable
Ptr FileInfo
outInfo' <- Ptr (Ptr FileInfo) -> IO (Ptr FileInfo)
forall a. Storable a => Ptr a -> IO a
peek Ptr (Ptr FileInfo)
outInfo
FileInfo
outInfo'' <- ((ManagedPtr FileInfo -> FileInfo) -> Ptr FileInfo -> IO FileInfo
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
wrapObject ManagedPtr FileInfo -> FileInfo
Gio.FileInfo.FileInfo) Ptr FileInfo
outInfo'
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
CString -> IO ()
forall a. Ptr a -> IO ()
freeMem CString
attributes'
Ptr (Ptr FileInfo) -> IO ()
forall a. Ptr a -> IO ()
freeMem Ptr (Ptr FileInfo)
outInfo
FileInfo -> IO FileInfo
forall (m :: * -> *) a. Monad m => a -> m a
return FileInfo
outInfo''
) (do
CString -> IO ()
forall a. Ptr a -> IO ()
freeMem CString
attributes'
Ptr (Ptr FileInfo) -> IO ()
forall a. Ptr a -> IO ()
freeMem Ptr (Ptr FileInfo)
outInfo
)
#if defined(ENABLE_OVERLOADING)
data RepoFileTreeQueryChildMethodInfo
instance (signature ~ (Int32 -> T.Text -> [Gio.Flags.FileQueryInfoFlags] -> Maybe (b) -> m (Gio.FileInfo.FileInfo)), MonadIO m, IsRepoFile a, Gio.Cancellable.IsCancellable b) => O.OverloadedMethod RepoFileTreeQueryChildMethodInfo a signature where
overloadedMethod = repoFileTreeQueryChild
instance O.OverloadedMethodInfo RepoFileTreeQueryChildMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileTreeQueryChild",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileTreeQueryChild"
})
#endif
foreign import ccall "ostree_repo_file_tree_set_metadata" ostree_repo_file_tree_set_metadata ::
Ptr RepoFile ->
CString ->
Ptr GVariant ->
IO ()
repoFileTreeSetMetadata ::
(B.CallStack.HasCallStack, MonadIO m, IsRepoFile a) =>
a
-> T.Text
-> GVariant
-> m ()
repoFileTreeSetMetadata :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsRepoFile a) =>
a -> Text -> GVariant -> m ()
repoFileTreeSetMetadata a
self Text
checksum GVariant
metadata = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr RepoFile
self' <- a -> IO (Ptr RepoFile)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
CString
checksum' <- Text -> IO CString
textToCString Text
checksum
Ptr GVariant
metadata' <- GVariant -> IO (Ptr GVariant)
forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr GVariant
metadata
Ptr RepoFile -> CString -> Ptr GVariant -> IO ()
ostree_repo_file_tree_set_metadata Ptr RepoFile
self' CString
checksum' Ptr GVariant
metadata'
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
GVariant -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr GVariant
metadata
CString -> IO ()
forall a. Ptr a -> IO ()
freeMem CString
checksum'
() -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data RepoFileTreeSetMetadataMethodInfo
instance (signature ~ (T.Text -> GVariant -> m ()), MonadIO m, IsRepoFile a) => O.OverloadedMethod RepoFileTreeSetMetadataMethodInfo a signature where
overloadedMethod = repoFileTreeSetMetadata
instance O.OverloadedMethodInfo RepoFileTreeSetMetadataMethodInfo a where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.OSTree.Objects.RepoFile.repoFileTreeSetMetadata",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-ostree-1.0.15/docs/GI-OSTree-Objects-RepoFile.html#v:repoFileTreeSetMetadata"
})
#endif