handler

package
v0.0.0-...-e3fd505 Latest Latest
Warning

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

Go to latest
Published: May 10, 2018 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const Email string = "" /* 1212-byte string literal not displayed */

Variables

This section is empty.

Functions

func APICommentHandler

func APICommentHandler(ctx *golf.Context)

APICommentHandler retrieves a comment with the given comment id.

func APICommentPostHandler

func APICommentPostHandler(ctx *golf.Context)

APICommentPostHandler retrives the tag with the given post id.

func APICommentsHandler

func APICommentsHandler(ctx *golf.Context)

APICommentsHandler retrieves all the comments.

func APIDocumentationHandler

func APIDocumentationHandler(routes map[string]map[string]interface{}) golf.HandlerFunc

APIDocumentationHandler shows which routes match with what functionality, similar to https://api.github.com

func APIPostAuthorHandler

func APIPostAuthorHandler(ctx *golf.Context)

APIPostAuthorHandler gets the author of the given post.

func APIPostCommentsHandler

func APIPostCommentsHandler(ctx *golf.Context)

APIPostCommentsHandler gets the comments on the given post.

func APIPostDeleteHandler

func APIPostDeleteHandler(ctx *golf.Context)

APIPostDeleteHandler deletes the post referenced by the post_id.

func APIPostExcerptHandler

func APIPostExcerptHandler(ctx *golf.Context)

APIPostExcerptHandler gets the excerpt of the given post.

func APIPostHandler

func APIPostHandler(ctx *golf.Context)

APIPostHandler retrieves the post with the given ID.

func APIPostPublishHandler

func APIPostPublishHandler(ctx *golf.Context)

APIPostPublishHandler publishes the post referenced by the post_id.

func APIPostSaveHandler

func APIPostSaveHandler(ctx *golf.Context)

APIPostSaveHandler saves the post given in the json-formatted request body.

func APIPostSlugHandler

func APIPostSlugHandler(ctx *golf.Context)

APIPostSlugHandler retrieves the post with the given slug.

func APIPostSummaryHandler

func APIPostSummaryHandler(ctx *golf.Context)

APIPostSummaryHandler gets the summary of the given post.

func APIPostTagStringHandler

func APIPostTagStringHandler(ctx *golf.Context)

APIPostTagStringHandler gets the tag string of the given post.

func APIPostTagsHandler

func APIPostTagsHandler(ctx *golf.Context)

APIPostTagsHandler gets the tags of the given post.

func APIPostsHandler

func APIPostsHandler(offset, limit int) golf.HandlerFunc

APIPostsHandler gets an array of posts of length <= limit, starting at offset. To paginate through posts, increment offset by limit until the length of the post array in the response is less than limit.

func APITagHandler

func APITagHandler(ctx *golf.Context)

APITagHandler retrieves the tag with the given id.

func APITagSlugHandler

func APITagSlugHandler(ctx *golf.Context)

APITagSlugHandler retrieves the tag(s) with the given slug.

func APITagsHandler

func APITagsHandler(ctx *golf.Context)

APITagsHandler retrieves all the tags.

func APIUserEmailHandler

func APIUserEmailHandler(ctx *golf.Context)

APIUserEmailHandler retrieves the user with the given email.

func APIUserHandler

func APIUserHandler(ctx *golf.Context)

APIUserHandler retrieves the user with the given id.

func APIUserSlugHandler

func APIUserSlugHandler(ctx *golf.Context)

APIUserSlugHandler retrives the user with the given slug.

func APIUsersHandler

func APIUsersHandler(ctx *golf.Context)

APIUsersHandler retrieves all users.

func AdminHandler

func AdminHandler(ctx *golf.Context)

func AdminMonitorPage

func AdminMonitorPage(ctx *golf.Context)

func AdminPageHandler

func AdminPageHandler(ctx *golf.Context)

func AdminPasswordChange

func AdminPasswordChange(ctx *golf.Context)

func AdminPasswordPage

func AdminPasswordPage(ctx *golf.Context)

func AdminPostHandler

func AdminPostHandler(ctx *golf.Context)

func AuthLoginHandler

func AuthLoginHandler(ctx *golf.Context)

func AuthLoginPageHandler

func AuthLoginPageHandler(ctx *golf.Context)

func AuthLogoutHandler

func AuthLogoutHandler(ctx *golf.Context)

func AuthMiddleware

func AuthMiddleware(next golf.HandlerFunc) golf.HandlerFunc

func AuthSignUpHandler

func AuthSignUpHandler(ctx *golf.Context)

func AuthSignUpPageHandler

func AuthSignUpPageHandler(ctx *golf.Context)

func CommentAddHandler

func CommentAddHandler(ctx *golf.Context)

func CommentHandler

func CommentHandler(ctx *golf.Context)

func CommentRemoveHandler

func CommentRemoveHandler(ctx *golf.Context)

func CommentUpdateHandler

func CommentUpdateHandler(ctx *golf.Context)

func CommentViewHandler

func CommentViewHandler(ctx *golf.Context)

func ContentEditHandler

func ContentEditHandler(ctx *golf.Context)

func ContentHandler

func ContentHandler(ctx *golf.Context)

func ContentRemoveHandler

func ContentRemoveHandler(ctx *golf.Context)

func ContentSaveHandler

func ContentSaveHandler(ctx *golf.Context)

func FileRemoveHandler

func FileRemoveHandler(ctx *golf.Context)

func FileUploadHandler

func FileUploadHandler(ctx *golf.Context)

func FileViewHandler

func FileViewHandler(ctx *golf.Context)

func HomeHandler

func HomeHandler(ctx *golf.Context)

func Initialize

func Initialize(app *golf.Application) *golf.Application

func JWTAuthLoginHandler

func JWTAuthLoginHandler(ctx *golf.Context)

func JWTAuthMiddleware

func JWTAuthMiddleware(next golf.HandlerFunc) golf.HandlerFunc

func JWTDecryptHandler

func JWTDecryptHandler(ctx *golf.Context)

func NotFoundHandler

func NotFoundHandler(ctx *golf.Context, data ...map[string]interface{})

func PageCreateHandler

func PageCreateHandler(ctx *golf.Context)

func PageSaveHandler

func PageSaveHandler(ctx *golf.Context)

func PostCreateHandler

func PostCreateHandler(ctx *golf.Context)

func PostSaveHandler

func PostSaveHandler(ctx *golf.Context)

func ProfileChangeHandler

func ProfileChangeHandler(ctx *golf.Context)

func ProfileHandler

func ProfileHandler(ctx *golf.Context)

func RegisterFunctions

func RegisterFunctions(app *golf.Application)

func RssHandler

func RssHandler(ctx *golf.Context)

func SettingCustomHandler

func SettingCustomHandler(ctx *golf.Context)

func SettingNavHandler

func SettingNavHandler(ctx *golf.Context)

func SettingUpdateHandler

func SettingUpdateHandler(ctx *golf.Context)

func SettingViewHandler

func SettingViewHandler(ctx *golf.Context)

func SiteMapHandler

func SiteMapHandler(ctx *golf.Context)

func TagHandler

func TagHandler(ctx *golf.Context)

Types

type APIResponseBodyJSON

type APIResponseBodyJSON struct {
	Data   interface{}   `json:"data"`
	Status APIStatusJSON `json:"status"`
}

func NewAPISuccessResponse

func NewAPISuccessResponse(data interface{}, msgs ...string) APIResponseBodyJSON

func (APIResponseBodyJSON) Serialize

func (body APIResponseBodyJSON) Serialize() []byte

type APISerializeable

type APISerializeable interface {
	Serialize() []byte
}

type APIStatusJSON

type APIStatusJSON struct {
	Status  string `json:"status"`
	Message string `json:"message"`
}

func NewErrorStatusJSON

func NewErrorStatusJSON(msgs ...string) APIStatusJSON

func NewSuccessStatusJSON

func NewSuccessStatusJSON(msgs ...string) APIStatusJSON

func (APIStatusJSON) Serialize

func (status APIStatusJSON) Serialize() []byte

type JWTPostBody

type JWTPostBody struct {
	Email    string `json:"email"`
	Password string `json:"password"`
}

Jump to

Keyboard shortcuts

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