disk

package
v1.14.0 Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2020 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New() serving.Serving

New returns a serving instance that is capable of reading files from the disk

Types

type Reader

type Reader struct {
}

Reader is a disk access driver

type Serving

type Serving struct {
	Reader
}

Serving describes a disk access serving

func (*Serving) ServeFileHTTP

func (s *Serving) ServeFileHTTP(h serving.Handler) bool

ServeFileHTTP serves a file from disk and returns true. It returns false when a file could not been found.

func (*Serving) ServeNotFoundHTTP

func (s *Serving) ServeNotFoundHTTP(h serving.Handler)

ServeNotFoundHTTP tries to read a custom 404 page

Jump to

Keyboard shortcuts

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