crawler

package
v0.0.0-...-395d2ec Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2017 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Crawler

type Crawler struct {
	SeedRawURL string
	SeedURL    *url.URL
	// contains filtered or unexported fields
}

Crawler struct

func New

func New(u string) (*Crawler, error)

New Crawler instance

func (*Crawler) Run

func (c *Crawler) Run()

Run starts crawlering the URL

type LinkMetadata

type LinkMetadata struct {
	Domain             string `json:"domain"`
	TLD                string `json:"tld"`
	OriginalURL        string `json:"original_url"`
	OriginalURLHash    string `json:"original_url_hash"`
	Redirects          bool   `json:"redirects"`
	DestinationURL     string `json:"destination_url"`
	DestinationURLHash string `json:"destination_url_hash"`
}

LinkMetadata of each link

type Links struct {
	Links []LinkMetadata `json:"links"`
	Count int            `json:"count"`
	Page  string         `json:"page"`
}

Links of each link

Jump to

Keyboard shortcuts

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