Share via


WebViewWebResourceRequestedEventArgs Class

Definition

Event arguments for the WebResourceRequested event.

public ref class WebViewWebResourceRequestedEventArgs
public class WebViewWebResourceRequestedEventArgs
type WebViewWebResourceRequestedEventArgs = class
Public Class WebViewWebResourceRequestedEventArgs
Inheritance
WebViewWebResourceRequestedEventArgs

Constructors

WebViewWebResourceRequestedEventArgs(PlatformWebViewWebResourceRequestedEventArgs)
WebViewWebResourceRequestedEventArgs(Uri, String)

Initializes a new instance of the WebViewWebResourceRequestedEventArgs class with the specified URI and method.

Properties

Handled

Gets or sets a value indicating whether the request has been handled.

If set to true, the web view will not process the request further and a response must be provided using the SetResponse(Int32, String, IReadOnlyDictionary<String,String>, Stream) or SetResponse(Int32, String, IReadOnlyDictionary<String,String>, Task<Stream>) method. If set to false, the web view will continue processing the request as normal.

Headers

Gets the headers associated with the request.

Method

Gets the HTTP method used for the request (e.g., GET, POST).

PlatformArgs

Gets the platform-specific event arguments.

QueryParameters

Gets the query parameters from the URI.

Uri

Gets the URI of the requested resource.

Methods

SetResponse(Int32, String, IReadOnlyDictionary<String,String>, Stream)

Sets the response for the web resource request.

This method must be called if the Handled property is set to true.

SetResponse(Int32, String, IReadOnlyDictionary<String,String>, Task<Stream>)

Sets the asynchronous response for the web resource request.

This method must be called if the Handled property is set to true.

SetResponse(Int32, String, String, Stream)

Sets the response for the web resource request with a status code, reason, and content type.

SetResponse(Int32, String, String, Task<Stream>)

Sets the response for the web resource request with a status code, reason, and content type.

SetResponse(Int32, String)

Sets the response for the web resource request with a status code and reason.

Applies to