core

package
v0.0.0-...-5c9eeab Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2019 License: GPL-3.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Core

type Core interface {
	// login created peer identity
	Start(key string, port int) error

	// logout current peer identity
	End() error

	// Join a new space
	JoinSpace(spaceName string) error

	// leave a joined space
	LeaveSpace(spaceName string) error
}

Core interface

type RhizomeCore

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

RhizomeCore main cordinator

func NewRhizomeCore

func NewRhizomeCore() *RhizomeCore

NewRhizomeCore init the RhizomeCore

func (*RhizomeCore) End

func (core *RhizomeCore) End() error

End end the service

func (*RhizomeCore) Login

func (core *RhizomeCore) Login(name string, privKey crypto.PrivKey, prot pnet.Protector) error

Login login using private key, name, and corresponding network protector

func (*RhizomeCore) Logout

func (core *RhizomeCore) Logout() error

Logout logout current space

func (*RhizomeCore) Start

func (core *RhizomeCore) Start() error

Start the service

type UserData

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

UserData is used to load data from json

Jump to

Keyboard shortcuts

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