plugin

package
v0.6.1 Latest Latest
Warning

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

Go to latest
Published: Jan 2, 2023 License: MIT Imports: 1 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

数据结构

main

js中main函数的参数:

// 参数
argv = [
    {
        Url: "https://mikanani.me/Home/Episode/0c0a30b9b7ee437e33fdea6522eb223377dd1d48", // Link,详情页连接,用于下一步解析番剧信息
        Name: "", // 种子名
        Date: "", // 发布日期
        Torrent: "", // 种子连接
        Hash: "", // 种子hash,唯一ID
    },
    // ...
]
// 返回值
main = {
    index: [0, 1, 2], // 筛选结果
    error: null,
}

日志

// 日志输出
log.debug(...params)
log.info(...params)
log.error(...params)

os.readFile

// 读取文本文件
// 参数
filename // 基于当前插件所在目录的相对路径
// 返回值
os.readFile // 字符串

variable

// 变量
variable.version // AnimeGo版本号
variable.name // 插件名(即不含扩展名的插件文件名)

animeGo.parseName

// 初步解析资源名
// 参数
name = "" // 种子名
// 返回值
animeGo.parseName = {
    TitleRaw: "", // 种子名
    Name: "", // 番剧名
    Season: 0, // 季度
    Ep: 0, // ep
    Group: "", // 字幕组
    Definition: "", // 分辨率
    Sub: "", // 字幕语言
    Source: "", // 资源平台
}

animeGo.getMikanInfo

// 获取Mikan信息
// 参数
url = "https://mikanani.me/Home/Episode/0c0a30b9b7ee437e33fdea6522eb223377dd1d48" // mikanUrl
// 返回值
animeGo.getMikanInfo = {
    ID: 0,
    SubGroupID: 0,
    PubGroupID: 0,
    GroupName: ""
}

其他函数

sleep
sleep(ms) // ms 毫秒,1000ms=1s
print
print(...params)

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Plugin

type Plugin interface {
	Execute(file string, params models.Object) any
	SetSchema(paramsSchema, resultSchema []string)
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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