state

package
v0.0.0-...-7d36741 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DB

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

DB wraps the SQLite state database.

func Open

func Open(path string) (*DB, error)

Open opens (or creates) the SQLite state file and applies the schema.

func (*DB) AlreadyMigrated

func (d *DB) AlreadyMigrated(sourceFolder string, sourceUID, uidValidity uint32) (bool, error)

AlreadyMigrated returns true if this source message has been successfully copied before.

func (*DB) Close

func (d *DB) Close() error

Close closes the database.

func (*DB) MarkDeleted

func (d *DB) MarkDeleted(sourceFolder string, sourceUID, uidValidity uint32) error

MarkDeleted updates the record to indicate the source message was expunged.

func (*DB) RecordMigration

func (d *DB) RecordMigration(sourceFolder string, sourceUID, uidValidity uint32, destFolder string) error

RecordMigration inserts a successful copy record. Duplicate inserts are silently ignored.

Jump to

Keyboard shortcuts

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