Documentation ¶
Index ¶
Constants ¶
View Source
const GIN_JUDGER = "github.com/syzoj/syzoj-ng-go/svc/app.judger"
View Source
const GIN_USER_ID = "USER_ID"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type App ¶
type App struct { Db *sql.DB ListenAddr string Redis *svcredis.RedisService // The persistent redis instance. No eviction policies allowed. RedisCache *svcredis.RedisService JudgeService *judge.JudgeService EmailService *email.EmailService // optional JudgeToken string }
func DefaultApp ¶
func DefaultApp(db *sql.DB, redis *svcredis.RedisService, redisCache *svcredis.RedisService, listenAddr string, judgeService *judge.JudgeService) *App
func (*App) UserMiddleware ¶
type ForgetRequest ¶
type ForgetRequest struct {
Email string `json:"email" form:"email"`
}
type GetProblemResponse ¶
type GetProblemsResponse ¶
type GetProblemsResponse struct {
Problems []*GetProblemsResponseProblem
}
type HeaderResponse ¶
type IndexResponse ¶
type IndexResponse struct { Divine *divine.Divine Ranklist []*IndexResponseUser `json:"ranklist"` Notices []*IndexResponseNotice `json:"notices"` Contests []*IndexResponseContest `json:"contests"` Problems []*IndexResponseProblem `json:"problems"` }
type IndexResponseContest ¶
type IndexResponseNotice ¶
type IndexResponseProblem ¶
type IndexResponseUser ¶
type LoginRequest ¶
type TaskResult ¶
type TaskResult struct { Id string `json:"id"` Sid string `json:"sid"` Type string `json:"type"` Data json.RawMessage `json:"data"` }
Click to show internal directories.
Click to hide internal directories.