client

package
v0.1.0-alpha Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Search(param *SearchParam) (*[]SearchResult, error)

func SearchWithOption

func SearchWithOption(param *SearchParam, opt *ClientOption) (*[]SearchResult, error)

Types

type ClientOption

type ClientOption struct {
	Referrer  string
	UserAgent string
	Timeout   time.Duration
}

func NewClientOption

func NewClientOption(referrer, userAgent string, timeout time.Duration) *ClientOption

type SearchParam

type SearchParam struct {
	Query string
}

func NewSearchParam

func NewSearchParam(query string) (*SearchParam, error)

type SearchResult

type SearchResult struct {
	Title   string
	Link    string
	Snippet string
}

Jump to

Keyboard shortcuts

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