tns

package
v1.1.5 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2024 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	Fetch(path Path) (Object, error)
	Lookup(query Query) (interface{}, error)
	Push(path []string, data interface{}) error
	List(depth int) ([]string, error)
	Close()

	Simple() SimpleIface
	Database() StructureIface[*structureSpec.Database]
	Domain() StructureIface[*structureSpec.Domain]
	Function() StructureIface[*structureSpec.Function]
	Library() StructureIface[*structureSpec.Library]
	Messaging() StructureIface[*structureSpec.Messaging]
	Service() StructureIface[*structureSpec.Service]
	SmartOp() StructureIface[*structureSpec.SmartOp]
	Storage() StructureIface[*structureSpec.Storage]
	Website() StructureIface[*structureSpec.Website]

	Stats() Stats

	Peers(...peerCore.ID) Client
}

type Object

type Object interface {
	Path() Path
	Bind(interface{}) error
	Interface() interface{}
	// Expected to use with links index
	Current(branch []string) ([]Path, error)
}

type Path

type Path interface {
	String() string
	Slice() []string
}

type Query

type Query struct {
	Prefix []string
	RegEx  bool
}

type Service

type Service interface {
	services.DBService
}

type SimpleIface

type SimpleIface interface {
	Commit(projectId string, branches ...string) (commit string, branch string, err error)
	Project(projectID string, branches ...string) (interface{}, error)
	GetRepositoryProjectId(gitProvider, repoId string) (projectId string, err error)
}

type Stats

type Stats interface {
	Database() (kvdb.Stats, error)
}

type StructureGetter

type StructureGetter[T structureSpec.Structure] interface {
	Commit(projectId string) (commit string, branch string, err error)
	List() (o map[string]T, commit string, branch string, err error)
	GetById(resourceId string) (T, error)
	GetByIdCommit(projectId, commit string) (resource T, err error)
	GetByName(resourceName string) (resource T, err error)
}

type StructureIface

type StructureIface[T structureSpec.Structure] interface {
	Relative(projectId, appId string, branches ...string) StructureGetter[T]
	All(projectId, appId string, branches ...string) StructureGetter[T]
	Global(projectId string, branches ...string) StructureGetter[T]
}

Jump to

Keyboard shortcuts

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