cmds

package
v0.0.0-...-b0c7cc0 Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2019 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Client Kind = iota
	System      = iota
	Database
)

Variables

View Source
var Commands = []Command{
	{"connect", Client, "connect treedb server", "connect ADDRESS(tcp[4|6]://host:port or unix://filepath)"},
	{"create", System, "create database", "create NAME [FROM TEMPLATE]"},
	{"select", System, "select database", "select NAME"},
	{"get", Database, "get value stored at path", "get PATH"},
	{"set", Database, "set value stored to path", "set PATH VALUE"},
	{"delete", Database, "delete key pointed by path", "delete PATH"},
	{"cache", Database, "set cache timeout for path", "cache PATH TIMEOUT(never or delete or 0 or time.Duration)"},
	{"touch", Database, "update timestamp for in memory path", "touch PATH"},
}

Functions

func Complete

func Complete(name string) (suggests []string)

Types

type Command

type Command struct {
	Name  string
	Kind  Kind
	Info  string
	Usage string
}

func Find

func Find(name string) *Command

type Kind

type Kind int

Jump to

Keyboard shortcuts

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