Class RuleSet


  • public class RuleSet
    extends java.lang.Object
    Corresponds to SpeculationRuleSet
    • Constructor Summary

      Constructors 
      Constructor Description
      RuleSet​(RuleSetId id, LoaderId loaderId, java.lang.String sourceText)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      RuleSetId getId()  
      LoaderId getLoaderId()
      Identifies a document which the rule set is associated with.
      java.lang.String getSourceText()
      Source text of JSON representing the rule set.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RuleSet

        public RuleSet​(RuleSetId id,
                       LoaderId loaderId,
                       java.lang.String sourceText)
    • Method Detail

      • getLoaderId

        public LoaderId getLoaderId()
        Identifies a document which the rule set is associated with.
      • getSourceText

        public java.lang.String getSourceText()
        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: - https://wicg.github.io/nav-speculation/speculation-rules.html - https://github.com/WICG/nav-speculation/blob/main/triggers.md