db

package
v1.3.12 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Database

type Database struct {
	DB *sql.DB
}

func InitDB

func InitDB(filepath string) (*Database, error)

func (*Database) CleanUpOldPosts

func (d *Database) CleanUpOldPosts(forum string, duration time.Duration)

func (*Database) CreateTableIfNotExists

func (d *Database) CreateTableIfNotExists(forum string) error

func (*Database) IsNewPost

func (d *Database) IsNewPost(forum, postID string) bool

func (*Database) StorePostID added in v1.3.9

func (d *Database) StorePostID(forum, postID string)

Jump to

Keyboard shortcuts

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