handlers

package
v0.1.0-alpha.7 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2021 License: MIT Imports: 4 Imported by: 0

README

handlers

These functions decide if the request should be cached. They accept the parsed config, a http.ResponseWriter, and a http.Request.

There are handlers for the following:

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Cookie(c config.Config, w http.ResponseWriter, r *http.Request) bool

Cookie compares the config cookie values against the ones sent by the request and if one matches, we want to bypass the cache.

func Method

func Method(c config.Config, w http.ResponseWriter, r *http.Request) bool

Method checks the config methods we should cache against the request method and determines whether or not this request should be cached.

func URI

URI takes the config Bypass and checks those URIs against the current request uri to see if it matches. If it does, we return true because we should bypass this requeust.

Types

This section is empty.

Jump to

Keyboard shortcuts

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