sites

package
v0.14.1 Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2019 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var SupportedSites = []string{
	"www.comicextra.com",
	"mangarock.com",
	"www.mangareader.net",
	"www.mangatown.com",
	"www.mangahere.cc",
}

SupportedSites are the supported sites.

Functions

func GetInfo added in v0.12.3

func GetInfo(b BaseSite, url string) (string, string)

func Initialize added in v0.12.3

func Initialize(b BaseSite, comic *core.Comic) error

func LoadComicFromSource added in v0.9.1

func LoadComicFromSource(source, url, country, format string, all, last bool) ([]*core.Comic, error)

LoadComicFromSource will return a `comic` instance initialized based on the source

func RetrieveIssueLinks(b BaseSite, url string, all, last bool) ([]string, error)

Types

type BaseSite added in v0.12.3

type BaseSite interface {
	// Initialize will initialize the comic struct with the images link
	Initialize(comic *core.Comic) error

	// GetInfo will return the comic name and issue number
	GetInfo(url string) (string, string)

	// RetrieveIssueLinks will return the images links of a comic
	RetrieveIssueLinks(url string, all, last bool) ([]string, error)
}

BaseSite specifies an implementation of a Site which allows you to retrieve a manga/comic basics info and imges links

type Comicextra added in v0.12.3

type Comicextra struct{}

func (*Comicextra) GetInfo added in v0.12.3

func (c *Comicextra) GetInfo(url string) (string, string)

func (*Comicextra) Initialize added in v0.12.3

func (c *Comicextra) Initialize(comic *core.Comic) error

Initialize will initialize the comic based on comicextra.com

func (c *Comicextra) RetrieveIssueLinks(url string, all, last bool) ([]string, error)

RetrieveIssueLinks gets a slice of urls for all issues in a comic

type Mangareader added in v0.12.3

type Mangareader struct{}

func (*Mangareader) GetInfo added in v0.12.3

func (m *Mangareader) GetInfo(url string) (string, string)

func (*Mangareader) Initialize added in v0.12.3

func (m *Mangareader) Initialize(comic *core.Comic) error

Initialize loads links and metadata from mangareader

func (m *Mangareader) RetrieveIssueLinks(url string, all, last bool) ([]string, error)

RetrieveIssueLinks gets a slice of urls for all issues in a comic

type Mangarock added in v0.12.3

type Mangarock struct {
	Client *mangarock.Client
}

func NewMangarock added in v0.12.3

func NewMangarock(options map[string]string) *Mangarock

func (*Mangarock) GetInfo added in v0.12.3

func (m *Mangarock) GetInfo(url string) (string, string)

func (*Mangarock) Initialize added in v0.12.3

func (m *Mangarock) Initialize(comic *core.Comic) error

Initialize loads links and metadata from mangarock

func (m *Mangarock) RetrieveIssueLinks(url string, all, last bool) ([]string, error)

RetrieveIssueLinks gets a slice of urls for all issues in a comic

type Mangatown added in v0.12.3

type Mangatown struct{}

func (*Mangatown) GetInfo added in v0.12.3

func (m *Mangatown) GetInfo(url string) (string, string)

func (*Mangatown) Initialize added in v0.12.3

func (m *Mangatown) Initialize(comic *core.Comic) error

Initialize loads links and metadata from mangatown

func (m *Mangatown) RetrieveIssueLinks(url string, all, last bool) ([]string, error)

RetrieveIssueLinks gets a slice of urls for all issues in a comic

Jump to

Keyboard shortcuts

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