http

package
v0.0.0-...-9ccd474 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2022 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Overview

Package http can download objects from HTTP server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

func New

func New(config *Config) *Client

func (*Client) CanonicalURI

func (c *Client) CanonicalURI(uri string) (string, error)

CanonicalURI implements gate/server.Source.CanonicalURI.

func (*Client) OpenURI

func (c *Client) OpenURI(ctx context.Context, uri string, maxSize int) (io.ReadCloser, int64, error)

OpenURI implements gate/server.Source.OpenURI.

type Config

type Config struct {
	Addr   string
	Client *http.Client
}

func (*Config) Configured

func (c *Config) Configured() bool

Jump to

Keyboard shortcuts

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