google

package
v0.0.0-...-576eb72 Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2014 License: MPL-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PlusScope    = "https://www.googleapis.com/auth/plus.login"
	EmailScope   = "https://www.googleapis.com/auth/plus.profile.emails.read"
	ProfileScope = "profile"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AgeRange

type AgeRange struct {
	Min int
	Max int
}

type App

type App struct {
	*oauth2.Client
}

func (*App) Clone

func (a *App) Clone(ctx httpclient.Context) *App

func (*App) Parse

func (a *App) Parse(s string) error

func (*App) Person

func (a *App) Person(id string, accessToken string) (*Person, error)

func (*App) Refresh

func (a *App) Refresh(refresh string) (*oauth2.Token, error)

func (*App) Stats

func (a *App) Stats(urls []string) (map[string]*Stats, error)

type Error

type Error struct {
	Code    int
	Message string
}

func (*Error) Error

func (e *Error) Error() string

type Name

type Name struct {
	Display string
	Given   string
	Family  string
}

type Person

type Person struct {
	Id         string
	Name       Name
	Image      string
	URL        string
	Emails     []*Value
	Links      []*Value
	Gender     string
	Occupation string
	Age        AgeRange
	Lang       string
}

func (*Person) UnmarshalJSON

func (p *Person) UnmarshalJSON(data []byte) error

type Stats

type Stats struct {
	Normalized string
	Count      int
}

type Value

type Value struct {
	Value string
	Type  string
	Label string
}

Jump to

Keyboard shortcuts

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