common

package
v0.0.0-...-004a0da Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2024 License: BSD-3-Clause Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	BaseURL = "https://www.example.com"
	Debug   = false
	Wait    = 5 * time.Second
	ImgWait = time.Second
)

Functions

func AssignSeriesID

func AssignSeriesID(s data.Series) string

func AttemptSaveImage

func AttemptSaveImage(href string) (string, error)

func ChromeRequestOrCache

func ChromeRequestOrCache(httpPath string) string

func CleanStuff

func CleanStuff(s string) string

func RequestOrCache

func RequestOrCache(httpPath string) string

func RequestOrCache2

func RequestOrCache2(httpPath string) (string, error)

func RequestOrCacheBytes

func RequestOrCacheBytes(httpPath string) []byte

func SaveImage

func SaveImage(href string) string

func Slugify

func Slugify(s string) string

Types

type Client

type Client struct {
	BaseURL string
}

func NewClient

func NewClient(baseURL string) *Client

func (*Client) ChromeRequestOrCache

func (c *Client) ChromeRequestOrCache(httpPath string) string

func (*Client) RequestOrCache

func (c *Client) RequestOrCache(httpPath string) string

func (*Client) RequestOrCache2

func (c *Client) RequestOrCache2(httpPath string) (string, error)

func (*Client) RequestOrCacheBytes

func (c *Client) RequestOrCacheBytes(httpPath string) []byte

Jump to

Keyboard shortcuts

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