route

package
v0.0.0-...-9a81921 Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2019 License: Apache-2.0 Imports: 31 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MB = 1 << 20
)

Variables

This section is empty.

Functions

func MarshalID

func MarshalID(kind string, spec interface{}) graphql.ID

func UnmarshalKind

func UnmarshalKind(id graphql.ID) string

func UnmarshalSpec

func UnmarshalSpec(id graphql.ID, v interface{}) error

Types

type Asset

type Asset struct {
	ContentType string `json:"content_type,omitempty"`
	Href        string `json:"href,omitempty"`
	ID          string `json:"id,omitempty"`
	Name        string `json:"name,omitempty"`
	Size        int64  `json:"size,omitempty"`
}

type ConfirmVerificationHandler

type ConfirmVerificationHandler struct {
	Conf *myconf.Config
	Db   data.Queryer
}

func (ConfirmVerificationHandler) Cors

func (ConfirmVerificationHandler) ServeHTTP

type GraphQLHandler

type GraphQLHandler struct {
	Conf   *myconf.Config
	Repos  *repo.Repos
	Schema *graphql.Schema
}

func (GraphQLHandler) Cors

func (h GraphQLHandler) Cors() *cors.Cors

func (GraphQLHandler) ServeHTTP

func (h GraphQLHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type GraphQLSchemaHandler

type GraphQLSchemaHandler struct {
	Conf   *myconf.Config
	Schema *graphql.Schema
}

func (GraphQLSchemaHandler) Cors

func (h GraphQLSchemaHandler) Cors() *cors.Cors

func (GraphQLSchemaHandler) ServeHTTP

func (h GraphQLSchemaHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type GraphiQLHandler

type GraphiQLHandler struct {
	Conf *myconf.Config
}

func (GraphiQLHandler) Cors

func (h GraphiQLHandler) Cors() *cors.Cors

func (GraphiQLHandler) ServeHTTP

func (h GraphiQLHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type IndexHandler

type IndexHandler struct{}

func (IndexHandler) ServeHTTP

func (h IndexHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type PreviewHandler

type PreviewHandler struct {
	Conf  *myconf.Config
	Repos *repo.Repos
}

func (PreviewHandler) Cors

func (h PreviewHandler) Cors() *cors.Cors

func (PreviewHandler) ServeHTTP

func (h PreviewHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type RemoveTokenHandler

type RemoveTokenHandler struct {
	Conf *myconf.Config
}

func (RemoveTokenHandler) Cors

func (h RemoveTokenHandler) Cors() *cors.Cors

func (RemoveTokenHandler) ServeHTTP

func (h RemoveTokenHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type SignupHandler

type SignupHandler struct {
	AuthSvc *service.AuthService
	Conf    *myconf.Config
	Db      data.Queryer
}

func (SignupHandler) Cors

func (h SignupHandler) Cors() *cors.Cors

func (SignupHandler) ServeHTTP

func (h SignupHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type SignupSuccessResponse

type SignupSuccessResponse struct {
	AccessToken string              `json:"access_token,omitempty"`
	ExpiresIn   myjwt.UnixTimestamp `json:"expires_in,omitempty"`
}

func (*SignupSuccessResponse) StatusHTTP

func (r *SignupSuccessResponse) StatusHTTP() int

type Sizer

type Sizer interface {
	Size() int64
}

type TokenHandler

type TokenHandler struct {
	AuthSvc *service.AuthService
	Conf    *myconf.Config
	Db      data.Queryer
}

func (TokenHandler) Cors

func (h TokenHandler) Cors() *cors.Cors

func (TokenHandler) ServeHTTP

func (h TokenHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type UploadAssetsHandler

type UploadAssetsHandler struct {
	Conf       *myconf.Config
	Repos      *repo.Repos
	StorageSvc *service.StorageService
}

func (UploadAssetsHandler) Cors

func (h UploadAssetsHandler) Cors() *cors.Cors

func (UploadAssetsHandler) ServeHTTP

func (h UploadAssetsHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type UploadAssetsSuccessResponse

type UploadAssetsSuccessResponse struct {
	Asset Asset `json:"asset,omitempty"`
}

func (*UploadAssetsSuccessResponse) StatusHTTP

func (r *UploadAssetsSuccessResponse) StatusHTTP() int

type UploadHandler

type UploadHandler struct{}

func (UploadHandler) ServeHTTP

func (h UploadHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type UserAssetsHandler

type UserAssetsHandler struct {
	Conf       *myconf.Config
	StorageSvc *service.StorageService
}

UserAssetsHandler - handler for user assets route

func (UserAssetsHandler) Cors

func (h UserAssetsHandler) Cors() *cors.Cors

func (UserAssetsHandler) ServeHTTP

func (h UserAssetsHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

Jump to

Keyboard shortcuts

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