Copyright | Will Thompson and Iñaki García Etxebarria |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
A policy decision for resource responses.
WebKitResponsePolicyDecision represents a policy decision for a resource response, whether from the network or the local system. A very common use case for these types of decision is deciding whether or not to download a particular resource or to load it normally.
Synopsis
- newtype ResponsePolicyDecision = ResponsePolicyDecision (ManagedPtr ResponsePolicyDecision)
- class (GObject o, IsDescendantOf ResponsePolicyDecision o) => IsResponsePolicyDecision o
- toResponsePolicyDecision :: (MonadIO m, IsResponsePolicyDecision o) => o -> m ResponsePolicyDecision
- responsePolicyDecisionGetRequest :: (HasCallStack, MonadIO m, IsResponsePolicyDecision a) => a -> m URIRequest
- responsePolicyDecisionGetResponse :: (HasCallStack, MonadIO m, IsResponsePolicyDecision a) => a -> m URIResponse
- responsePolicyDecisionIsMainFrameMainResource :: (HasCallStack, MonadIO m, IsResponsePolicyDecision a) => a -> m Bool
- responsePolicyDecisionIsMimeTypeSupported :: (HasCallStack, MonadIO m, IsResponsePolicyDecision a) => a -> m Bool
- getResponsePolicyDecisionRequest :: (MonadIO m, IsResponsePolicyDecision o) => o -> m URIRequest
- getResponsePolicyDecisionResponse :: (MonadIO m, IsResponsePolicyDecision o) => o -> m URIResponse
Exported types
newtype ResponsePolicyDecision Source #
Memory-managed wrapper type.
ResponsePolicyDecision (ManagedPtr ResponsePolicyDecision) |
Instances
Eq ResponsePolicyDecision Source # | |
Defined in GI.WebKit.Objects.ResponsePolicyDecision | |
GObject ResponsePolicyDecision Source # | |
Defined in GI.WebKit.Objects.ResponsePolicyDecision | |
ManagedPtrNewtype ResponsePolicyDecision Source # | |
Defined in GI.WebKit.Objects.ResponsePolicyDecision toManagedPtr :: ResponsePolicyDecision -> ManagedPtr ResponsePolicyDecision | |
TypedObject ResponsePolicyDecision Source # | |
Defined in GI.WebKit.Objects.ResponsePolicyDecision | |
HasParentTypes ResponsePolicyDecision Source # | |
Defined in GI.WebKit.Objects.ResponsePolicyDecision | |
IsGValue (Maybe ResponsePolicyDecision) Source # | Convert |
Defined in GI.WebKit.Objects.ResponsePolicyDecision gvalueGType_ :: IO GType gvalueSet_ :: Ptr GValue -> Maybe ResponsePolicyDecision -> IO () gvalueGet_ :: Ptr GValue -> IO (Maybe ResponsePolicyDecision) | |
type ParentTypes ResponsePolicyDecision Source # | |
Defined in GI.WebKit.Objects.ResponsePolicyDecision |
class (GObject o, IsDescendantOf ResponsePolicyDecision o) => IsResponsePolicyDecision o Source #
Type class for types which can be safely cast to ResponsePolicyDecision
, for instance with toResponsePolicyDecision
.
Instances
(GObject o, IsDescendantOf ResponsePolicyDecision o) => IsResponsePolicyDecision o Source # | |
Defined in GI.WebKit.Objects.ResponsePolicyDecision |
toResponsePolicyDecision :: (MonadIO m, IsResponsePolicyDecision o) => o -> m ResponsePolicyDecision Source #
Cast to ResponsePolicyDecision
, for types for which this is known to be safe. For general casts, use castTo
.
Methods
Click to display all available methods, including inherited ones
Methods
bindProperty, bindPropertyFull, download, forceFloating, freezeNotify, getv, ignore, isFloating, isMainFrameMainResource, isMimeTypeSupported, notify, notifyByPspec, ref, refSink, runDispose, stealData, stealQdata, thawNotify, unref, use, useWithPolicies, watchClosure.
Getters
getData, getProperty, getQdata, getRequest, getResponse.
Setters
getRequest
responsePolicyDecisionGetRequest Source #
:: (HasCallStack, MonadIO m, IsResponsePolicyDecision a) | |
=> a |
|
-> m URIRequest | Returns: The URI request that is associated with this policy decision. |
Return the URIRequest
associated with the response decision.
Modifications to the returned object are <emphasis>not</emphasis> taken
into account when the request is sent over the network, and is intended
only to aid in evaluating whether a response decision should be taken or
not. To modify requests before they are sent over the network the
WebKitPage::send-request
signal can be used instead.
getResponse
responsePolicyDecisionGetResponse Source #
:: (HasCallStack, MonadIO m, IsResponsePolicyDecision a) | |
=> a |
|
-> m URIResponse | Returns: The URI response that is associated with this policy decision. |
Gets the value of the ResponsePolicyDecision:response property.
isMainFrameMainResource
responsePolicyDecisionIsMainFrameMainResource Source #
:: (HasCallStack, MonadIO m, IsResponsePolicyDecision a) | |
=> a |
|
-> m Bool | Returns: |
Gets whether the request is the main frame main resource
Since: 2.40
isMimeTypeSupported
responsePolicyDecisionIsMimeTypeSupported Source #
:: (HasCallStack, MonadIO m, IsResponsePolicyDecision a) | |
=> a |
|
-> m Bool | Returns: |
Gets whether the MIME type of the response can be displayed in the WebView
.
Gets whether the MIME type of the response can be displayed in the WebView
that triggered this policy decision request. See also webViewCanShowMimeType
.
Since: 2.4
Properties
request
This property contains the URIRequest
associated with this
policy decision.
getResponsePolicyDecisionRequest :: (MonadIO m, IsResponsePolicyDecision o) => o -> m URIRequest Source #
Get the value of the “request
” property.
When overloading is enabled, this is equivalent to
get
responsePolicyDecision #request
response
This property contains the URIResponse
associated with this
policy decision.
getResponsePolicyDecisionResponse :: (MonadIO m, IsResponsePolicyDecision o) => o -> m URIResponse Source #
Get the value of the “response
” property.
When overloading is enabled, this is equivalent to
get
responsePolicyDecision #response