gateway

package
v0.0.16 Latest Latest
Warning

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

Go to latest
Published: May 3, 2022 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ContentPathPrefix = "/ipfs/"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type GatewayHandler

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

func NewGatewayHandler

func NewGatewayHandler(peer Peer, dag ipld.DAGService, bserv blockservice.BlockService) *GatewayHandler

func (*GatewayHandler) ResolvePath

func (i *GatewayHandler) ResolvePath(ctx context.Context, p path.Path) (path.Resolved, error)

func (*GatewayHandler) ServeHTTP

func (i *GatewayHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)

type Peer

type Peer interface {
	Get(context.Context, cid.Cid) (ipld.Node, error)
}

Jump to

Keyboard shortcuts

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