lanzou

package
v0.0.0-...-7b7e080 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Dom

type Dom struct {
	Zt  int    `json:"zt"`
	Dom string `json:"dom"`
	// URL 可能为string或int
	URL interface{} `json:"url"`
	// Inf 可能为string或int
	Inf interface{} `json:"inf"`
}

type FileItem

type FileItem []struct {
	Icon    string `json:"icon"`
	T       int    `json:"t"`
	ID      string `json:"id"`
	NameAll string `json:"name_all"`
	Size    string `json:"size"`
	Time    string `json:"time"`
	Duan    string `json:"duan"`
	PIco    int    `json:"p_ico"`
}

type FileList

type FileList struct {
	Zt   int    `json:"zt"`
	Info string `json:"info"`
	// Text 可能为int或数组
	Text interface{} `json:"text"`
}

type Lanzou

type Lanzou struct {
	*client.Client
}

func New

func New(config *client.Config) (*Lanzou, error)

func (*Lanzou) DownloadFile

func (l *Lanzou) DownloadFile(downloadURL string) (io.ReadCloser, int64, error)

func (*Lanzou) IsDirURL

func (l *Lanzou) IsDirURL(shareURL string) bool

func (*Lanzou) IsFileURL

func (l *Lanzou) IsFileURL(shareURL string) bool

func (*Lanzou) ParseAnonymousShare

func (l *Lanzou) ParseAnonymousShare(parsedURI string, firstPage string) (*ResponseData, error)

func (*Lanzou) ParsePasswordShare

func (l *Lanzou) ParsePasswordShare(parsedURI string, pwd string, firstPage string) (*ResponseData, error)

func (*Lanzou) ResolveShareURL

func (l *Lanzou) ResolveShareURL(shareURL, pwd string) ([]ResponseData, error)

type ResponseData

type ResponseData struct {
	Name string `json:"name"`
	Size string `json:"size"`
	URL  string `json:"url"`
}

Jump to

Keyboard shortcuts

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