sessions

package
v0.0.0-...-0f7315d Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2016 License: BSD-2-Clause Imports: 6 Imported by: 0

Documentation

Overview

Package sessions implements COOKIE based sessions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Init

func Init(url.Values)

Init is a function that is used for initialization of Sessions controller.

Types

type Sessions

type Sessions struct {
	Session map[string]string

	Request  *http.Request       `bind:"request"`
	Response http.ResponseWriter `bind:"response"`
}

Sessions is a controller that makes Session field available for your actions when you're using this controller as a parent.

func (*Sessions) After

func (c *Sessions) After() http.Handler

After is a magic action that will be executed at the very end of request life cycle and is responsible for creating a signed cookie with session info.

func (*Sessions) Before

func (c *Sessions) Before() http.Handler

Before is a magic action that gets session info from a request and initializes Session field.

Jump to

Keyboard shortcuts

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