Documentation
¶
Index ¶
- type Builder
- func (builder *Builder) Build() *Node
- func (builder *Builder) WithAddr(addr wire.Address) *Builder
- func (builder *Builder) WithContentResolver(contentResolver dht.ContentResolver) *Builder
- func (builder *Builder) WithHost(host string) *Builder
- func (builder *Builder) WithPort(port uint16) *Builder
- func (builder *Builder) WithPrivKey(privKey *id.PrivKey) *Builder
- type ContentResolver
- type Node
- func (node *Node) Addr() wire.Address
- func (node *Node) Broadcast(ctx context.Context, subnet id.Hash, dataType uint8, data []byte)
- func (node *Node) DHT() dht.DHT
- func (node *Node) Gossiper() *gossip.Gossiper
- func (node *Node) Identity() id.Signatory
- func (node *Node) Peer() *peer.Peer
- func (node *Node) Run(ctx context.Context)
- func (node *Node) Send(ctx context.Context, signatory id.Signatory, dataType uint8, data []byte)
- func (node *Node) Sync(ctx context.Context, subnet, hash id.Hash, dataType uint8) ([]byte, error)
- func (node *Node) Transport() *transport.Transport
- type Options
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Builder ¶ added in v0.4.0
type Builder struct {
// contains filtered or unexported fields
}
func (*Builder) WithContentResolver ¶
func (builder *Builder) WithContentResolver(contentResolver dht.ContentResolver) *Builder
type ContentResolver ¶
type ContentResolver = dht.ContentResolver
Click to show internal directories.
Click to hide internal directories.