Go API Documentation

github.com/caddyserver/caddy/v2/modules/caddyhttp/encode/brotli

No package summary is available.

Package

Files: 1. Third party imports: 0. Imports from organisation: 0. Tests: 0. Benchmarks: 0.

Vars

Interface guards

var _ encode.Precompressed = (*BrotliPrecompressed)(nil)

Types

BrotliPrecompressed

BrotliPrecompressed provides the file extension for files precompressed with brotli encoding.

type BrotliPrecompressed struct{}

Functions

func (BrotliPrecompressed) AcceptEncoding

AcceptEncoding returns the name of the encoding as used in the Accept-Encoding request headers.

func (BrotliPrecompressed) AcceptEncoding() string	{ return "br" }

Cognitive complexity: 0, Cyclomatic complexity: 1

func (BrotliPrecompressed) CaddyModule

CaddyModule returns the Caddy module information.

func (BrotliPrecompressed) CaddyModule() caddy.ModuleInfo {
	return caddy.ModuleInfo{
		ID:	"http.precompressed.br",
		New:	func() caddy.Module { return new(BrotliPrecompressed) },
	}
}

Cognitive complexity: 2, Cyclomatic complexity: 1

func (BrotliPrecompressed) Suffix

Suffix returns the filename suffix of precompressed files.

func (BrotliPrecompressed) Suffix() string	{ return ".br" }

Cognitive complexity: 0, Cyclomatic complexity: 1

Private functions

func init

init ()