Documentation ¶
Index ¶
- func GenKey(dir string) (ic.PrivKey, error)
- func GenSwarm() *swarm.Swarm
- func GenSwarm2() (*swarm.Swarm, *tptu.Upgrader)
- func GenSwarmByKey(key ic.PrivKey) (*swarm.Swarm, *tptu.Upgrader)
- func GenUpgrader(n *swarm.Swarm) *tptu.Upgrader
- func LoadKey(dir string) (ic.PrivKey, error)
- type MyID
- type Node
- func (self *Node) Bootstrap(ctx context.Context) error
- func (self *Node) Close()
- func (self *Node) Connect(ctx context.Context, targetID interface{}, targetAddrs []ma.Multiaddr) error
- func (self *Node) FindPeer(ctx context.Context, targetID interface{}) (pstore.PeerInfo, error)
- func (self *Node) GetValue(ctx context.Context, key string) ([]byte, error)
- func (self *Node) PutValue(ctx context.Context, key string, value []byte) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenUpgrader ¶
GenUpgrader creates a new connection upgrader for use with this swarm.
Types ¶
Click to show internal directories.
Click to hide internal directories.