reader

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2019 License: BSD-3-Clause Imports: 9 Imported by: 11 modules, 16 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CacheReader

type CacheReader struct {
	Reader
	// contains filtered or unexported fields
}

func (*CacheReader) Read

func (r *CacheReader) Read(key string) (io.ReadCloser, error)

type CacheReaderOptions

type CacheReaderOptions struct {
	Debug  bool
	Strict bool
}

func NewDefaultCacheReaderOptions

func NewDefaultCacheReaderOptions() (*CacheReaderOptions, error)

type FSReader

type FSReader struct {
	Reader
	// contains filtered or unexported fields
}

func (*FSReader) Read

func (r *FSReader) Read(path string) (io.ReadCloser, error)

func (*FSReader) URI

func (r *FSReader) URI(path string) string

type MultiReader

type MultiReader struct {
	Reader
	// contains filtered or unexported fields
}

func (*MultiReader) Read

func (mr *MultiReader) Read(uri string) (io.ReadCloser, error)

func (*MultiReader) URI

func (mr *MultiReader) URI(uri string) string

type NullReader

type NullReader struct {
	Reader
}

func (*NullReader) Read

func (r *NullReader) Read(uri string) (io.ReadCloser, error)

func (*NullReader) URI

func (r *NullReader) URI(uri string) string

type Reader

type Reader interface {
	Read(string) (io.ReadCloser, error)
	URI(string) string
}

func NewCacheReader

func NewCacheReader(r Reader, c cache.Cache, opts *CacheReaderOptions) (Reader, error)

func NewFSReader

func NewFSReader(root string) (Reader, error)

func NewMultiReader

func NewMultiReader(readers ...Reader) (Reader, error)

func NewMultiReaderFromStrings

func NewMultiReaderFromStrings(dsn_strings ...string) (Reader, error)

func NewNullReader

func NewNullReader() (Reader, error)

Jump to

Keyboard shortcuts

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