webkit.web_extension_match_pattern

Module for [WebExtensionMatchPattern] class

Types 1

Represents a way to specify a group of URLs for use in WebExtensions.

All match patterns are specified as strings. Apart from the special <all_urls> pattern, match patterns consist of three parts: scheme, host, and path.

Generally, match patterns are returned from a #WebKitWebExtension.

Methods
void * _cPtr(Flag!"Dup" dup = No.Dup)
GType _gType() @property
WebExtensionMatchPattern self()Returns `this`, for use in `with` statements.
webkit.web_extension_match_pattern.WebExtensionMatchPattern newAllHostsAndSchemes()Returns a new #WebKitWebExtensionMatchPattern that has `*` for scheme, host, and path. Returns: a newly created #WebKitWebExtensionMatchPattern
webkit.web_extension_match_pattern.WebExtensionMatchPattern newAllUrls()Returns a new #WebKitWebExtensionMatchPattern for `<all_urls>`. Returns: a newly created #WebKitWebExtensionMatchPattern
webkit.web_extension_match_pattern.WebExtensionMatchPattern newWithScheme(string scheme, string host, string path)Returns a new #WebKitWebExtensionMatchPattern for the specified scheme, host, and path strings.
webkit.web_extension_match_pattern.WebExtensionMatchPattern newWithString(string string_)Returns a new #WebKitWebExtensionMatchPattern for the specified string.
string getHost()Gets the host part of the pattern string, unless [webkit.webextensionmatch_pattern.WebExtensionMatchPattern.getMatchesAllUrls] is true. Returns: The host string.
bool getMatchesAllHosts()Gets whether the match pattern matches all host. This happens when the pattern is `<all_urls>`, or if `*` is set as the host string. Returns: Whether this match pattern matches all hosts.
bool getMatchesAllUrls()Gets whether the match pattern matches all URLs, in other words, whether the pattern is `<all_urls>`. Returns: Whether this match pattern matches all URLs.
string getPath()Gets the path part of the pattern string, unless [webkit.webextensionmatch_pattern.WebExtensionMatchPattern.getMatchesAllUrls] is true. Returns: The path string.
string getScheme()Gets the scheme part of the pattern string, unless [webkit.webextensionmatch_pattern.WebExtensionMatchPattern.getMatchesAllUrls] is true. Returns: The scheme string.
string getString()Gets the original pattern string. Returns: The original pattern string.
bool matchesPattern(webkit.web_extension_match_pattern.WebExtensionMatchPattern pattern, webkit.types.WebExtensionMatchPatternOptions options)Matches the matchPattern against the specified pattern with options.
bool matchesUrl(string url, webkit.types.WebExtensionMatchPatternOptions options)Matches the matchPattern against the specified URL with options.
void registerCustomURLScheme(string urlScheme)Registers a custom URL scheme that can be used in match patterns.
Constructors
this(void * ptr, Flag!"Take" take)