storage

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2019 License: LGPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Empty = iota
	RefreshToken
	AccessToken
	IDToken
)

Variables

This section is empty.

Functions

This section is empty.

Types

type MemoryStorage

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

func Memory

func Memory() *MemoryStorage

func (*MemoryStorage) DeleteToken

func (m *MemoryStorage) DeleteToken(tt TokenType) error

func (*MemoryStorage) GetToken

func (m *MemoryStorage) GetToken(tt TokenType) (string, error)

func (*MemoryStorage) SetToken

func (m *MemoryStorage) SetToken(tt TokenType, token string) error

type Storage

type Storage interface {
	SetToken(TokenType, string) error
	GetToken(TokenType) (string, error)
	DeleteToken(TokenType) error
}

type TokenType

type TokenType int

func (TokenType) String

func (tt TokenType) String() string

Jump to

Keyboard shortcuts

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