Documentation ¶
Index ¶
- func DownloadVideoComments(commentURL string, outputPath string, nicoHistory string, threadID string, ...) (err error)
- func DownloadVideoSource(videoURL string, outputPath string, nicoHistory string) (err error)
- func GetFlv(videoID string, sessionKey string) (flv map[string]string, err error)
- func GetHistory(videoID string, sessionKey string) (nicoHistory string, err error)
- func GetSessionKey(mail string, password string) (error, string)
- func IsMylist(query string) bool
- func ToMylistID(query string) string
- func ToVideoID(query string) string
- type Comment
- type GlobalNumberRes
- type Leaf
- type Mylist
- type MylistVideo
- type MylistVideoThumbnailStyle
- type Packet
- type Tag
- type Thread
- type Thumbinfo
- type ViewCounter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DownloadVideoComments ¶
func DownloadVideoComments(commentURL string, outputPath string, nicoHistory string, threadID string, length int) (err error)
commentURL flv.ms threadID flv.thread_id length flv.l
func DownloadVideoSource ¶
func GetHistory ¶
func ToMylistID ¶
Types ¶
type Comment ¶
type Comment struct { ThreadID int `xml:"thread,attr" json:"thread"` No int `xml:"no,attr" json:"no"` Vpos int `xml:"vpos,attr" json:"vpos"` Date string `xml:"date,attr" json:"date"` Mail string `xml:"mail,attr" json:"mail"` UserID string `xml:"user_id,attr" json:"user_id"` Anonymity bool `xml:"anonymity,attr" json:"anonymity"` Leaf int `xml:"leaf,attr" json:"leaf"` Body string `xml:",chardata" json:"body"` }
<chat thread="1387572949" no="5" vpos="15095" date="1387575544" mail="184" user_id="kwpNfx7idiioqlDzTDbG49P-drU" anonymity="1" leaf="2">綺麗だな~</chat>
type GlobalNumberRes ¶
type GlobalNumberRes struct {
NumRes int `xml:"num_res,attr" json:"num_res"`
}
<global_num_res thread="1387572949" num_res="256"/>
type Leaf ¶
type Leaf struct { ThreadID int `xml:"thread,attr" json:"thread_id"` Number int `xml:"leaf,attr" json:"number"` Count int `xml:"count,attr" json:"count"` }
<leaf thread="1387572949" count="49"/> <leaf thread="1387572949" leaf="1" count="14"/>
type Mylist ¶
type Mylist struct { Name string `json:"name"` Description string `json:"description"` UserID int `json:"user_id"` UserNickname string `json:"user_nickname"` DefaultSort int `json:"default_sort"` List []MylistVideo `json:"list"` IsWatchingThisMylist bool `json:"is_watching_this_mylist"` IsWatchingCountFull bool `json:"is_watching_count_full"` Status string `json:"status"` }
type MylistVideo ¶
type MylistVideo struct { ThumbnailURL string `json:"thumbnailurl"` Length string `json:"length"` LengthSeconds int `json:"length_seconds"` Title string `json:"title"` ViewCounter int `json:"view_counter"` NumRes int `json:"num_res"` MylistCounter int `json:"mylist_counter"` FirstRetrieve string `json:"first_retrieve"` DescriptionShort string `json:"description_short"` LastResBody string `json:"last_res_body"` ThumbnailStyle MylistVideoThumbnailStyle `json:"thumbnail_style"` IsMiddleThumbnail bool `json:"is_middle_thumbnail"` ID string `json:"id"` CreateTime int `json:"create_time"` ThreadUpdateTime string `json:"thread_update_time"` MylistComment string `json:"mylist_comment"` }
type Packet ¶
type Packet struct { Threads []Thread `xml:"thread" json:"threads"` Leaves []Leaf `xml:"leaf" json:"leaves"` ViewCounter ViewCounter `xml:"view_counter" json:"view_counter"` GlobalNumberRes GlobalNumberRes `xml:"global_num_res" json:"global_num_res"` Comments []Comment `xml:"chat" json:"comments"` }
type Thread ¶
type Thread struct { ResultCode int `xml:"resultcode,attr" json:"result_code"` ID int `xml:"thread,attr" json:"id"` LastRes int `xml:"last_res,attr" json:"last_res"` Ticket string `xml:"ticket,attr" json:"ticket"` Revision int `xml:"revision,attr" json:"revision"` ServerTime int `xml:"server_time,attr" json:"server_time"` }
<thread resultcode="0" thread="1387572949" last_res="256" ticket="0x50cac000" revision="1" server_time="1465812057"/>
type Thumbinfo ¶
type Thumbinfo struct { VideoID string `xml:"thumb>video_id"` Title string `xml:"thumb>title"` Description string `xml:"thumb>description"` ThumbnailURL string `xml:"thumb>thumbnail_url"` FirstRetrieve string `xml:"thumb>first_retrieve"` Length string `xml:"thumb>length"` MovieType string `xml:"thumb>movie_type"` SizeHigh int `xml:"thumb>size_high"` SizeLow int `xml:"thumb>size_low"` ViewCounter int `xml:"thumb>view_counter"` CommentNum int `xml:"thumb>comment_num"` MylistCounter int `xml:"thumb>mylist_counter"` LastResBody string `xml:"thumb>last_res_body"` WatchURL string `xml:"thumb>watch_url"` ThumbType string `xml:"thumb>thumb_type"` Embeddable bool `xml:"thumb>embeddable"` NoLivePlay int `xml:"thumb>no_live_play"` Tags []Tag `xml:"thumb>tags>tag"` UserID int `xml:"thumb>user_id"` UserNickname string `xml:"thumb>user_nickname"` UserIconURL string `xml:"thumb>user_icon_url"` }
func GetThumbInfo ¶
type ViewCounter ¶
type ViewCounter struct { Video string `xml:"video,attr" json:"video"` ID string `xml:"id,attr" json:"id"` Mylist int `xml:"mylist,attr" json:"mylist"` }
<view_counter video="32767" id="sm22495319" mylist="55"/>
Click to show internal directories.
Click to hide internal directories.