handler

package
v0.5.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 29, 2022 License: Apache-2.0, MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FinderHandler

type FinderHandler struct {
	// contains filtered or unexported fields
}

FinderHandler provides request handling functionality for the finder server that is common to all protocols.

func NewFinderHandler

func NewFinderHandler(indexer indexer.Interface, registry *registry.Registry, indexCounts *counter.IndexCounts) *FinderHandler

func (*FinderHandler) Close added in v0.5.2

func (h *FinderHandler) Close()

func (*FinderHandler) Find

func (h *FinderHandler) Find(mhashes []multihash.Multihash) (*model.FindResponse, error)

Find reads from indexer core to populate a response from a list of multihashes.

func (*FinderHandler) GetProvider

func (h *FinderHandler) GetProvider(providerID peer.ID) ([]byte, error)

func (*FinderHandler) GetStats added in v0.4.18

func (h *FinderHandler) GetStats() ([]byte, error)

func (*FinderHandler) ListProviders

func (h *FinderHandler) ListProviders() ([]byte, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL