Documentation
¶
Index ¶
- type Middleware
- func (c *Middleware) ClientIP() string
- func (c *Middleware) CrumbVal(name string) (*http.Cookie, bool)
- func (c *Middleware) Hostname() string
- func (c *Middleware) Location() *url.URL
- func (c *Middleware) MediaType(mt types.MediaType)
- func (c *Middleware) MetaVal(key string) (string, bool)
- func (c *Middleware) Pathway() string
- func (c *Middleware) Protocol() string
- func (c *Middleware) QueryVal(key string) (string, bool)
- func (c *Middleware) RedirectTo(code int, url string)
- func (c *Middleware) Referral() string
- func (c *Middleware) Request() *http.Request
- func (c *Middleware) Respond(status int, v interface{})
- func (c *Middleware) Response() http.ResponseWriter
- func (c *Middleware) SecureChannel() *tls.ConnectionState
- func (c *Middleware) SetBaggage(key string, value any)
- func (c *Middleware) SetCrumb(cookie *http.Cookie)
- func (c *Middleware) SetHeader(key, value string)
- func (c *Middleware) SetStatus(status int)
- func (c *Middleware) Throw(status int, err interface{})
- func (c *Middleware) UriParam(key string) (string, bool)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Middleware ¶
type Middleware struct {
// contains filtered or unexported fields
}
func NewContext ¶
func NewContext(w *responses.ResponseWriter, r *http.Request) *Middleware
func (*Middleware) ClientIP ¶
func (c *Middleware) ClientIP() string
func (*Middleware) Hostname ¶
func (c *Middleware) Hostname() string
func (*Middleware) Location ¶
func (c *Middleware) Location() *url.URL
func (*Middleware) MediaType ¶
func (c *Middleware) MediaType(mt types.MediaType)
func (*Middleware) Pathway ¶
func (c *Middleware) Pathway() string
func (*Middleware) Protocol ¶
func (c *Middleware) Protocol() string
func (*Middleware) RedirectTo ¶
func (c *Middleware) RedirectTo(code int, url string)
func (*Middleware) Referral ¶
func (c *Middleware) Referral() string
func (*Middleware) Request ¶
func (c *Middleware) Request() *http.Request
func (*Middleware) Respond ¶
func (c *Middleware) Respond(status int, v interface{})
func (*Middleware) Response ¶
func (c *Middleware) Response() http.ResponseWriter
func (*Middleware) SecureChannel ¶
func (c *Middleware) SecureChannel() *tls.ConnectionState
func (*Middleware) SetBaggage ¶
func (c *Middleware) SetBaggage(key string, value any)
func (*Middleware) SetCrumb ¶
func (c *Middleware) SetCrumb(cookie *http.Cookie)
func (*Middleware) SetHeader ¶
func (c *Middleware) SetHeader(key, value string)
func (*Middleware) SetStatus ¶
func (c *Middleware) SetStatus(status int)
func (*Middleware) Throw ¶
func (c *Middleware) Throw(status int, err interface{})
Click to show internal directories.
Click to hide internal directories.