p2padvt

package
v0.0.14 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2021 License: Unlicense Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var F, E, W, I, D, T log.LevelPrinter = log.GetLogPrinterSet(subsystem)
View Source
var Magic = []byte{'a', 'd', 'v', 1}

Functions

func Get

func Get(uuid uint64, listeners string) []byte

Get returns an advertisment message

Types

type Advertisment

type Advertisment struct {
	// IPs is here stored as an empty struct map so shuffling is automatic
	IPs map[string]struct{}
	// P2P is the port on which the node can be contacted by other peers
	P2P uint16
	// UUID is a unique identifier randomly generated at each initialisation
	UUID uint64
}

Advertisment is the contact details, UUID and services available on a node

Jump to

Keyboard shortcuts

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