Documentation ¶
Index ¶
- type MockRouter
- func (m *MockRouter) Advertise(ctx context.Context, keys []string) error
- func (m *MockRouter) Close() error
- func (m *MockRouter) LookupKey(key string) ([]string, bool)
- func (m *MockRouter) Net() peernet.Network
- func (m *MockRouter) Resolve(ctx context.Context, key string, allowSelf bool, count int) (<-chan routing.PeerInfo, error)
- func (m *MockRouter) ResolveWithCache(ctx context.Context, key string, allowSelf bool, count int) (<-chan routing.PeerInfo, func(), error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockRouter ¶
type MockRouter struct {
// contains filtered or unexported fields
}
func NewMockRouter ¶
func NewMockRouter(resolver map[string][]string) *MockRouter
func (*MockRouter) Advertise ¶
func (m *MockRouter) Advertise(ctx context.Context, keys []string) error
func (*MockRouter) Close ¶
func (m *MockRouter) Close() error
Click to show internal directories.
Click to hide internal directories.