connector

package
v0.0.0-...-96daba7 Latest Latest
Warning

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

Go to latest
Published: Jul 28, 2019 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Connector

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

func New

func New(listenAddress string, finder Finder, onNodeHandler func(node *vnode.Node) bool, onConnectionHandler func(c *net.TCPConn, inbound bool)) *Connector

func (*Connector) ConnectNode

func (c *Connector) ConnectNode(node *vnode.Node) (err error)

func (*Connector) Start

func (c *Connector) Start() (err error)

type Finder

type Finder interface {
	Nodes() []*vnode.Node
}

Jump to

Keyboard shortcuts

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