Documentation
¶
Index ¶
- func AllFn(okRes bool, filters ...func(*html.Node) bool) func(*html.Node) bool
- func AnyFn(okRes bool, filters ...func(*html.Node) bool) func(*html.Node) bool
- func Attr(n *html.Node, key string) (string, bool)
- func Children(n *html.Node, filter func(*html.Node) bool) []*html.Node
- func Find(n *html.Node, filter func(*html.Node) bool) *html.Node
- func JoinData(n ...*html.Node) string
- func Traverse(n *html.Node, check func(*html.Node) bool, nodes []*html.Node) []*html.Node
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AllFn ¶
AllFn gets a slice of filters and returns new filter func. This function calls each filter from the slice with given *html.Node and returns okRes if all filters return true otherwise this function returns !okRes.
func AnyFn ¶
AnyFn gets a slice of filters and returns new func. This function calls each filter from the slice with given *html.Node and returns okRes if any call of filter returns true. If all filters returns false this function returns !okRes.
func Children ¶
Children returns slice of nodes where each node is a child of given node and filter function returns true for corresponding child node.
func Find ¶
Find walks through tree of nodes and call filter function for each one and returns node if filter returns true.
Types ¶
This section is empty.