bing

package
v0.5.4 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildImageURL

func BuildImageURL(q core.Query) (string, error)

func BuildURL

func BuildURL(q core.Query) (string, error)

Types

type Bing

type Bing struct {
	core.Browser
	core.SearchEngineOptions
	// contains filtered or unexported fields
}

func New

func New(browser core.Browser, opts core.SearchEngineOptions) *Bing

func (*Bing) GetRateLimiter

func (bing *Bing) GetRateLimiter() *rate.Limiter

func (*Bing) Name

func (bing *Bing) Name() string

func (*Bing) Search

func (bing *Bing) Search(query core.Query) ([]core.SearchResult, error)

func (*Bing) SearchImage

func (bing *Bing) SearchImage(query core.Query) ([]core.SearchResult, error)

SearchImage performs Bing image search and returns results

type BingImageData

type BingImageData struct {
	T      string `json:"t"`      // Title
	Desc   string `json:"desc"`   // Description
	IMGURL string `json:"imgurl"` // Original image URL
	W      int    `json:"w"`      // Width
	H      int    `json:"h"`      // Height
	PURL   string `json:"purl"`   // Page URL
	TURL   string `json:"turl"`   // Thumbnail URL
	MURL   string `json:"murl"`   // Image URL
}

BingImageData represents the JSON structure in the m attribute of image elements

Jump to

Keyboard shortcuts

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