spider

package
Version: v0.0.0-...-760f784 Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2018 License: Apache-2.0 Imports: 5 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindMaxFromSliceString

func FindMaxFromSliceString(min int, sofs []string) int

Find max int value from a slice of string ["1","24"] --> 24

Types

type Spider

type Spider struct {
	Url string // page that spider would deal with
	// contains filtered or unexported fields
}

Spider

func CreateSpiderFromResponse

func CreateSpiderFromResponse(r *http.Response) (*Spider, error)

func CreateSpiderFromUrl

func CreateSpiderFromUrl(url string) (*Spider, error)

Start spider

func (*Spider) GetAttr

func (s *Spider) GetAttr(rule, attr string) ([]string, error)

func (*Spider) GetHtml

func (s *Spider) GetHtml(rule string) ([]string, error)

func (*Spider) GetText

func (s *Spider) GetText(rule string) ([]string, error)

Jump to

Keyboard shortcuts

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