{- | Copyright : Will Thompson, Iñaki García Etxebarria and Jonas Platte License : LGPL-2.1 Maintainer : Iñaki García Etxebarria (garetxe@gmail.com) The `GBookmarkFile` structure contains only private data and should not be directly accessed. -} module GI.GLib.Structs.BookmarkFile ( -- * Exported types BookmarkFile(..) , noBookmarkFile , -- * Methods -- ** bookmarkFileAddApplication bookmarkFileAddApplication , -- ** bookmarkFileAddGroup bookmarkFileAddGroup , -- ** bookmarkFileFree bookmarkFileFree , -- ** bookmarkFileGetAdded bookmarkFileGetAdded , -- ** bookmarkFileGetAppInfo bookmarkFileGetAppInfo , -- ** bookmarkFileGetApplications bookmarkFileGetApplications , -- ** bookmarkFileGetDescription bookmarkFileGetDescription , -- ** bookmarkFileGetGroups bookmarkFileGetGroups , -- ** bookmarkFileGetIcon bookmarkFileGetIcon , -- ** bookmarkFileGetIsPrivate bookmarkFileGetIsPrivate , -- ** bookmarkFileGetMimeType bookmarkFileGetMimeType , -- ** bookmarkFileGetModified bookmarkFileGetModified , -- ** bookmarkFileGetSize bookmarkFileGetSize , -- ** bookmarkFileGetTitle bookmarkFileGetTitle , -- ** bookmarkFileGetUris bookmarkFileGetUris , -- ** bookmarkFileGetVisited bookmarkFileGetVisited , -- ** bookmarkFileHasApplication bookmarkFileHasApplication , -- ** bookmarkFileHasGroup bookmarkFileHasGroup , -- ** bookmarkFileHasItem bookmarkFileHasItem , -- ** bookmarkFileLoadFromData bookmarkFileLoadFromData , -- ** bookmarkFileLoadFromDataDirs bookmarkFileLoadFromDataDirs , -- ** bookmarkFileLoadFromFile bookmarkFileLoadFromFile , -- ** bookmarkFileMoveItem bookmarkFileMoveItem , -- ** bookmarkFileRemoveApplication bookmarkFileRemoveApplication , -- ** bookmarkFileRemoveGroup bookmarkFileRemoveGroup , -- ** bookmarkFileRemoveItem bookmarkFileRemoveItem , -- ** bookmarkFileSetAdded bookmarkFileSetAdded , -- ** bookmarkFileSetAppInfo bookmarkFileSetAppInfo , -- ** bookmarkFileSetDescription bookmarkFileSetDescription , -- ** bookmarkFileSetGroups bookmarkFileSetGroups , -- ** bookmarkFileSetIcon bookmarkFileSetIcon , -- ** bookmarkFileSetIsPrivate bookmarkFileSetIsPrivate , -- ** bookmarkFileSetMimeType bookmarkFileSetMimeType , -- ** bookmarkFileSetModified bookmarkFileSetModified , -- ** bookmarkFileSetTitle bookmarkFileSetTitle , -- ** bookmarkFileSetVisited bookmarkFileSetVisited , -- ** bookmarkFileToData bookmarkFileToData , -- ** bookmarkFileToFile bookmarkFileToFile , ) where import Prelude () import Data.GI.Base.ShortPrelude import qualified Data.Text as T import qualified Data.ByteString.Char8 as B import qualified Data.Map as Map import GI.GLib.Types import GI.GLib.Callbacks newtype BookmarkFile = BookmarkFile (ForeignPtr BookmarkFile) noBookmarkFile :: Maybe BookmarkFile noBookmarkFile = Nothing -- method BookmarkFile::add_application -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "exec", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "exec", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_add_application" g_bookmark_file_add_application :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- name : TBasicType TUTF8 CString -> -- exec : TBasicType TUTF8 IO () bookmarkFileAddApplication :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri Maybe (T.Text) -> -- name Maybe (T.Text) -> -- exec m () bookmarkFileAddApplication _obj uri name exec = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri maybeName <- case name of Nothing -> return nullPtr Just jName -> do jName' <- textToCString jName return jName' maybeExec <- case exec of Nothing -> return nullPtr Just jExec -> do jExec' <- textToCString jExec return jExec' g_bookmark_file_add_application _obj' uri' maybeName maybeExec touchManagedPtr _obj freeMem uri' freeMem maybeName freeMem maybeExec return () -- method BookmarkFile::add_group -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_add_group" g_bookmark_file_add_group :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- group : TBasicType TUTF8 IO () bookmarkFileAddGroup :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri T.Text -> -- group m () bookmarkFileAddGroup _obj uri group = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri group' <- textToCString group g_bookmark_file_add_group _obj' uri' group' touchManagedPtr _obj freeMem uri' freeMem group' return () -- method BookmarkFile::free -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_free" g_bookmark_file_free :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" IO () bookmarkFileFree :: (MonadIO m) => BookmarkFile -> -- _obj m () bookmarkFileFree _obj = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj g_bookmark_file_free _obj' touchManagedPtr _obj return () -- method BookmarkFile::get_added -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TInt64 -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_added" g_bookmark_file_get_added :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO Int64 bookmarkFileGetAdded :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m Int64 bookmarkFileGetAdded _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri onException (do result <- propagateGError $ g_bookmark_file_get_added _obj' uri' touchManagedPtr _obj freeMem uri' return result ) (do freeMem uri' ) -- method BookmarkFile::get_app_info -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "exec", argType = TBasicType TUTF8, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything},Arg {argName = "count", argType = TBasicType TUInt32, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything},Arg {argName = "stamp", argType = TBasicType TInt64, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_app_info" g_bookmark_file_get_app_info :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- name : TBasicType TUTF8 Ptr CString -> -- exec : TBasicType TUTF8 Ptr Word32 -> -- count : TBasicType TUInt32 Ptr Int64 -> -- stamp : TBasicType TInt64 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileGetAppInfo :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri T.Text -> -- name m (T.Text,Word32,Int64) bookmarkFileGetAppInfo _obj uri name = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri name' <- textToCString name exec <- allocMem :: IO (Ptr CString) count <- allocMem :: IO (Ptr Word32) stamp <- allocMem :: IO (Ptr Int64) onException (do _ <- propagateGError $ g_bookmark_file_get_app_info _obj' uri' name' exec count stamp exec' <- peek exec exec'' <- cstringToText exec' freeMem exec' count' <- peek count stamp' <- peek stamp touchManagedPtr _obj freeMem uri' freeMem name' freeMem exec freeMem count freeMem stamp return (exec'', count', stamp') ) (do freeMem uri' freeMem name' freeMem exec freeMem count freeMem stamp ) -- method BookmarkFile::get_applications -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}] -- Lengths : [Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TCArray False (-1) 2 (TBasicType TUTF8) -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_applications" g_bookmark_file_get_applications :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr Word64 -> -- length : TBasicType TUInt64 Ptr (Ptr GError) -> -- error IO (Ptr CString) bookmarkFileGetApplications :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m [T.Text] bookmarkFileGetApplications _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri length_ <- allocMem :: IO (Ptr Word64) onException (do result <- propagateGError $ g_bookmark_file_get_applications _obj' uri' length_ length_' <- peek length_ checkUnexpectedReturnNULL "g_bookmark_file_get_applications" result result' <- (unpackUTF8CArrayWithLength length_') result (mapCArrayWithLength length_') freeMem result freeMem result touchManagedPtr _obj freeMem uri' freeMem length_ return result' ) (do freeMem uri' freeMem length_ ) -- method BookmarkFile::get_description -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TUTF8 -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_description" g_bookmark_file_get_description :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CString bookmarkFileGetDescription :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m T.Text bookmarkFileGetDescription _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri onException (do result <- propagateGError $ g_bookmark_file_get_description _obj' uri' checkUnexpectedReturnNULL "g_bookmark_file_get_description" result result' <- cstringToText result freeMem result touchManagedPtr _obj freeMem uri' return result' ) (do freeMem uri' ) -- method BookmarkFile::get_groups -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}] -- Lengths : [Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TCArray False (-1) 2 (TBasicType TUTF8) -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_groups" g_bookmark_file_get_groups :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr Word64 -> -- length : TBasicType TUInt64 Ptr (Ptr GError) -> -- error IO (Ptr CString) bookmarkFileGetGroups :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m [T.Text] bookmarkFileGetGroups _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri length_ <- allocMem :: IO (Ptr Word64) onException (do result <- propagateGError $ g_bookmark_file_get_groups _obj' uri' length_ length_' <- peek length_ checkUnexpectedReturnNULL "g_bookmark_file_get_groups" result result' <- (unpackUTF8CArrayWithLength length_') result (mapCArrayWithLength length_') freeMem result freeMem result touchManagedPtr _obj freeMem uri' freeMem length_ return result' ) (do freeMem uri' freeMem length_ ) -- method BookmarkFile::get_icon -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "href", argType = TBasicType TUTF8, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything},Arg {argName = "mime_type", argType = TBasicType TUTF8, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_icon" g_bookmark_file_get_icon :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr CString -> -- href : TBasicType TUTF8 Ptr CString -> -- mime_type : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileGetIcon :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m (T.Text,T.Text) bookmarkFileGetIcon _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri href <- allocMem :: IO (Ptr CString) mime_type <- allocMem :: IO (Ptr CString) onException (do _ <- propagateGError $ g_bookmark_file_get_icon _obj' uri' href mime_type href' <- peek href href'' <- cstringToText href' freeMem href' mime_type' <- peek mime_type mime_type'' <- cstringToText mime_type' freeMem mime_type' touchManagedPtr _obj freeMem uri' freeMem href freeMem mime_type return (href'', mime_type'') ) (do freeMem uri' freeMem href freeMem mime_type ) -- method BookmarkFile::get_is_private -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_is_private" g_bookmark_file_get_is_private :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileGetIsPrivate :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m () bookmarkFileGetIsPrivate _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri onException (do _ <- propagateGError $ g_bookmark_file_get_is_private _obj' uri' touchManagedPtr _obj freeMem uri' return () ) (do freeMem uri' ) -- method BookmarkFile::get_mime_type -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TUTF8 -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_mime_type" g_bookmark_file_get_mime_type :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CString bookmarkFileGetMimeType :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m T.Text bookmarkFileGetMimeType _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri onException (do result <- propagateGError $ g_bookmark_file_get_mime_type _obj' uri' checkUnexpectedReturnNULL "g_bookmark_file_get_mime_type" result result' <- cstringToText result freeMem result touchManagedPtr _obj freeMem uri' return result' ) (do freeMem uri' ) -- method BookmarkFile::get_modified -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TInt64 -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_modified" g_bookmark_file_get_modified :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO Int64 bookmarkFileGetModified :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m Int64 bookmarkFileGetModified _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri onException (do result <- propagateGError $ g_bookmark_file_get_modified _obj' uri' touchManagedPtr _obj freeMem uri' return result ) (do freeMem uri' ) -- method BookmarkFile::get_size -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TInt32 -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_get_size" g_bookmark_file_get_size :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" IO Int32 bookmarkFileGetSize :: (MonadIO m) => BookmarkFile -> -- _obj m Int32 bookmarkFileGetSize _obj = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj result <- g_bookmark_file_get_size _obj' touchManagedPtr _obj return result -- method BookmarkFile::get_title -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TUTF8 -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_title" g_bookmark_file_get_title :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CString bookmarkFileGetTitle :: (MonadIO m) => BookmarkFile -> -- _obj Maybe (T.Text) -> -- uri m T.Text bookmarkFileGetTitle _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj maybeUri <- case uri of Nothing -> return nullPtr Just jUri -> do jUri' <- textToCString jUri return jUri' onException (do result <- propagateGError $ g_bookmark_file_get_title _obj' maybeUri checkUnexpectedReturnNULL "g_bookmark_file_get_title" result result' <- cstringToText result freeMem result touchManagedPtr _obj freeMem maybeUri return result' ) (do freeMem maybeUri ) -- method BookmarkFile::get_uris -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}] -- Lengths : [Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TCArray False (-1) 1 (TBasicType TUTF8) -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_get_uris" g_bookmark_file_get_uris :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" Ptr Word64 -> -- length : TBasicType TUInt64 IO (Ptr CString) bookmarkFileGetUris :: (MonadIO m) => BookmarkFile -> -- _obj m [T.Text] bookmarkFileGetUris _obj = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj length_ <- allocMem :: IO (Ptr Word64) result <- g_bookmark_file_get_uris _obj' length_ length_' <- peek length_ checkUnexpectedReturnNULL "g_bookmark_file_get_uris" result result' <- (unpackUTF8CArrayWithLength length_') result (mapCArrayWithLength length_') freeMem result freeMem result touchManagedPtr _obj freeMem length_ return result' -- method BookmarkFile::get_visited -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TInt64 -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_get_visited" g_bookmark_file_get_visited :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO Int64 bookmarkFileGetVisited :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m Int64 bookmarkFileGetVisited _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri onException (do result <- propagateGError $ g_bookmark_file_get_visited _obj' uri' touchManagedPtr _obj freeMem uri' return result ) (do freeMem uri' ) -- method BookmarkFile::has_application -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_has_application" g_bookmark_file_has_application :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- name : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileHasApplication :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri T.Text -> -- name m () bookmarkFileHasApplication _obj uri name = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri name' <- textToCString name onException (do _ <- propagateGError $ g_bookmark_file_has_application _obj' uri' name' touchManagedPtr _obj freeMem uri' freeMem name' return () ) (do freeMem uri' freeMem name' ) -- method BookmarkFile::has_group -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_has_group" g_bookmark_file_has_group :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- group : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileHasGroup :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri T.Text -> -- group m () bookmarkFileHasGroup _obj uri group = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri group' <- textToCString group onException (do _ <- propagateGError $ g_bookmark_file_has_group _obj' uri' group' touchManagedPtr _obj freeMem uri' freeMem group' return () ) (do freeMem uri' freeMem group' ) -- method BookmarkFile::has_item -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_has_item" g_bookmark_file_has_item :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 IO CInt bookmarkFileHasItem :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m Bool bookmarkFileHasItem _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri result <- g_bookmark_file_has_item _obj' uri' let result' = (/= 0) result touchManagedPtr _obj freeMem uri' return result' -- method BookmarkFile::load_from_data -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "data", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "data", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_load_from_data" g_bookmark_file_load_from_data :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- data : TBasicType TUTF8 Word64 -> -- length : TBasicType TUInt64 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileLoadFromData :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- data Word64 -> -- length m () bookmarkFileLoadFromData _obj data_ length_ = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj data_' <- textToCString data_ onException (do _ <- propagateGError $ g_bookmark_file_load_from_data _obj' data_' length_ touchManagedPtr _obj freeMem data_' return () ) (do freeMem data_' ) -- method BookmarkFile::load_from_data_dirs -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "file", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "full_path", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "file", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "full_path", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_load_from_data_dirs" g_bookmark_file_load_from_data_dirs :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- file : TBasicType TUTF8 CString -> -- full_path : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileLoadFromDataDirs :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- file Maybe (T.Text) -> -- full_path m () bookmarkFileLoadFromDataDirs _obj file full_path = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj file' <- textToCString file maybeFull_path <- case full_path of Nothing -> return nullPtr Just jFull_path -> do jFull_path' <- textToCString jFull_path return jFull_path' onException (do _ <- propagateGError $ g_bookmark_file_load_from_data_dirs _obj' file' maybeFull_path touchManagedPtr _obj freeMem file' freeMem maybeFull_path return () ) (do freeMem file' freeMem maybeFull_path ) -- method BookmarkFile::load_from_file -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "filename", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "filename", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_load_from_file" g_bookmark_file_load_from_file :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- filename : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileLoadFromFile :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- filename m () bookmarkFileLoadFromFile _obj filename = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj filename' <- textToCString filename onException (do _ <- propagateGError $ g_bookmark_file_load_from_file _obj' filename' touchManagedPtr _obj freeMem filename' return () ) (do freeMem filename' ) -- method BookmarkFile::move_item -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "old_uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "new_uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "old_uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "new_uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_move_item" g_bookmark_file_move_item :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- old_uri : TBasicType TUTF8 CString -> -- new_uri : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileMoveItem :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- old_uri Maybe (T.Text) -> -- new_uri m () bookmarkFileMoveItem _obj old_uri new_uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj old_uri' <- textToCString old_uri maybeNew_uri <- case new_uri of Nothing -> return nullPtr Just jNew_uri -> do jNew_uri' <- textToCString jNew_uri return jNew_uri' onException (do _ <- propagateGError $ g_bookmark_file_move_item _obj' old_uri' maybeNew_uri touchManagedPtr _obj freeMem old_uri' freeMem maybeNew_uri return () ) (do freeMem old_uri' freeMem maybeNew_uri ) -- method BookmarkFile::remove_application -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_remove_application" g_bookmark_file_remove_application :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- name : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileRemoveApplication :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri T.Text -> -- name m () bookmarkFileRemoveApplication _obj uri name = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri name' <- textToCString name onException (do _ <- propagateGError $ g_bookmark_file_remove_application _obj' uri' name' touchManagedPtr _obj freeMem uri' freeMem name' return () ) (do freeMem uri' freeMem name' ) -- method BookmarkFile::remove_group -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_remove_group" g_bookmark_file_remove_group :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- group : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileRemoveGroup :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri T.Text -> -- group m () bookmarkFileRemoveGroup _obj uri group = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri group' <- textToCString group onException (do _ <- propagateGError $ g_bookmark_file_remove_group _obj' uri' group' touchManagedPtr _obj freeMem uri' freeMem group' return () ) (do freeMem uri' freeMem group' ) -- method BookmarkFile::remove_item -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_remove_item" g_bookmark_file_remove_item :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileRemoveItem :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri m () bookmarkFileRemoveItem _obj uri = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri onException (do _ <- propagateGError $ g_bookmark_file_remove_item _obj' uri' touchManagedPtr _obj freeMem uri' return () ) (do freeMem uri' ) -- method BookmarkFile::set_added -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "added", argType = TBasicType TInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "added", argType = TBasicType TInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_set_added" g_bookmark_file_set_added :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Int64 -> -- added : TBasicType TInt64 IO () bookmarkFileSetAdded :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri Int64 -> -- added m () bookmarkFileSetAdded _obj uri added = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri g_bookmark_file_set_added _obj' uri' added touchManagedPtr _obj freeMem uri' return () -- method BookmarkFile::set_app_info -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "exec", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "count", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "stamp", argType = TBasicType TInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "exec", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "count", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "stamp", argType = TBasicType TInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_set_app_info" g_bookmark_file_set_app_info :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- name : TBasicType TUTF8 CString -> -- exec : TBasicType TUTF8 Int32 -> -- count : TBasicType TInt32 Int64 -> -- stamp : TBasicType TInt64 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileSetAppInfo :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri T.Text -> -- name T.Text -> -- exec Int32 -> -- count Int64 -> -- stamp m () bookmarkFileSetAppInfo _obj uri name exec count stamp = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri name' <- textToCString name exec' <- textToCString exec onException (do _ <- propagateGError $ g_bookmark_file_set_app_info _obj' uri' name' exec' count stamp touchManagedPtr _obj freeMem uri' freeMem name' freeMem exec' return () ) (do freeMem uri' freeMem name' freeMem exec' ) -- method BookmarkFile::set_description -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "description", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "description", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_set_description" g_bookmark_file_set_description :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- description : TBasicType TUTF8 IO () bookmarkFileSetDescription :: (MonadIO m) => BookmarkFile -> -- _obj Maybe (T.Text) -> -- uri T.Text -> -- description m () bookmarkFileSetDescription _obj uri description = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj maybeUri <- case uri of Nothing -> return nullPtr Just jUri -> do jUri' <- textToCString jUri return jUri' description' <- textToCString description g_bookmark_file_set_description _obj' maybeUri description' touchManagedPtr _obj freeMem maybeUri freeMem description' return () -- method BookmarkFile::set_groups -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "groups", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "groups", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_set_groups" g_bookmark_file_set_groups :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- groups : TBasicType TUTF8 Word64 -> -- length : TBasicType TUInt64 IO () bookmarkFileSetGroups :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri Maybe (T.Text) -> -- groups Word64 -> -- length m () bookmarkFileSetGroups _obj uri groups length_ = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri maybeGroups <- case groups of Nothing -> return nullPtr Just jGroups -> do jGroups' <- textToCString jGroups return jGroups' g_bookmark_file_set_groups _obj' uri' maybeGroups length_ touchManagedPtr _obj freeMem uri' freeMem maybeGroups return () -- method BookmarkFile::set_icon -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "href", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "mime_type", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "href", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "mime_type", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_set_icon" g_bookmark_file_set_icon :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- href : TBasicType TUTF8 CString -> -- mime_type : TBasicType TUTF8 IO () bookmarkFileSetIcon :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri Maybe (T.Text) -> -- href T.Text -> -- mime_type m () bookmarkFileSetIcon _obj uri href mime_type = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri maybeHref <- case href of Nothing -> return nullPtr Just jHref -> do jHref' <- textToCString jHref return jHref' mime_type' <- textToCString mime_type g_bookmark_file_set_icon _obj' uri' maybeHref mime_type' touchManagedPtr _obj freeMem uri' freeMem maybeHref freeMem mime_type' return () -- method BookmarkFile::set_is_private -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "is_private", argType = TBasicType TBoolean, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "is_private", argType = TBasicType TBoolean, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_set_is_private" g_bookmark_file_set_is_private :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CInt -> -- is_private : TBasicType TBoolean IO () bookmarkFileSetIsPrivate :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri Bool -> -- is_private m () bookmarkFileSetIsPrivate _obj uri is_private = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri let is_private' = (fromIntegral . fromEnum) is_private g_bookmark_file_set_is_private _obj' uri' is_private' touchManagedPtr _obj freeMem uri' return () -- method BookmarkFile::set_mime_type -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "mime_type", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "mime_type", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_set_mime_type" g_bookmark_file_set_mime_type :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- mime_type : TBasicType TUTF8 IO () bookmarkFileSetMimeType :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri T.Text -> -- mime_type m () bookmarkFileSetMimeType _obj uri mime_type = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri mime_type' <- textToCString mime_type g_bookmark_file_set_mime_type _obj' uri' mime_type' touchManagedPtr _obj freeMem uri' freeMem mime_type' return () -- method BookmarkFile::set_modified -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "modified", argType = TBasicType TInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "modified", argType = TBasicType TInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_set_modified" g_bookmark_file_set_modified :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Int64 -> -- modified : TBasicType TInt64 IO () bookmarkFileSetModified :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri Int64 -> -- modified m () bookmarkFileSetModified _obj uri modified = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri g_bookmark_file_set_modified _obj' uri' modified touchManagedPtr _obj freeMem uri' return () -- method BookmarkFile::set_title -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "title", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "title", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_set_title" g_bookmark_file_set_title :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 CString -> -- title : TBasicType TUTF8 IO () bookmarkFileSetTitle :: (MonadIO m) => BookmarkFile -> -- _obj Maybe (T.Text) -> -- uri T.Text -> -- title m () bookmarkFileSetTitle _obj uri title = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj maybeUri <- case uri of Nothing -> return nullPtr Just jUri -> do jUri' <- textToCString jUri return jUri' title' <- textToCString title g_bookmark_file_set_title _obj' maybeUri title' touchManagedPtr _obj freeMem maybeUri freeMem title' return () -- method BookmarkFile::set_visited -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "visited", argType = TBasicType TInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "uri", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "visited", argType = TBasicType TInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "g_bookmark_file_set_visited" g_bookmark_file_set_visited :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- uri : TBasicType TUTF8 Int64 -> -- visited : TBasicType TInt64 IO () bookmarkFileSetVisited :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- uri Int64 -> -- visited m () bookmarkFileSetVisited _obj uri visited = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj uri' <- textToCString uri g_bookmark_file_set_visited _obj' uri' visited touchManagedPtr _obj freeMem uri' return () -- method BookmarkFile::to_data -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "length", argType = TBasicType TUInt64, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TUTF8 -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_to_data" g_bookmark_file_to_data :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" Ptr Word64 -> -- length : TBasicType TUInt64 Ptr (Ptr GError) -> -- error IO CString bookmarkFileToData :: (MonadIO m) => BookmarkFile -> -- _obj m (T.Text,Word64) bookmarkFileToData _obj = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj length_ <- allocMem :: IO (Ptr Word64) onException (do result <- propagateGError $ g_bookmark_file_to_data _obj' length_ checkUnexpectedReturnNULL "g_bookmark_file_to_data" result result' <- cstringToText result freeMem result length_' <- peek length_ touchManagedPtr _obj freeMem length_ return (result', length_') ) (do freeMem length_ ) -- method BookmarkFile::to_file -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "filename", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "GLib" "BookmarkFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "filename", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TBoolean -- throws : True -- Skip return : False foreign import ccall "g_bookmark_file_to_file" g_bookmark_file_to_file :: Ptr BookmarkFile -> -- _obj : TInterface "GLib" "BookmarkFile" CString -> -- filename : TBasicType TUTF8 Ptr (Ptr GError) -> -- error IO CInt bookmarkFileToFile :: (MonadIO m) => BookmarkFile -> -- _obj T.Text -> -- filename m () bookmarkFileToFile _obj filename = liftIO $ do let _obj' = unsafeManagedPtrGetPtr _obj filename' <- textToCString filename onException (do _ <- propagateGError $ g_bookmark_file_to_file _obj' filename' touchManagedPtr _obj freeMem filename' return () ) (do freeMem filename' )