Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewExecutableSchema ¶
func NewExecutableSchema(cfg Config) graphql.ExecutableSchema
NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface.
Types ¶
type ComplexityRoot ¶
type ComplexityRoot struct { Judge struct { Code func(childComplexity int) int Configuration func(childComplexity int) int CreatedAt func(childComplexity int) int ID func(childComplexity int) int Name func(childComplexity int) int Problems func(childComplexity int, after *entgql.Cursor[int], first *int, before *entgql.Cursor[int], last *int) int Type func(childComplexity int) int UpdatedAt func(childComplexity int) int } JudgeConnection struct { Edges func(childComplexity int) int PageInfo func(childComplexity int) int TotalCount func(childComplexity int) int } JudgeEdge struct { Cursor func(childComplexity int) int Node func(childComplexity int) int } Mutation struct { CreateJudge func(childComplexity int, input ent.CreateJudgeInput) int CreateProblem func(childComplexity int, input ent.CreateProblemInput) int CreateSubmission func(childComplexity int, input ent.CreateSubmissionInput) int UpdateJudge func(childComplexity int, id int, input ent.UpdateJudgeInput) int UpdateProblem func(childComplexity int, id int, input ent.UpdateProblemInput) int UpdateSubmission func(childComplexity int, id int, input ent.UpdateSubmissionInput) int } PageInfo struct { EndCursor func(childComplexity int) int HasNextPage func(childComplexity int) int HasPreviousPage func(childComplexity int) int StartCursor func(childComplexity int) int } Problem struct { Code func(childComplexity int) int CreatedAt func(childComplexity int) int ID func(childComplexity int) int Judge func(childComplexity int) int Name func(childComplexity int) int Submissions func(childComplexity int, after *entgql.Cursor[int], first *int, before *entgql.Cursor[int], last *int) int UpdatedAt func(childComplexity int) int } ProblemConnection struct { Edges func(childComplexity int) int PageInfo func(childComplexity int) int TotalCount func(childComplexity int) int } ProblemEdge struct { Cursor func(childComplexity int) int Node func(childComplexity int) int } Query struct { Judges func(childComplexity int, after *entgql.Cursor[int], first *int, before *entgql.Cursor[int], last *int) int Node func(childComplexity int, id int) int Nodes func(childComplexity int, ids []int) int Problems func(childComplexity int, after *entgql.Cursor[int], first *int, before *entgql.Cursor[int], last *int) int Submissions func(childComplexity int, after *entgql.Cursor[int], first *int, before *entgql.Cursor[int], last *int) int } Submission struct { CreatedAt func(childComplexity int) int ID func(childComplexity int) int Problem func(childComplexity int) int Status func(childComplexity int) int TestCount func(childComplexity int) int UpdatedAt func(childComplexity int) int Verdict func(childComplexity int) int } SubmissionConnection struct { Edges func(childComplexity int) int PageInfo func(childComplexity int) int TotalCount func(childComplexity int) int } SubmissionEdge struct { Cursor func(childComplexity int) int Node func(childComplexity int) int } }
type Config ¶
type Config struct { Schema *ast.Schema Resolvers ResolverRoot Directives DirectiveRoot Complexity ComplexityRoot }
type DirectiveRoot ¶
type DirectiveRoot struct { }
type MutationResolver ¶
type MutationResolver interface { CreateJudge(ctx context.Context, input ent.CreateJudgeInput) (*ent.Judge, error) UpdateJudge(ctx context.Context, id int, input ent.UpdateJudgeInput) (*ent.Judge, error) CreateProblem(ctx context.Context, input ent.CreateProblemInput) (*ent.Problem, error) UpdateProblem(ctx context.Context, id int, input ent.UpdateProblemInput) (*ent.Problem, error) CreateSubmission(ctx context.Context, input ent.CreateSubmissionInput) (*ent.Submission, error) UpdateSubmission(ctx context.Context, id int, input ent.UpdateSubmissionInput) (*ent.Submission, error) }
type QueryResolver ¶
type QueryResolver interface { Node(ctx context.Context, id int) (ent.Noder, error) Nodes(ctx context.Context, ids []int) ([]ent.Noder, error) Judges(ctx context.Context, after *entgql.Cursor[int], first *int, before *entgql.Cursor[int], last *int) (*ent.JudgeConnection, error) Problems(ctx context.Context, after *entgql.Cursor[int], first *int, before *entgql.Cursor[int], last *int) (*ent.ProblemConnection, error) Submissions(ctx context.Context, after *entgql.Cursor[int], first *int, before *entgql.Cursor[int], last *int) (*ent.SubmissionConnection, error) }
type ResolverRoot ¶
type ResolverRoot interface { Mutation() MutationResolver Query() QueryResolver }
Click to show internal directories.
Click to hide internal directories.