module GI.WebKit.Objects.DOMHTMLPropertiesCollection
(
DOMHTMLPropertiesCollection(..) ,
IsDOMHTMLPropertiesCollection ,
toDOMHTMLPropertiesCollection ,
noDOMHTMLPropertiesCollection ,
dOMHTMLPropertiesCollectionGetLength ,
dOMHTMLPropertiesCollectionGetNames ,
dOMHTMLPropertiesCollectionItem ,
dOMHTMLPropertiesCollectionNamedItem ,
DOMHTMLPropertiesCollectionLengthPropertyInfo,
dOMHTMLPropertiesCollectionLength ,
getDOMHTMLPropertiesCollectionLength ,
DOMHTMLPropertiesCollectionNamesPropertyInfo,
dOMHTMLPropertiesCollectionNames ,
getDOMHTMLPropertiesCollectionNames ,
) 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.ManagedPtr as B.ManagedPtr
import qualified Data.GI.Base.GError as B.GError
import qualified Data.GI.Base.GVariant as B.GVariant
import qualified Data.GI.Base.GParamSpec as B.GParamSpec
import qualified Data.GI.Base.CallStack as B.CallStack
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 GI.GObject.Objects.Object as GObject.Object
import qualified GI.WebKit.Objects.DOMDOMStringList as WebKit.DOMDOMStringList
import qualified GI.WebKit.Objects.DOMHTMLCollection as WebKit.DOMHTMLCollection
import qualified GI.WebKit.Objects.DOMNode as WebKit.DOMNode
import qualified GI.WebKit.Objects.DOMObject as WebKit.DOMObject
newtype DOMHTMLPropertiesCollection = DOMHTMLPropertiesCollection (ManagedPtr DOMHTMLPropertiesCollection)
foreign import ccall "webkit_dom_html_properties_collection_get_type"
c_webkit_dom_html_properties_collection_get_type :: IO GType
instance GObject DOMHTMLPropertiesCollection where
gobjectType _ = c_webkit_dom_html_properties_collection_get_type
class GObject o => IsDOMHTMLPropertiesCollection o
#if MIN_VERSION_base(4,9,0)
instance (GObject a, O.UnknownAncestorError DOMHTMLPropertiesCollection a) =>
IsDOMHTMLPropertiesCollection a
#endif
instance IsDOMHTMLPropertiesCollection DOMHTMLPropertiesCollection
instance WebKit.DOMHTMLCollection.IsDOMHTMLCollection DOMHTMLPropertiesCollection
instance WebKit.DOMObject.IsDOMObject DOMHTMLPropertiesCollection
instance GObject.Object.IsObject DOMHTMLPropertiesCollection
toDOMHTMLPropertiesCollection :: IsDOMHTMLPropertiesCollection o => o -> IO DOMHTMLPropertiesCollection
toDOMHTMLPropertiesCollection = unsafeCastTo DOMHTMLPropertiesCollection
noDOMHTMLPropertiesCollection :: Maybe DOMHTMLPropertiesCollection
noDOMHTMLPropertiesCollection = Nothing
type family ResolveDOMHTMLPropertiesCollectionMethod (t :: Symbol) (o :: *) :: * where
ResolveDOMHTMLPropertiesCollectionMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "ref" o = GObject.Object.ObjectRefMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "replaceData" o = GObject.Object.ObjectReplaceDataMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "replaceQdata" o = GObject.Object.ObjectReplaceQdataMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo
ResolveDOMHTMLPropertiesCollectionMethod l o = O.MethodResolutionFailed l o
instance (info ~ ResolveDOMHTMLPropertiesCollectionMethod t DOMHTMLPropertiesCollection, O.MethodInfo info DOMHTMLPropertiesCollection p) => O.IsLabelProxy t (DOMHTMLPropertiesCollection -> p) where
fromLabelProxy _ = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info)
#if MIN_VERSION_base(4,9,0)
instance (info ~ ResolveDOMHTMLPropertiesCollectionMethod t DOMHTMLPropertiesCollection, O.MethodInfo info DOMHTMLPropertiesCollection p) => O.IsLabel t (DOMHTMLPropertiesCollection -> p) where
fromLabel _ = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info)
#endif
getDOMHTMLPropertiesCollectionLength :: (MonadIO m, IsDOMHTMLPropertiesCollection o) => o -> m CULong
getDOMHTMLPropertiesCollectionLength obj = liftIO $ getObjectPropertyULong obj "length"
data DOMHTMLPropertiesCollectionLengthPropertyInfo
instance AttrInfo DOMHTMLPropertiesCollectionLengthPropertyInfo where
type AttrAllowedOps DOMHTMLPropertiesCollectionLengthPropertyInfo = '[ 'AttrGet]
type AttrSetTypeConstraint DOMHTMLPropertiesCollectionLengthPropertyInfo = (~) ()
type AttrBaseTypeConstraint DOMHTMLPropertiesCollectionLengthPropertyInfo = IsDOMHTMLPropertiesCollection
type AttrGetType DOMHTMLPropertiesCollectionLengthPropertyInfo = CULong
type AttrLabel DOMHTMLPropertiesCollectionLengthPropertyInfo = "length"
type AttrOrigin DOMHTMLPropertiesCollectionLengthPropertyInfo = DOMHTMLPropertiesCollection
attrGet _ = getDOMHTMLPropertiesCollectionLength
attrSet _ = undefined
attrConstruct _ = undefined
attrClear _ = undefined
getDOMHTMLPropertiesCollectionNames :: (MonadIO m, IsDOMHTMLPropertiesCollection o) => o -> m (Maybe WebKit.DOMDOMStringList.DOMDOMStringList)
getDOMHTMLPropertiesCollectionNames obj = liftIO $ getObjectPropertyObject obj "names" WebKit.DOMDOMStringList.DOMDOMStringList
data DOMHTMLPropertiesCollectionNamesPropertyInfo
instance AttrInfo DOMHTMLPropertiesCollectionNamesPropertyInfo where
type AttrAllowedOps DOMHTMLPropertiesCollectionNamesPropertyInfo = '[ 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint DOMHTMLPropertiesCollectionNamesPropertyInfo = (~) ()
type AttrBaseTypeConstraint DOMHTMLPropertiesCollectionNamesPropertyInfo = IsDOMHTMLPropertiesCollection
type AttrGetType DOMHTMLPropertiesCollectionNamesPropertyInfo = (Maybe WebKit.DOMDOMStringList.DOMDOMStringList)
type AttrLabel DOMHTMLPropertiesCollectionNamesPropertyInfo = "names"
type AttrOrigin DOMHTMLPropertiesCollectionNamesPropertyInfo = DOMHTMLPropertiesCollection
attrGet _ = getDOMHTMLPropertiesCollectionNames
attrSet _ = undefined
attrConstruct _ = undefined
attrClear _ = undefined
instance O.HasAttributeList DOMHTMLPropertiesCollection
type instance O.AttributeList DOMHTMLPropertiesCollection = DOMHTMLPropertiesCollectionAttributeList
type DOMHTMLPropertiesCollectionAttributeList = ('[ '("coreObject", WebKit.DOMObject.DOMObjectCoreObjectPropertyInfo), '("length", DOMHTMLPropertiesCollectionLengthPropertyInfo), '("names", DOMHTMLPropertiesCollectionNamesPropertyInfo)] :: [(Symbol, *)])
dOMHTMLPropertiesCollectionLength :: AttrLabelProxy "length"
dOMHTMLPropertiesCollectionLength = AttrLabelProxy
dOMHTMLPropertiesCollectionNames :: AttrLabelProxy "names"
dOMHTMLPropertiesCollectionNames = AttrLabelProxy
type instance O.SignalList DOMHTMLPropertiesCollection = DOMHTMLPropertiesCollectionSignalList
type DOMHTMLPropertiesCollectionSignalList = ('[ '("notify", GObject.Object.ObjectNotifySignalInfo)] :: [(Symbol, *)])
foreign import ccall "webkit_dom_html_properties_collection_get_length" webkit_dom_html_properties_collection_get_length ::
Ptr () ->
IO CULong
dOMHTMLPropertiesCollectionGetLength ::
(B.CallStack.HasCallStack, MonadIO m) =>
Ptr ()
-> m CULong
dOMHTMLPropertiesCollectionGetLength self = liftIO $ do
result <- webkit_dom_html_properties_collection_get_length self
return result
foreign import ccall "webkit_dom_html_properties_collection_get_names" webkit_dom_html_properties_collection_get_names ::
Ptr () ->
IO (Ptr WebKit.DOMDOMStringList.DOMDOMStringList)
dOMHTMLPropertiesCollectionGetNames ::
(B.CallStack.HasCallStack, MonadIO m) =>
Ptr ()
-> m WebKit.DOMDOMStringList.DOMDOMStringList
dOMHTMLPropertiesCollectionGetNames self = liftIO $ do
result <- webkit_dom_html_properties_collection_get_names self
checkUnexpectedReturnNULL "dOMHTMLPropertiesCollectionGetNames" result
result' <- (newObject WebKit.DOMDOMStringList.DOMDOMStringList) result
return result'
foreign import ccall "webkit_dom_html_properties_collection_item" webkit_dom_html_properties_collection_item ::
Ptr () ->
CULong ->
IO (Ptr WebKit.DOMNode.DOMNode)
dOMHTMLPropertiesCollectionItem ::
(B.CallStack.HasCallStack, MonadIO m) =>
Ptr ()
-> CULong
-> m WebKit.DOMNode.DOMNode
dOMHTMLPropertiesCollectionItem self index = liftIO $ do
result <- webkit_dom_html_properties_collection_item self index
checkUnexpectedReturnNULL "dOMHTMLPropertiesCollectionItem" result
result' <- (newObject WebKit.DOMNode.DOMNode) result
return result'
foreign import ccall "webkit_dom_html_properties_collection_named_item" webkit_dom_html_properties_collection_named_item ::
Ptr () ->
CString ->
IO (Ptr ())
dOMHTMLPropertiesCollectionNamedItem ::
(B.CallStack.HasCallStack, MonadIO m) =>
Ptr ()
-> T.Text
-> m (Ptr ())
dOMHTMLPropertiesCollectionNamedItem self name = liftIO $ do
name' <- textToCString name
result <- webkit_dom_html_properties_collection_named_item self name'
freeMem name'
return result