coreutils

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2020 License: Apache-2.0 Imports: 14 Imported by: 1

Documentation

Overview

Code generated by go generate via internal/cmd/coreutils; DO NOT EDIT.

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrServicerNotImplemented will return when service doesn't implement Servicer.
	ErrServicerNotImplemented = errors.New("servicer not implemented")
	// ErrStoragerNotImplemented will return when service doesn't implement Storager.
	ErrStoragerNotImplemented = errors.New("storager not implemented")
)

Functions

func Open

func Open(t string, opt ...*types.Pair) (srv storage.Servicer, store storage.Storager, err error)

Open will parse config string and return valid Servicer and Storager.

Depends on config string's service type, Servicer could be nil. Depends on config string's content, Storager could be nil if namespace not given.

func OpenServicer

func OpenServicer(t string, opt ...*types.Pair) (srv storage.Servicer, err error)

OpenServicer will open a servicer from config string.

func OpenStorager

func OpenStorager(t string, opt ...*types.Pair) (store storage.Storager, err error)

OpenStorager will open a storager from config string.

Types

type OpenError added in v0.8.0

type OpenError struct {
	Err error

	Type  string
	Pairs []*types.Pair
}

OpenError returned while open related error happens.

func (*OpenError) Error added in v0.8.0

func (e *OpenError) Error() string

func (*OpenError) Unwrap added in v0.8.0

func (e *OpenError) Unwrap() error

Unwrap implements xerrors.Wrapper

Jump to

Keyboard shortcuts

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