rewrite

package
v0.0.0-...-572ac14 Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2014 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const Type = "rewrite"

Variables

This section is empty.

Functions

func CliFlags

func CliFlags() []cli.Flag

func FromCli

func FromCli(c *cli.Context) (plugin.Middleware, error)

func FromOther

func FromOther(r Rewrite) (plugin.Middleware, error)

func GetSpec

func GetSpec() *plugin.MiddlewareSpec

Types

type Rewrite

type Rewrite struct {
	Regexp      string
	Replacement string
}

type RewriteInstance

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

func NewRewriteInstance

func NewRewriteInstance(regex, replacement string) (*RewriteInstance, error)

func (*RewriteInstance) NewMiddleware

func (r *RewriteInstance) NewMiddleware() (middleware.Middleware, error)

func (*RewriteInstance) ProcessRequest

func (rewrite *RewriteInstance) ProcessRequest(r Request) (*http.Response, error)

func (*RewriteInstance) ProcessResponse

func (*RewriteInstance) ProcessResponse(r Request, a Attempt)

Jump to

Keyboard shortcuts

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