scraper

package
Version: v0.0.0-...-866a79a Latest Latest
Warning

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

Go to latest
Published: Jun 13, 2019 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// AZBaseURL is the URL used to retrieve the lyrics of a song.
	AZBaseURL = "https://www.azlyrics.com"

	// AZSearchURL is the URL used to search for a song.
	AZSearchURL = "https://search.azlyrics.com"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AZLyrics

type AZLyrics struct {
	Collector *colly.Collector
	Prompt    *prompt.Prompt
	Lyrics    string
}

AZLyrics is the scraper struct for AZLyrics.

func New

func New() *AZLyrics

New instantiates a new AZLyrics and returns a pointer to it.

func (*AZLyrics) SearchSongLyrics

func (a *AZLyrics) SearchSongLyrics()

SearchSongLyrics starts a new lyrics search with a prompt.

func (*AZLyrics) SearchSongURL

func (a *AZLyrics) SearchSongURL()

SearchSongURL is the advanced search for a song in case there is no match found by SearchSongLyrics.

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto