Documentation ¶
Index ¶
- type Lassie
- func (l *Lassie) Fetch(ctx context.Context, rootCid cid.Cid, linkSystem linking.LinkSystem) (types.RetrievalID, *types.RetrievalStats, error)
- func (l *Lassie) RegisterSubscriber(subscriber types.RetrievalEventSubscriber) func()
- func (l *Lassie) Retrieve(ctx context.Context, request types.RetrievalRequest) (*types.RetrievalStats, error)
- type LassieConfig
- type LassieOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Lassie ¶
type Lassie struct {
// contains filtered or unexported fields
}
func NewLassieWithConfig ¶
func NewLassieWithConfig(ctx context.Context, cfg *LassieConfig) (*Lassie, error)
func (*Lassie) Fetch ¶
func (l *Lassie) Fetch(ctx context.Context, rootCid cid.Cid, linkSystem linking.LinkSystem) (types.RetrievalID, *types.RetrievalStats, error)
func (*Lassie) RegisterSubscriber ¶
func (l *Lassie) RegisterSubscriber(subscriber types.RetrievalEventSubscriber) func()
func (*Lassie) Retrieve ¶ added in v0.4.0
func (l *Lassie) Retrieve(ctx context.Context, request types.RetrievalRequest) (*types.RetrievalStats, error)
type LassieConfig ¶
type LassieOption ¶
type LassieOption func(cfg *LassieConfig)
func WithFinder ¶
func WithFinder(finder retriever.CandidateFinder) LassieOption
func WithGlobalTimeout ¶ added in v0.4.0
func WithGlobalTimeout(timeout time.Duration) LassieOption
func WithHost ¶ added in v0.4.0
func WithHost(host host.Host) LassieOption
func WithLibp2pOpts ¶ added in v0.4.4
func WithLibp2pOpts(libp2pOptions ...libp2p.Option) LassieOption
func WithProviderTimeout ¶ added in v0.4.0
func WithProviderTimeout(timeout time.Duration) LassieOption
Click to show internal directories.
Click to hide internal directories.