api

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: AGPL-3.0 Imports: 1 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 interface {
	StoreFile(options storage.StoreFileOptions) (storage.Event, error)
	GetFile(eventOfFile storage.Event) ([]byte, error)
	GetEvent(hashOfEvent [64]byte) (storage.Event, error)
	GetMetadata(eventOfFile storage.Event) ([]byte, error)
	GetAllRootEvents() ([]storage.Event, error)
	GetRootIndex() ([]storage.RootEventsIndex, error)
	GetRootEventsWithTitle(title string) ([]storage.Event, error)
	CreateRootEvent(title string) (storage.Event, error)
	CreateNewEvent(options storage.EventOptions) (storage.Event, error)
}

type Index

type Index interface {
	RebuildIndex() (uint64, error)
	GetChildrenHashesOfEvent(eventHash [64]byte) [][64]byte
	GetDirectChildrenOfEvent(eventHash [64]byte) ([]storage.Event, error)
}

Jump to

Keyboard shortcuts

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