Documentation
¶
Index ¶
- Variables
- type Illust
- func (i *Illust) Download(page int, filedir, filename string) (string, error)
- func (i *Illust) DownloadData(page int) ([]byte, string, error)
- func (i *Illust) DownloadSingleThread(page int, filedir, filename string) (string, error)
- func (i *Illust) DownloadToCache(page int, filename string) (string, error)
- type RankValue
Constants ¶
This section is empty.
Variables ¶
View Source
var (
CacheDir = "data/pixiv/"
)
View Source
var IPTables = map[string]string{
"pixiv.net": "210.140.92.183:443",
"i.pximg.net": "210.140.92.142:443",
}
P站 无污染 IP 地址
Functions ¶
This section is empty.
Types ¶
type Illust ¶
type Illust struct {
Pid int64 `db:"pid"`
Title string `db:"title"`
Caption string `db:"caption"`
Tags string `db:"tags"`
ImageUrls []string `db:"image_urls"`
AgeLimit string `db:"age_limit"`
CreatedTime string `db:"created_time"`
UserId int64 `db:"user_id"`
UserName string `db:"user_name"`
}
插画结构体
func (*Illust) Download ¶ added in v1.2.5
Download 多线程下载 link 到 filedir,返回 filedir+filename+suffix, error
func (*Illust) DownloadData ¶ added in v1.2.5
DownloadData 下载第 page 页,返回 data, suffix, error
func (*Illust) DownloadSingleThread ¶ added in v1.2.5
DownloadSingleThread 单线程下载第 page 页到 filedir/filename.xxx,返回 filedir/filename.suffix, error
type RankValue ¶
type RankValue struct {
/* required, possible rank modes:
- daily (default)
- weekly
- monthly
- rookie
- original
- male
- female
- daily_r18
- weekly_r18
- male_r18
- female_r18
- r18g
*/
Mode string
/* optional, possible rank type:
- all (default)
- illust
- ugoira
- manga
*/
Type string
Page int
Date string
}
搜索元素
Click to show internal directories.
Click to hide internal directories.