crdtdb

package
v0.0.0-...-716df76 Latest Latest
Warning

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

Go to latest
Published: Mar 23, 2021 License: Unlicense Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AppendTagToPost

func AppendTagToPost(db *sql.DB, tag, postHash string) error

func Close

func Close(db *sql.DB)

func InitDB

func InitDB(channel string) *sql.DB

func InsertPost

func InsertPost(db *sql.DB, hash string, size int) error

func LatestHash

func LatestHash(db *sql.DB) (hash string)

func MappingsCount

func MappingsCount(db *sql.DB) int

func NewHash

func NewHash(db *sql.DB, hash string) error

func PostCount

func PostCount(db *sql.DB) int

Types

type Post

type Post struct {
	ID   int
	Hash string
	Size int
	Tags []string
}

func GetPosts

func GetPosts(db *sql.DB) ([]Post, error)
func Search(tag string, db *sql.DB) ([]Post, error)

Jump to

Keyboard shortcuts

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