gi-webkit-0.2.4.12: GI/WebKit/Objects/DOMPerformanceEntryList.hs
{- |
Copyright : Will Thompson, Iñaki García Etxebarria and Jonas Platte
License : LGPL-2.1
Maintainer : Iñaki García Etxebarria (garetxe@gmail.com)
-}
module GI.WebKit.Objects.DOMPerformanceEntryList
(
-- * Exported types
DOMPerformanceEntryList(..) ,
DOMPerformanceEntryListK ,
toDOMPerformanceEntryList ,
noDOMPerformanceEntryList ,
-- * Methods
-- ** dOMPerformanceEntryListGetLength
dOMPerformanceEntryListGetLength ,
-- ** dOMPerformanceEntryListItem
dOMPerformanceEntryListItem ,
-- * Properties
-- ** Length
DOMPerformanceEntryListLengthPropertyInfo,
getDOMPerformanceEntryListLength ,
) 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.WebKit.Types
import GI.WebKit.Callbacks
import qualified GI.GObject as GObject
newtype DOMPerformanceEntryList = DOMPerformanceEntryList (ForeignPtr DOMPerformanceEntryList)
foreign import ccall "webkit_dom_performance_entry_list_get_type"
c_webkit_dom_performance_entry_list_get_type :: IO GType
type instance ParentTypes DOMPerformanceEntryList = DOMPerformanceEntryListParentTypes
type DOMPerformanceEntryListParentTypes = '[DOMObject, GObject.Object]
instance GObject DOMPerformanceEntryList where
gobjectIsInitiallyUnowned _ = False
gobjectType _ = c_webkit_dom_performance_entry_list_get_type
class GObject o => DOMPerformanceEntryListK o
instance (GObject o, IsDescendantOf DOMPerformanceEntryList o) => DOMPerformanceEntryListK o
toDOMPerformanceEntryList :: DOMPerformanceEntryListK o => o -> IO DOMPerformanceEntryList
toDOMPerformanceEntryList = unsafeCastTo DOMPerformanceEntryList
noDOMPerformanceEntryList :: Maybe DOMPerformanceEntryList
noDOMPerformanceEntryList = Nothing
-- VVV Prop "length"
-- Type: TBasicType TUInt64
-- Flags: [PropertyReadable]
getDOMPerformanceEntryListLength :: (MonadIO m, DOMPerformanceEntryListK o) => o -> m Word64
getDOMPerformanceEntryListLength obj = liftIO $ getObjectPropertyUInt64 obj "length"
data DOMPerformanceEntryListLengthPropertyInfo
instance AttrInfo DOMPerformanceEntryListLengthPropertyInfo where
type AttrAllowedOps DOMPerformanceEntryListLengthPropertyInfo = '[ 'AttrGet]
type AttrSetTypeConstraint DOMPerformanceEntryListLengthPropertyInfo = (~) ()
type AttrBaseTypeConstraint DOMPerformanceEntryListLengthPropertyInfo = DOMPerformanceEntryListK
type AttrGetType DOMPerformanceEntryListLengthPropertyInfo = Word64
type AttrLabel DOMPerformanceEntryListLengthPropertyInfo = "DOMPerformanceEntryList::length"
attrGet _ = getDOMPerformanceEntryListLength
attrSet _ = undefined
attrConstruct _ = undefined
type instance AttributeList DOMPerformanceEntryList = DOMPerformanceEntryListAttributeList
type DOMPerformanceEntryListAttributeList = ('[ '("core-object", DOMObjectCoreObjectPropertyInfo), '("length", DOMPerformanceEntryListLengthPropertyInfo)] :: [(Symbol, *)])
type instance SignalList DOMPerformanceEntryList = DOMPerformanceEntryListSignalList
type DOMPerformanceEntryListSignalList = ('[ '("notify", GObject.ObjectNotifySignalInfo), '("notify::[property]", GObjectNotifySignalInfo)] :: [(Symbol, *)])
-- method DOMPerformanceEntryList::get_length
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "WebKit" "DOMPerformanceEntryList", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "WebKit" "DOMPerformanceEntryList", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TUInt64
-- throws : False
-- Skip return : False
foreign import ccall "webkit_dom_performance_entry_list_get_length" webkit_dom_performance_entry_list_get_length ::
Ptr DOMPerformanceEntryList -> -- _obj : TInterface "WebKit" "DOMPerformanceEntryList"
IO Word64
dOMPerformanceEntryListGetLength ::
(MonadIO m, DOMPerformanceEntryListK a) =>
a -> -- _obj
m Word64
dOMPerformanceEntryListGetLength _obj = liftIO $ do
let _obj' = unsafeManagedPtrCastPtr _obj
result <- webkit_dom_performance_entry_list_get_length _obj'
touchManagedPtr _obj
return result
-- method DOMPerformanceEntryList::item
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "WebKit" "DOMPerformanceEntryList", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "index", argType = TBasicType TUInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "WebKit" "DOMPerformanceEntryList", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "index", argType = TBasicType TUInt64, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "WebKit" "DOMPerformanceEntry"
-- throws : False
-- Skip return : False
foreign import ccall "webkit_dom_performance_entry_list_item" webkit_dom_performance_entry_list_item ::
Ptr DOMPerformanceEntryList -> -- _obj : TInterface "WebKit" "DOMPerformanceEntryList"
Word64 -> -- index : TBasicType TUInt64
IO (Ptr DOMPerformanceEntry)
dOMPerformanceEntryListItem ::
(MonadIO m, DOMPerformanceEntryListK a) =>
a -> -- _obj
Word64 -> -- index
m DOMPerformanceEntry
dOMPerformanceEntryListItem _obj index = liftIO $ do
let _obj' = unsafeManagedPtrCastPtr _obj
result <- webkit_dom_performance_entry_list_item _obj' index
checkUnexpectedReturnNULL "webkit_dom_performance_entry_list_item" result
result' <- (wrapObject DOMPerformanceEntry) result
touchManagedPtr _obj
return result'