indexer

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2016 License: MIT Imports: 31 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrUnknownIndexer = errors.New("Unknown indexer")
View Source
var (
	WriteCache = false
)

Functions

func ListDefinitions

func ListDefinitions() ([]string, error)

Types

type IndexerDefinition

type IndexerDefinition struct {
	Site         string            `yaml:"site"`
	Settings     []settingsField   `yaml:"settings"`
	Name         string            `yaml:"name"`
	Description  string            `yaml:"description"`
	Language     string            `yaml:"language"`
	Links        stringorslice     `yaml:"links"`
	Capabilities capabilitiesBlock `yaml:"caps"`
	Login        loginBlock        `yaml:"login"`
	Search       searchBlock       `yaml:"search"`
}

func LoadDefinition

func LoadDefinition(key string) (*IndexerDefinition, error)

func ParseDefinition

func ParseDefinition(src []byte) (*IndexerDefinition, error)

func ParseDefinitionFile

func ParseDefinitionFile(f *os.File) (*IndexerDefinition, error)

type Runner

type Runner struct {
	Definition *IndexerDefinition
	Browser    browser.Browsable
	Config     config.Config
	Logger     logrus.FieldLogger
	// contains filtered or unexported fields
}

func NewRunner

func NewRunner(def *IndexerDefinition, conf config.Config) *Runner

func (*Runner) Capabilities

func (r *Runner) Capabilities() torznab.Capabilities

func (*Runner) Download

func (r *Runner) Download(u string) (io.ReadCloser, http.Header, error)

func (*Runner) Info

func (r *Runner) Info() torznab.Info

func (*Runner) Search

func (r *Runner) Search(query torznab.Query) ([]torznab.ResultItem, error)

type Tester added in v1.3.0

type Tester struct {
	Runner *Runner
	Opts   TesterOpts
}

func (*Tester) Test added in v1.3.0

func (t *Tester) Test() error

type TesterOpts added in v1.3.0

type TesterOpts struct {
	Download bool
}

Jump to

Keyboard shortcuts

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