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

Method IsSelection

query.go:32–34  ·  view source on GitHub ↗

IsSelection checks the current matched set of elements against a Selection object and returns true if at least one of these elements matches.

(sel *Selection)

Source from the content-addressed store, hash-verified

30// IsSelection checks the current matched set of elements against a Selection object
31// and returns true if at least one of these elements matches.
32func (s *Selection) IsSelection(sel *Selection) bool {
33 return s.FilterSelection(sel).Length() > 0
34}
35
36// IsNodes checks the current matched set of elements against the specified nodes
37// and returns true if at least one of these elements matches.

Callers 3

BenchmarkIsSelectionFunction · 0.80
TestIsSelectionFunction · 0.80
TestIsSelectionNotFunction · 0.80

Calls 2

FilterSelectionMethod · 0.95
LengthMethod · 0.80

Tested by 3

BenchmarkIsSelectionFunction · 0.64
TestIsSelectionFunction · 0.64
TestIsSelectionNotFunction · 0.64