mgostore

package
v0.0.0-...-3df08ef Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2014 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CLIENT_COL    = "clients"
	AUTHORIZE_COL = "authorizations"
	ACCESS_COL    = "accesses"
)

collection names for the entities

View Source
const REFRESHTOKEN = "refreshtoken"

Variables

This section is empty.

Functions

This section is empty.

Types

type MongoStorage

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

func New

func New(session *mgo.Session, dbName string) *MongoStorage

func (*MongoStorage) Clone

func (store *MongoStorage) Clone() osin.Storage

func (*MongoStorage) Close

func (store *MongoStorage) Close()

func (*MongoStorage) GetClient

func (store *MongoStorage) GetClient(id string) (osin.Client, error)

func (*MongoStorage) LoadAccess

func (store *MongoStorage) LoadAccess(token string) (*osin.AccessData, error)

func (*MongoStorage) LoadAuthorize

func (store *MongoStorage) LoadAuthorize(code string) (*osin.AuthorizeData, error)

func (*MongoStorage) LoadRefresh

func (store *MongoStorage) LoadRefresh(token string) (*osin.AccessData, error)

func (*MongoStorage) RemoveAccess

func (store *MongoStorage) RemoveAccess(token string) error

func (*MongoStorage) RemoveAuthorize

func (store *MongoStorage) RemoveAuthorize(code string) error

func (*MongoStorage) RemoveRefresh

func (store *MongoStorage) RemoveRefresh(token string) error

func (*MongoStorage) SaveAccess

func (store *MongoStorage) SaveAccess(data *osin.AccessData) error

func (*MongoStorage) SaveAuthorize

func (store *MongoStorage) SaveAuthorize(data *osin.AuthorizeData) error

func (*MongoStorage) SetClient

func (store *MongoStorage) SetClient(id string, client osin.Client) error

Jump to

Keyboard shortcuts

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