scraper

package
v0.0.0-...-13999d3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 28, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Scraper

type Scraper struct {
	MaximumParallel   int
	RecursionMaxDepth int
	OutputFilePath    string
	// contains filtered or unexported fields
}

func NewScraper

func NewScraper(parallel, maxDepth int, outputFile string) *Scraper

func (*Scraper) Scrape

func (s *Scraper) Scrape(ctx context.Context, document *html.Node) (urls []*url.URL, err error)

Scrape will scrape the given document and return all the urls found

type ScraperService

type ScraperService interface {
	Scrape(ctx context.Context, document *html.Node) (urls []*url.URL, err error)
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL