MCPcopy
hub / github.com/PuerkitoBio/goquery / compileMatcher

Function compileMatcher

type.go:166–172  ·  view source on GitHub ↗

compileMatcher compiles the selector string s and returns the corresponding Matcher. If s is an invalid selector string, it returns a Matcher that fails all matches.

(s string)

Source from the content-addressed store, hash-verified

164// the corresponding Matcher. If s is an invalid selector string,
165// it returns a Matcher that fails all matches.
166func compileMatcher(s string) Matcher {
167 cs, err := cascadia.Compile(s)
168 if err != nil {
169 return invalidMatcher{}
170 }
171 return cs
172}
173
174type singleMatcher struct {
175 Matcher

Callers 15

FilterMethod · 0.85
NotMethod · 0.85
IsMethod · 0.85
AfterMethod · 0.85
AppendMethod · 0.85
BeforeMethod · 0.85
PrependMethod · 0.85
RemoveFilteredMethod · 0.85
ReplaceWithMethod · 0.85
WrapMethod · 0.85
WrapAllMethod · 0.85
WrapInnerMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…