rest

package
v0.8.3 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2018 License: BSD-2-Clause Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Create

func Create(cfg Config, rt http.RoundTripper) (restic.Backend, error)

Create creates a new REST on server configured in config.

func Open

func Open(cfg Config, rt http.RoundTripper) (*restBackend, error)

Open opens the REST backend with the given config.

func ParseConfig

func ParseConfig(s string) (interface{}, error)

ParseConfig parses the string s and extracts the REST server URL.

Types

type Config

type Config struct {
	URL         *url.URL
	Connections uint `option:"connections" help:"set a limit for the number of concurrent connections (default: 5)"`
}

Config contains all configuration necessary to connect to a REST server.

func NewConfig

func NewConfig() Config

NewConfig returns a new Config with the default values filled in.

type ErrIsNotExist

type ErrIsNotExist struct {
	restic.Handle
}

ErrIsNotExist is returned whenever the requested file does not exist on the server.

func (ErrIsNotExist) Error

func (e ErrIsNotExist) Error() string

Jump to

Keyboard shortcuts

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