RuleSet

@Serializable
data class RuleSet(val id: RuleSetId, val loaderId: LoaderId, val sourceText: String, val backendNodeId: BackendNodeId? = null, val url: String? = null, val requestId: RequestId? = null, val errorType: RuleSetErrorType? = null, val errorMessage: String? = null)(source)

Corresponds to SpeculationRuleSet

Official doc

Constructors

Link copied to clipboard
constructor(id: RuleSetId, loaderId: LoaderId, sourceText: String, backendNodeId: BackendNodeId? = null, url: String? = null, requestId: RequestId? = null, errorType: RuleSetErrorType? = null, errorMessage: String? = null)

Properties

Link copied to clipboard

A speculation rule set is either added through an inline

Link copied to clipboard
val errorMessage: String? = null

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

Link copied to clipboard

Error information errorMessage is null iff errorType is null.

Link copied to clipboard
Link copied to clipboard

Identifies a document which the rule set is associated with.

Link copied to clipboard
val requestId: RequestId? = null
Link copied to clipboard

Source text of JSON representing the rule set. If it comes from

Link copied to clipboard
val url: String? = null