localDB

package
v0.0.0-...-a1e7e79 Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TableNamePatients  = "stat_patients"
	TableNameDocuments = "stat_documents"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type DB

type DB struct {
	sync.Mutex
	// contains filtered or unexported fields
}

func New

func New(filePath string) *DB

func (*DB) Close

func (db *DB) Close()

func (*DB) Migrate

func (db *DB) Migrate(migrations string) error

func (*DB) StatDocumentsCountGet

func (db *DB) StatDocumentsCountGet(start, end int64) (uint64, error)

func (*DB) StatDocumentsCountIncrement

func (db *DB) StatDocumentsCountIncrement(timestamp time.Time) error

func (*DB) StatPatientsCountGet

func (db *DB) StatPatientsCountGet(start, end int64) (uint64, error)

func (*DB) StatPatientsCountIncrement

func (db *DB) StatPatientsCountIncrement(timestamp time.Time) error

func (*DB) SyncLastBlockGet

func (db *DB) SyncLastBlockGet() (uint64, error)

func (*DB) SyncLastBlockSet

func (db *DB) SyncLastBlockSet(lastSyncedBlock uint64) error

Jump to

Keyboard shortcuts

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