prefetch

package
v0.0.0-...-c8b2685 Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2023 License: GPL-3.0 Imports: 23 Imported by: 0

Documentation

Overview

Package prefetch processes items received via RSS/Atom feeds and checks if they contain image links. If they do, it loads those images, saves them locally and adjusts the item to reference the local image. We may do this for other resources, too.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Prefetcher

type Prefetcher struct {
	// contains filtered or unexported fields
}

Prefetcher takes care of processing news items to prefetch and locally store images. Maybe other stuff, too.

func Create

func Create(cnt int) (*Prefetcher, error)

Create creates a new instance of the Prefetcher, prepared to use up to cnt concurrent goroutines for fetching objects.

func (*Prefetcher) IsRunning

func (p *Prefetcher) IsRunning() bool

IsRunning returns true if the Prefetcher is active.

func (*Prefetcher) Start

func (p *Prefetcher) Start() error

Start sets the Prefetcher on its path.

func (*Prefetcher) Stop

func (p *Prefetcher) Stop()

Stop tells the Prefetcher to stop. Duh.

Jump to

Keyboard shortcuts

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