tstor/daemons/atorrent/peer_store.go

25 lines
581 B
Go
Raw Normal View History

2025-01-07 21:51:28 +00:00
package atorrent
import (
"github.com/anacrolix/dht/v2/krpc"
peer_store "github.com/anacrolix/dht/v2/peer-store"
"github.com/anacrolix/torrent/types/infohash"
"github.com/royalcat/kv"
)
type peerStore struct {
store kv.Store[infohash.T, []krpc.NodeAddr]
}
var _ peer_store.Interface = (*peerStore)(nil)
// AddPeer implements peer_store.Interface.
func (p *peerStore) AddPeer(ih infohash.T, node krpc.NodeAddr) {
panic("unimplemented")
}
// GetPeers implements peer_store.Interface.
func (p *peerStore) GetPeers(ih infohash.T) []krpc.NodeAddr {
panic("unimplemented")
}