Documentation ¶
Index ¶
- func NewNoopLibP2PHost() noopLibP2PHost
- type NetworkSubmodule
- func (networkSubmodule *NetworkSubmodule) API() apiface.INetwork
- func (networkSubmodule *NetworkSubmodule) FetchMessagesByCids(ctx context.Context, cids []cid.Cid) ([]*types.UnsignedMessage, error)
- func (networkSubmodule *NetworkSubmodule) FetchSignedMessagesByCids(ctx context.Context, cids []cid.Cid) ([]*types.SignedMessage, error)
- func (networkSubmodule *NetworkSubmodule) Stop(ctx context.Context)
- func (networkSubmodule *NetworkSubmodule) V0API() apiface.INetwork
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type NetworkSubmodule ¶
type NetworkSubmodule struct { NetworkName string Host host.Host // Router is a router from IPFS Router routing.Routing Pubsub *libp2pps.PubSub // TODO: split chain bitswap from storage bitswap (issue: ???) Bitswap exchange.Interface Network *net.Network GraphExchange graphsync.GraphExchange PeerMgr net.IPeerMgr //data transfer DataTransfer datatransfer.Manager DataTransferHost dtnet.DataTransferNetwork // contains filtered or unexported fields }
NetworkSubmodule enhances the `Node` with networking capabilities.
func NewNetworkSubmodule ¶
func NewNetworkSubmodule(ctx context.Context, config networkConfig) (*NetworkSubmodule, error)
NewNetworkSubmodule creates a new network submodule.
func (*NetworkSubmodule) API ¶
func (networkSubmodule *NetworkSubmodule) API() apiface.INetwork
API create a new network implement
func (*NetworkSubmodule) FetchMessagesByCids ¶
func (networkSubmodule *NetworkSubmodule) FetchMessagesByCids( ctx context.Context, cids []cid.Cid, ) ([]*types.UnsignedMessage, error)
func (*NetworkSubmodule) FetchSignedMessagesByCids ¶
func (networkSubmodule *NetworkSubmodule) FetchSignedMessagesByCids( ctx context.Context, cids []cid.Cid, ) ([]*types.SignedMessage, error)
func (*NetworkSubmodule) Stop ¶
func (networkSubmodule *NetworkSubmodule) Stop(ctx context.Context)
func (*NetworkSubmodule) V0API ¶ added in v0.9.7
func (networkSubmodule *NetworkSubmodule) V0API() apiface.INetwork
Click to show internal directories.
Click to hide internal directories.