model

package
v0.0.0-...-34674f1 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2020 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Comment

type Comment struct {
	ID       uint   `gorm:"primary_key"`
	Content  string `gorm:"size:1024` //内容
	NickName string //昵称
	Addr     string

	Time      time.Time
	DeletedAt *time.Time `gorm:"index:id_deleted"`
}

type FileInfo

type FileInfo struct {
	Number        int    `json:"number"`
	Extension     string `json:"extension"`  //格式
	Resolution    string `json:"resolution"` //解析度
	VideoEncoding string `json:"videoEncoding"`
	AudioEncoding string `json:"audioEncoding"`
	AudioBitrate  int    `json:"audioBitrate"`
	FPS           int    `json:"fps"`  // FPS are frames per second
	Url           string `json:"url"`  //视频下载地址
	Size          int64  `json:"size"` //视频大小
}

type RequestLog

type RequestLog struct {
	ID            uint `gorm:"primary_key"`
	RemoteAddr    string
	RequestUrl    string
	RequestMethod string

	RequestTime     time.Time
	RequestDuration time.Duration

	ResponseStatus int
	ResponseSize   int

	Referer string
}

type Video

type Video struct {
	Info     *VideoInfo            `json:"info"`
	Files    []*FileInfo           `json:"files"`
	Captions *y2bcaptions.Captions `json:"captions"`
}

type VideoInfo

type VideoInfo struct {
	ID            string        `json:"id"`            // ID
	Title         string        `json:"title"`         //标题
	Description   string        `json:"description"`   //描述
	DatePublished time.Time     `json:"datePublished"` //发表日期
	Uploader      string        `json:"uploader"`      //上传者
	Duration      time.Duration `json:"duration"`      //时长
	ThumbnailUrl  string
	//Captions      *y2bcaptions.Captions
	Kind string `json:"kind"` //类型
}

Jump to

Keyboard shortcuts

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