Documentation ¶
Index ¶
- type Content
- type Host
- func (h *Host) Bootstrap(ctx context.Context, network types.NetworkType) error
- func (h *Host) Close() error
- func (h *Host) IsRoutingTableListenerRegistered(listener RoutingTableListener) bool
- func (h *Host) PeerID() string
- func (h *Host) RegisterRoutingTableListener(listener RoutingTableListener)
- func (h *Host) SaveNetworkSizeEstimate(avg float64, std float64, r2 float64, sampleCount int, cpl int, ...)
- func (h *Host) UnregisterRoutingTableListener(listener RoutingTableListener)
- type RoutingTableListener
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Content ¶
type Content struct { CID cid.Cid // contains filtered or unexported fields }
Content encapsulates multiple representations of the same data.
func NewRandomContent ¶
NewRandomContent reads 1024 bytes from crypto/rand and builds a content struct.
type Host ¶
type Host struct { host.Host DBHost *models.Host DHT *kaddht.IpfsDHT Bootstrapped *time.Time StartedAt *time.Time Transports []*wrap.Notifier MsgSender *wrap.MessageSenderImpl // contains filtered or unexported fields }
func (*Host) IsRoutingTableListenerRegistered ¶
func (h *Host) IsRoutingTableListenerRegistered(listener RoutingTableListener) bool
func (*Host) RegisterRoutingTableListener ¶
func (h *Host) RegisterRoutingTableListener(listener RoutingTableListener)
func (*Host) SaveNetworkSizeEstimate ¶
func (*Host) UnregisterRoutingTableListener ¶
func (h *Host) UnregisterRoutingTableListener(listener RoutingTableListener)
Click to show internal directories.
Click to hide internal directories.