images

package
v0.0.0-...-906757e Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2023 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var JSON_FILE_DATE string = time.Now().Format("2006-01-02")

Functions

func GetImageBufferBytesAndContentTypeByUrl

func GetImageBufferBytesAndContentTypeByUrl(url string) ([]byte, string, error)

func PttImageBoard

func PttImageBoard(board string, titlePrefix string, chunkSize int, limitSize int, write bool) []string

PttImageBoard is a function for crawling a specific board on PTT. Parameters:

board: The name of the board to crawl.
titlePrefix: The prefix used to filter article titles. It can be an empty string.
chunkSize: The number of articles to request per chunk.
limitSize: The maximum number of articles to crawl.
write: A boolean indicating whether to write the results to a file.

Returns: A list of image links crawled.

func PttRandomImageBoard

func PttRandomImageBoard(board string, titlePrefix string) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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