data

package
v0.0.0-...-4081b50 Latest Latest
Warning

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

Go to latest
Published: May 8, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FromJSON

func FromJSON(i interface{}, r io.Reader) error

FromJSON converts JSON to Go data structure.

func ToJSON

func ToJSON(i interface{}, w io.Writer) error

ToJSON parses Go data structure to JSON.

Types

type Cred

type Cred struct {
	URL string `json:"url"`
}

Cred is credential for http.Request.Body. Includes URL that is going to be fetched.

type Images

type Images []*PageInfo

func GetImages

func GetImages(images Images, node *html.Node, resp *http.Response) Images

GetImages traverses the parsed HTML, returns each images in HTML.

type PageInfo

type PageInfo struct {
	ImageURL  string `json:"image"`
	ImageName string `json:"image_name"`
}

Jump to

Keyboard shortcuts

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