p2ptypes

package
v0.0.0-...-3da4c06 Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2022 License: LGPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ResolveAndParseMultiAddrs

func ResolveAndParseMultiAddrs(addrStrings []string) ([]libp2p_peer.AddrInfo, error)

ResolveAndParseMultiAddrs resolve the DNS multi peer and parse to libp2p AddrInfo

func StringsToMultiAddrs

func StringsToMultiAddrs(addrStrings []string) (maddrs []ma.Multiaddr, err error)

StringsToMultiAddrs convert a list of strings to a list of multiaddresses

Types

type AddrList

type AddrList []ma.Multiaddr

AddrList is a list of multi address

func (*AddrList) Set

func (al *AddrList) Set(value string) error

Set is a function to set the value of AddrList based on a string

func (*AddrList) String

func (al *AddrList) String() string

String is a function to print a string representation of the AddrList

type LifeCycle

type LifeCycle interface {
	Start()
	Close()
}

LifeCycle is the interface of module supports Start and Close

type PeerID

type PeerID libp2p_peer.ID

PeerID is the alias for libp2p peer ID

Jump to

Keyboard shortcuts

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