fileserver

package
v0.0.0-...-18db956 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2023 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Kind is the kind of FileServer.
	Kind = "FileServer"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type FileServer

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

func (*FileServer) Close

func (fsrv *FileServer) Close()

Close closes FileServer.

func (*FileServer) DefaultSpec

func (fsrv *FileServer) DefaultSpec() interface{}

DefaultSpec returns the default spec of FileServer.

func (*FileServer) Description

func (fsrv *FileServer) Description() string

Description returns the description of FileServer

func (*FileServer) Handle

func (fsrv *FileServer) Handle(ctx context.HTTPContext) string

Handle handles HTTP request

func (*FileServer) Inherit

func (fsrv *FileServer) Inherit(filterSpec *httppipeline.FilterSpec, previousGeneration httppipeline.Filter)

Inherit inherits previous generation of FileServer.

func (*FileServer) Init

func (fsrv *FileServer) Init(filterSpec *httppipeline.FilterSpec)

Init initializes FileServer.

func (*FileServer) Kind

func (fsrv *FileServer) Kind() string

Kind returns the kind of FileServer.

func (*FileServer) Results

func (fsrv *FileServer) Results() []string

Results returns the results of FileServer.

func (*FileServer) Status

func (fsrv *FileServer) Status() interface{}

Status returns Status generated by Runtime.

type Spec

type Spec struct {
	FileSystemRaw json.RawMessage

	Root string
	Hide []string
	// The names of files to try as index files if a folder is requested.
	// Default: index.html, index.txt.
	IndexNames []string
	// contains filtered or unexported fields
}

Spec is the spec of file server

Jump to

Keyboard shortcuts

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