api

package
v1.0.4-beta Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2018 License: MIT Imports: 5 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppInfo

type AppInfo struct {
	AppVersion   string   `json:"app_version"`
	Arch         string   `json:"arch"`
	OS           string   `json:"os"`
	Build        string   `json:"build"`
	DailyImages  []string `json:"daily_images"`
	RandomImages []string `json:"random_images"`
}

AppInfo is shared wallpaperize info type

type BingAPI

type BingAPI struct{}

BingAPI DailyImageGetter implementation

func (BingAPI) GetDailyImage

func (b BingAPI) GetDailyImage() (result []byte, err error)

GetDailyImage implementation

func (BingAPI) GetImageReader

func (b BingAPI) GetImageReader() (result io.ReadCloser, err error)

GetImageReader implementation

type ImageGetter

type ImageGetter interface {
	GetImage() (img []byte, err error)
}

ImageGetter fetch image

type UnsplashAPI

type UnsplashAPI struct{}

UnsplashAPI implementation

func (UnsplashAPI) GetImage

func (u UnsplashAPI) GetImage() (result []byte, err error)

GetImage implementation

func (UnsplashAPI) GetImageReader

func (u UnsplashAPI) GetImageReader() (result io.ReadCloser, err error)

GetImageReader returns an Reader with image entity

func (UnsplashAPI) GetRandomImage

func (u UnsplashAPI) GetRandomImage() (result []byte, err error)

GetRandomImage implementation

type Wallmaster

type Wallmaster interface {
	Get() (string, error)
	SetFromFile(file string) error
}

Wallmaster get and set wallpaper from filepath

Jump to

Keyboard shortcuts

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