module

package
v0.0.0-...-6aff058 Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2018 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddArchiveModule

func AddArchiveModule(exts []string, mod ArchiveModule)

func AddImageModule

func AddImageModule(exts []string, mod ImageModule)

func SupportArchiveType

func SupportArchiveType() []string

func SupportImageType

func SupportImageType() []string

Types

type ArchiveModule

type ArchiveModule interface {
	Open(name string) error
	Close() error
	ReadArchive(vpath string) []os.FileInfo
	ReadFile(name string) (io.ReadCloser, error)
	ReadFileInfo(name string) (os.FileInfo, error)
}

func GetArchiveModule

func GetArchiveModule(ext string) (ArchiveModule, error)

type ImageModule

type ImageModule interface {
	WriteResponse(w http.ResponseWriter, path string) error
	WriteResponseFromReader(w http.ResponseWriter, r io.Reader, size int64) error
}

func GetImageModule

func GetImageModule(ext string) (ImageModule, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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