Documentation ¶
Index ¶
- func AddrInfo(pid peer.ID, maddrs ...ma.Multiaddr) peer.AddrInfo
- func AddrInfoFromString(aiStr string) peer.AddrInfo
- func AddrInfoSliceToMap(slc []peer.AddrInfo) map[peer.ID]peer.AddrInfo
- func AddrInfoToString(ai peer.AddrInfo) string
- func AddrInfosFromString(sais string) []peer.AddrInfo
- func AddrInfosToString(ais ...peer.AddrInfo) string
- func Discovery(h host.Host, keyword string, bootstraps []peer.AddrInfo) error
- func HostImporter(h host.Host) func(...io.Reader) (host.Host, error)
- func HostToAddrInfo(h host.Host) peer.AddrInfo
- func RandBytes(bSize int) []byte
- func RandString(bSize int) string
- func SampleHost(seeds ...io.Reader) (host.Host, error)
- type DiscoveryDHT
- type HostGenerator
- type IBootstrap
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddrInfoFromString ¶
func AddrInfoToString ¶
func AddrInfosFromString ¶
func AddrInfosToString ¶
func RandString ¶
Types ¶
type DiscoveryDHT ¶
type DiscoveryDHT struct {
// contains filtered or unexported fields
}
func (*DiscoveryDHT) Bootstrap ¶
func (d *DiscoveryDHT) Bootstrap(keyword string, bootstraps []peer.AddrInfo) error
func (*DiscoveryDHT) Close ¶
func (d *DiscoveryDHT) Close()
func (*DiscoveryDHT) DHT ¶
func (d *DiscoveryDHT) DHT() *kad.IpfsDHT
func (*DiscoveryDHT) Discovery ¶
func (d *DiscoveryDHT) Discovery() discovery.Discovery
type IBootstrap ¶
func NewBootstrap ¶
func NewBootstrap(hGen HostGenerator, others ...peer.AddrInfo) (IBootstrap, error)
Click to show internal directories.
Click to hide internal directories.