keywords

package
v0.0.0-...-5597ac0 Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2017 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Keyword

type Keyword struct {
	ID            int64
	Value         string
	TimesScraped  int
	CreatedAt     string
	UpdatedAt     string
	LastScrapedAt string
}

func New

func New(value string) *Keyword

type Reader

type Reader interface {
	GetLeastScraped(int) ([]Keyword, error)
}

func NewReader

func NewReader(s Store) Reader

type ReaderWriter

type ReaderWriter interface {
	Reader
	Writer
}

func NewReaderWriter

func NewReaderWriter(s Store) ReaderWriter

type Store

type Store interface {
	Close() error
	QueryRow(string, ...interface{}) *sql.Row
	Query(string, ...interface{}) (*sql.Rows, error)
}

func NewStore

func NewStore(url string) (Store, error)

type Writer

type Writer interface {
	Upsert(*Keyword) (*Keyword, error)
	UpdateScraped(*Keyword) (*Keyword, error)
}

func NewWriter

func NewWriter(s Store) Writer

Jump to

Keyboard shortcuts

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