provider

package
v0.0.0-...-be43ff6 Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2015 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DefaultSession

type DefaultSession struct {
	RemoteSubject     string
	ForceLocalSubject string
	Extra             interface{}
	Token             *oauth2.Token
}

func (*DefaultSession) GetExtra

func (s *DefaultSession) GetExtra() interface{}

func (*DefaultSession) GetForcedLocalSubject

func (s *DefaultSession) GetForcedLocalSubject() string

func (*DefaultSession) GetRemoteSubject

func (s *DefaultSession) GetRemoteSubject() string

func (*DefaultSession) GetToken

func (s *DefaultSession) GetToken() *oauth2.Token

type Provider

type Provider interface {
	GetAuthCodeURL(state string) string
	Exchange(code string) (Session, error)
	GetID() string
}

type Registry

type Registry interface {
	Find(id string) (Provider, error)
}

func NewRegistry

func NewRegistry(providers []Provider) Registry

type Session

type Session interface {
	GetRemoteSubject() string
	GetForcedLocalSubject() string
	GetExtra() interface{}
	GetToken() *oauth2.Token
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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