anonymity

package
v1.5.15 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2023 License: MIT Imports: 19 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IHandlerF

type IHandlerF func(INode, asymmetric.IPubKey, []byte, []byte) ([]byte, error)

type INode

type INode interface {
	types.ICommand

	GetSettings() ISettings
	GetWrapperDB() IWrapperDB
	GetNetworkNode() network.INode
	GetMessageQueue() queue.IMessageQueue
	GetListPubKeys() asymmetric.IListPubKeys
	GetLogger() logger.ILogger

	HandleFunc(uint32, IHandlerF) INode
	HandleMessage(message.IMessage) // in runtime

	BroadcastPayload(asymmetric.IPubKey, adapters.IPayload) error
	FetchPayload(asymmetric.IPubKey, adapters.IPayload) ([]byte, error)
}

func NewNode

func NewNode(
	pSett ISettings,
	pLogger logger.ILogger,
	pWrapperDB IWrapperDB,
	pNetwork network.INode,
	pQueue queue.IMessageQueue,
	pFriends asymmetric.IListPubKeys,
) INode

type ISettings

type ISettings interface {
	GetServiceName() string
	GetNetworkMask() uint64
	GetRetryEnqueue() uint64
	GetFetchTimeWait() time.Duration
}

func NewSettings

func NewSettings(pSett *SSettings) ISettings

type IWrapperDB added in v1.5.6

type IWrapperDB interface {
	types.ICloser

	Get() database.IKVDatabase
	Set(database.IKVDatabase) IWrapperDB
}

func NewWrapperDB added in v1.5.6

func NewWrapperDB() IWrapperDB

type SSettings

type SSettings sSettings

Directories

Path Synopsis
_examples

Jump to

Keyboard shortcuts

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