Table of Contents

Class RuleSet

Namespace
Selenium.WebDriver.BiDi.Cdp.Preload
Assembly
Selenium.WebDriver.BiDi.Cdp.dll

Corresponds to SpeculationRuleSet

public sealed record RuleSet : IEquatable<RuleSet>
Inheritance
RuleSet
Implements
Inherited Members

Constructors

RuleSet(RuleSetId, LoaderId, string)

Corresponds to SpeculationRuleSet

public RuleSet(RuleSetId Id, LoaderId LoaderId, string SourceText)

Parameters

Id RuleSetId
LoaderId LoaderId

Identifies a document which the rule set is associated with.

SourceText string

Source text of JSON representing the rule set. If it comes from <script> tag, it is the textContent of the node. Note that it is a JSON for valid case.

See also:

Properties

BackendNodeId

A speculation rule set is either added through an inline <script> tag or through an external resource via the 'Speculation-Rules' HTTP header. For the first case, we include the BackendNodeId of the relevant <script> tag. For the second case, we include the external URL where the rule set was loaded from, and also RequestId if Network domain is enabled.

See also:

public BackendNodeId? BackendNodeId { get; init; }

Property Value

BackendNodeId

ErrorMessage

TODO(https://crbug.com/1425354): Replace this property with structured error.

[Obsolete]
public string? ErrorMessage { get; init; }

Property Value

string

ErrorType

Error information errorMessage is null iff errorType is null.

public RuleSetErrorType? ErrorType { get; init; }

Property Value

RuleSetErrorType?

Id

public RuleSetId Id { get; init; }

Property Value

RuleSetId

LoaderId

Identifies a document which the rule set is associated with.

public LoaderId LoaderId { get; init; }

Property Value

LoaderId

RequestId

public RequestId? RequestId { get; init; }

Property Value

RequestId

SourceText

Source text of JSON representing the rule set. If it comes from <script> tag, it is the textContent of the node. Note that it is a JSON for valid case.

See also:

public string SourceText { get; init; }

Property Value

string

Tag

public string? Tag { get; init; }

Property Value

string

Url

public string? Url { get; init; }

Property Value

string