postgres

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2026 License: AGPL-3.0 Imports: 11 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Store

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

func Open

func Open(ctx context.Context, url string) (*Store, error)

func (*Store) AccountByToken

func (s *Store) AccountByToken(token string) (*store.Account, error)

func (*Store) AddBytes

func (s *Store) AddBytes(accountID string, n int64)

func (*Store) AddPushes

func (s *Store) AddPushes(accountID string, n int)

func (*Store) ApproveDeviceCode

func (s *Store) ApproveDeviceCode(userCode, accountID string) error

func (*Store) AuthenticateV1

func (s *Store) AuthenticateV1(string, string, string, bool) (*store.Host, error)

func (*Store) AuthenticateV2

func (s *Store) AuthenticateV2(id, name string, pub []byte, _, _, _ bool) (*store.Host, error)

func (*Store) Ban

func (s *Store) Ban(id string, banned bool) error

func (*Store) Close

func (s *Store) Close()

func (*Store) ConsumeDeviceCode

func (s *Store) ConsumeDeviceCode(deviceCode string) (*store.Account, string, error)

func (*Store) Count

func (s *Store) Count() int

func (*Store) CreateCLIToken

func (s *Store) CreateCLIToken(accountID string) (string, error)

func (*Store) CreateDeviceCode

func (s *Store) CreateDeviceCode(userCode, deviceCode string, ttl time.Duration) (*store.DeviceCode, error)

func (*Store) Flush

func (s *Store) Flush() error

func (*Store) ListHosts

func (s *Store) ListHosts(accountID string) ([]*store.Host, error)

func (*Store) Lookup

func (s *Store) Lookup(id string) (*store.Host, bool)

func (*Store) LookupDeviceCode

func (s *Store) LookupDeviceCode(deviceCode string) (*store.DeviceCode, error)

func (*Store) LookupUserCode

func (s *Store) LookupUserCode(userCode string) (*store.DeviceCode, error)

func (*Store) QuotaFor

func (s *Store) QuotaFor(accountID string) store.Quota

func (*Store) RegisterHost

func (s *Store) RegisterHost(accountID, id, name string, pub []byte, bundleID string) (*store.Host, error)

func (*Store) RotateEd25519

func (s *Store) RotateEd25519(string, []byte) error

func (*Store) SetNode

func (s *Store) SetNode(id, nodeID string) error

func (*Store) SetQuotaDefaults

func (s *Store) SetQuotaDefaults(q store.Quota)

func (*Store) TouchSeen

func (s *Store) TouchSeen(id, name string) error

func (*Store) UpsertAccount

func (s *Store) UpsertAccount(provider, providerID, login string) (*store.Account, error)

Jump to

Keyboard shortcuts

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