tumblr

package
v0.0.0-...-37e3ad1 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2018 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewCrawler

func NewCrawler(opt *Opt) kniv.Crawler

Types

type Crawler

type Crawler struct {
	*gotumblr.TumblrRestClient
	// contains filtered or unexported fields
}

func (*Crawler) SetResourceChannel

func (c *Crawler) SetResourceChannel(q chan kniv.URLEvent)

func (*Crawler) SetRootDownloadDir

func (c *Crawler) SetRootDownloadDir(dir string)

func (*Crawler) StartResourceSending

func (c *Crawler) StartResourceSending(wg *sync.WaitGroup)

type CrawlerFactory

type CrawlerFactory struct{}

func (*CrawlerFactory) Create

func (c *CrawlerFactory) Create(crawlersSetting map[string]interface{}) (kniv.Crawler, error)

type Opt

type Opt struct {
	ConsumerKey              string
	ConsumerSecret           string
	OauthToken               string
	OauthSecret              string
	Offset                   int
	MaxBlogNum               int
	PostNumPerBlog           int
	APIIntervalMilliSec      time.Duration
	DownloadIntervalMilliSec time.Duration
	DstDirMap                map[string]string
	DownloadQueueSize        int
}

type VideoPost

type VideoPost struct {
	gotumblr.BasePost
	VideoUrl string `json:"video_url"`
}

Jump to

Keyboard shortcuts

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