silk

package
v0.0.0-...-5418a87 Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2024 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	FEATS = Feats{

		AppendOnly: 1 << 0,

		Lz4: 1 << 2,

		SplayTree: 1 << 1,

		AolFflush: 1 << 3,
	}
)

declare magic feature choices

Functions

func KeyFromValue

func KeyFromValue(value string) (string, []uuid.UUID)

returns a big uuid-like string and an array of component uuids from a seed string if there is somehow a collision please contact me so I can quit as a developer

Types

type Feats

type Feats struct {
	AppendOnly int
	Lz4        int
	SplayTree  int
	AolFflush  int
}

type RelationalNode

type RelationalNode struct {
	Chunks    []uuid.UUID
	Key       string //UWUID
	Name      string
	Links     []string
	Backlinks []string
	Tags      []string
}

func NewRelationalNode

func NewRelationalNode(value string) *RelationalNode

type Silk

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

onto the main struct

func New

func New() *Silk

func (*Silk) CloseDatabase

func (silk *Silk) CloseDatabase()

close a database, used internally and externally

func (*Silk) FindDiskDatabase

func (silk *Silk) FindDiskDatabase(dir string)

find me all valid databases in a directory

func (*Silk) NewDatabase

func (silk *Silk) NewDatabase(basedir string, feats int) (string, error)

give me a random database here and switch me to it

func (*Silk) OpenDatabase

func (silk *Silk) OpenDatabase(dir string, name string, feats int) error

open a database in a directory I know exists (currently creates a database if it doesn't exist, as long as the dir exists)

func (*Silk) PullNode

func (silk *Silk) PullNode(uuid string) RelationalNode

func (*Silk) PushNode

func (silk *Silk) PushNode(node RelationalNode)

Jump to

Keyboard shortcuts

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