kamiext

package module
v0.0.8 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2022 License: GPL-3.0 Imports: 2 Imported by: 0

README

KamiExt

KamiReader Extension basic methods to use in extensions

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewExtension added in v0.0.7

func NewExtension() *ext

func Write

func Write(data Response) int8

Types

type ArgMethod added in v0.0.7

type ArgMethod func(string) Response

type Chapter

type Chapter struct {
	Name      string   `json:"name"`
	Number    string   `json:"number"`
	Timestamp int      `json:"timestamp"`
	Handle    string   `json:"handle"`
	Pages     []string `json:"pages"`
}

type Comic

type Comic struct {
	Title         string    `json:"title"`
	Id            string    `json:"id"`
	Url           string    `json:"url"`
	ComicType     string    `json:"comictype"`
	ReleaseStatus string    `json:"releasestatus"`
	Summary       string    `json:"summary"`
	Cover         string    `json:"cover"`
	Authors       []string  `json:"authors"`
	Artists       []string  `json:"artists"`
	Altnames      []string  `json:"altnames"`
	Genres        []string  `json:"genres"`
	Year          string    `json:"year"`
	Chapters      []Chapter `json:"chapters"`
}

type Extension

type Extension struct {
	Name            string   `json:"name"`
	ExtensionId     string   `json:"id"`
	Author          string   `json:"author"`
	ExtensionSource string   `json:"source"`
	Sources         []Source `json:"sources"`
	Executable      string   `json:"executable"`
	UpdatesUrl      string   `json:"updatesurl"`
	Updater         string   `json:"updater"`
	Version         string   `json:"version"`
}

type ExtensionSetup added in v0.0.3

type ExtensionSetup struct {
	Name       string `json:"name"`
	Author     string `json:"author"`
	Source     string `json:"source"`
	UpdatesUrl string `json:"updatesurl"`
	Updater    string `json:"updater"`
	Version    string `json:"version"`
}

type JsonMethod added in v0.0.7

type JsonMethod func(any) Response

type Method added in v0.0.7

type Method func() Response

type Response

type Response struct {
	Data  any    `json:"data"`
	Error string `json:"error"`
}

func ArgMethodNotAvailable added in v0.0.7

func ArgMethodNotAvailable(a string) Response

func Error

func Error(err error) Response

func ErrorStr

func ErrorStr(err string) Response

func JsonMethodNotAvailable added in v0.0.7

func JsonMethodNotAvailable(a any) Response

func MethodNotAvailable added in v0.0.7

func MethodNotAvailable() Response

func MethodNotFound added in v0.0.7

func MethodNotFound() Response

func NoMethod added in v0.0.7

func NoMethod() Response

func Result

func Result(data any) Response

type SearchComic

type SearchComic struct {
	Title  string `json:"title"`
	Id     string `json:"id"`
	Handle string `json:"handle"`
	Cover  string `json:"cover"`
}

type Source

type Source struct {
	Name        string   `json:"name"`
	Methods     []string `json:"methods"`
	Id          string   `json:"id"`
	Domain      string   `json:"domain"`
	ExtensionId string   `json:"extensionid"`
}

type SourceSetup added in v0.0.3

type SourceSetup struct {
	Name    string   `json:"name"`
	Domain  string   `json:"domain"`
	Methods []string `json:"methods"`
	Id      string   `json:"id"`
}

Jump to

Keyboard shortcuts

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