Documentation
¶
Overview ¶
Package alfdb provides tools to store a Bluesky/Mastodon db-index of records (Bluesky) and statuses (Mastodon).
Index ¶
- func SchemaVersion() int
- type DB
- func (db *DB) Account(ctx context.Context, acc alfari.Account) (alfari.Account, error)
- func (db *DB) Close() error
- func (db *DB) Creds(ctx context.Context, acc alfari.Account) (alfari.Account, error)
- func (db *DB) DelMedia(ctx context.Context, acc alfari.Account, bscid string) error
- func (db *DB) Do(ctx context.Context, f func(tx *sql.Tx) error) (err error)
- func (db *DB) GetMedia(ctx context.Context, acc alfari.Account, bscid string) (media alfari.Media, err error)
- func (db *DB) Name() string
- func (db *DB) PutMedia(ctx context.Context, acc alfari.Account, media alfari.Media) error
- func (db *DB) PutToot(ctx context.Context, toot alfari.Toot) error
- func (db *DB) Sync(ctx context.Context) error
- func (db *DB) Thread(ctx context.Context, acc alfari.Account, bsid string) (alfari.Thread, error)
- func (db *DB) Threads(ctx context.Context, acc alfari.Account) iter.Seq2[alfari.Thread, error]
- func (db *DB) Toot(ctx context.Context, acc alfari.Account, bsid string) (toot alfari.Toot, err error)
- func (db *DB) Toots(ctx context.Context, acc alfari.Account) iter.Seq2[alfari.Toot, error]
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SchemaVersion ¶
func SchemaVersion() int
Types ¶
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
DB stores alfari data as a SQLite-backed database.
Click to show internal directories.
Click to hide internal directories.