graph

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2022 License: GPL-3.0 Imports: 19 Imported by: 0

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 AddCommentOperationResolver

type AddCommentOperationResolver interface {
	Author(ctx context.Context, obj *bug.AddCommentOperation) (models.IdentityWrapper, error)
	Date(ctx context.Context, obj *bug.AddCommentOperation) (*time.Time, error)
}

type BugResolver

type BugResolver interface {
	HumanID(ctx context.Context, obj models.BugWrapper) (string, error)

	Actors(ctx context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error)
	Participants(ctx context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error)
	Comments(ctx context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.CommentConnection, error)
	Timeline(ctx context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.TimelineItemConnection, error)
	Operations(ctx context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.OperationConnection, error)
}

type ColorResolver

type ColorResolver interface {
	R(ctx context.Context, obj *color.RGBA) (int, error)
	G(ctx context.Context, obj *color.RGBA) (int, error)
	B(ctx context.Context, obj *color.RGBA) (int, error)
}

type CommentHistoryStepResolver

type CommentHistoryStepResolver interface {
	Date(ctx context.Context, obj *bug.CommentHistoryStep) (*time.Time, error)
}

type CommentResolver

type CommentResolver interface {
	ID(ctx context.Context, obj *bug.Comment) (entity.CombinedId, error)
	Author(ctx context.Context, obj *bug.Comment) (models.IdentityWrapper, error)
}

type ComplexityRoot

type ComplexityRoot struct {
	AddCommentAndCloseBugPayload struct {
		Bug              func(childComplexity int) int
		ClientMutationID func(childComplexity int) int
		CommentOperation func(childComplexity int) int
		StatusOperation  func(childComplexity int) int
	}

	AddCommentAndReopenBugPayload struct {
		Bug              func(childComplexity int) int
		ClientMutationID func(childComplexity int) int
		CommentOperation func(childComplexity int) int
		StatusOperation  func(childComplexity int) int
	}

	AddCommentOperation struct {
		Author  func(childComplexity int) int
		Date    func(childComplexity int) int
		Files   func(childComplexity int) int
		Id      func(childComplexity int) int
		Message func(childComplexity int) int
	}

	AddCommentPayload struct {
		Bug              func(childComplexity int) int
		ClientMutationID func(childComplexity int) int
		Operation        func(childComplexity int) int
	}

	AddCommentTimelineItem struct {
		Author         func(childComplexity int) int
		CreatedAt      func(childComplexity int) int
		Edited         func(childComplexity int) int
		Files          func(childComplexity int) int
		History        func(childComplexity int) int
		ID             func(childComplexity int) int
		LastEdit       func(childComplexity int) int
		Message        func(childComplexity int) int
		MessageIsEmpty func(childComplexity int) int
	}

	Bug struct {
		Actors       func(childComplexity int, after *string, before *string, first *int, last *int) int
		Author       func(childComplexity int) int
		Comments     func(childComplexity int, after *string, before *string, first *int, last *int) int
		CreatedAt    func(childComplexity int) int
		HumanID      func(childComplexity int) int
		Id           func(childComplexity int) int
		Labels       func(childComplexity int) int
		LastEdit     func(childComplexity int) int
		Operations   func(childComplexity int, after *string, before *string, first *int, last *int) int
		Participants func(childComplexity int, after *string, before *string, first *int, last *int) int
		Status       func(childComplexity int) int
		Timeline     func(childComplexity int, after *string, before *string, first *int, last *int) int
		Title        func(childComplexity int) int
	}

	BugConnection struct {
		Edges      func(childComplexity int) int
		Nodes      func(childComplexity int) int
		PageInfo   func(childComplexity int) int
		TotalCount func(childComplexity int) int
	}

	BugEdge struct {
		Cursor func(childComplexity int) int
		Node   func(childComplexity int) int
	}

	ChangeLabelPayload struct {
		Bug              func(childComplexity int) int
		ClientMutationID func(childComplexity int) int
		Operation        func(childComplexity int) int
		Results          func(childComplexity int) int
	}

	CloseBugPayload struct {
		Bug              func(childComplexity int) int
		ClientMutationID func(childComplexity int) int
		Operation        func(childComplexity int) int
	}

	Color struct {
		B func(childComplexity int) int
		G func(childComplexity int) int
		R func(childComplexity int) int
	}

	Comment struct {
		Author  func(childComplexity int) int
		Files   func(childComplexity int) int
		ID      func(childComplexity int) int
		Message func(childComplexity int) int
	}

	CommentConnection struct {
		Edges      func(childComplexity int) int
		Nodes      func(childComplexity int) int
		PageInfo   func(childComplexity int) int
		TotalCount func(childComplexity int) int
	}

	CommentEdge struct {
		Cursor func(childComplexity int) int
		Node   func(childComplexity int) int
	}

	CommentHistoryStep struct {
		Date    func(childComplexity int) int
		Message func(childComplexity int) int
	}

	CreateOperation struct {
		Author  func(childComplexity int) int
		Date    func(childComplexity int) int
		Files   func(childComplexity int) int
		Id      func(childComplexity int) int
		Message func(childComplexity int) int
		Title   func(childComplexity int) int
	}

	CreateTimelineItem struct {
		Author         func(childComplexity int) int
		CreatedAt      func(childComplexity int) int
		Edited         func(childComplexity int) int
		Files          func(childComplexity int) int
		History        func(childComplexity int) int
		ID             func(childComplexity int) int
		LastEdit       func(childComplexity int) int
		Message        func(childComplexity int) int
		MessageIsEmpty func(childComplexity int) int
	}

	EditCommentOperation struct {
		Author  func(childComplexity int) int
		Date    func(childComplexity int) int
		Files   func(childComplexity int) int
		Id      func(childComplexity int) int
		Message func(childComplexity int) int
		Target  func(childComplexity int) int
	}

	EditCommentPayload struct {
		Bug              func(childComplexity int) int
		ClientMutationID func(childComplexity int) int
		Operation        func(childComplexity int) int
	}

	Identity struct {
		AvatarUrl   func(childComplexity int) int
		DisplayName func(childComplexity int) int
		Email       func(childComplexity int) int
		HumanID     func(childComplexity int) int
		Id          func(childComplexity int) int
		IsProtected func(childComplexity int) int
		Login       func(childComplexity int) int
		Name        func(childComplexity int) int
	}

	IdentityConnection struct {
		Edges      func(childComplexity int) int
		Nodes      func(childComplexity int) int
		PageInfo   func(childComplexity int) int
		TotalCount func(childComplexity int) int
	}

	IdentityEdge struct {
		Cursor func(childComplexity int) int
		Node   func(childComplexity int) int
	}

	Label struct {
		Color func(childComplexity int) int
		Name  func(childComplexity int) int
	}

	LabelChangeOperation struct {
		Added   func(childComplexity int) int
		Author  func(childComplexity int) int
		Date    func(childComplexity int) int
		Id      func(childComplexity int) int
		Removed func(childComplexity int) int
	}

	LabelChangeResult struct {
		Label  func(childComplexity int) int
		Status func(childComplexity int) int
	}

	LabelChangeTimelineItem struct {
		Added   func(childComplexity int) int
		Author  func(childComplexity int) int
		Date    func(childComplexity int) int
		ID      func(childComplexity int) int
		Removed func(childComplexity int) int
	}

	LabelConnection struct {
		Edges      func(childComplexity int) int
		Nodes      func(childComplexity int) int
		PageInfo   func(childComplexity int) int
		TotalCount func(childComplexity int) int
	}

	LabelEdge struct {
		Cursor func(childComplexity int) int
		Node   func(childComplexity int) int
	}

	Mutation struct {
		AddComment          func(childComplexity int, input models.AddCommentInput) int
		AddCommentAndClose  func(childComplexity int, input models.AddCommentAndCloseBugInput) int
		AddCommentAndReopen func(childComplexity int, input models.AddCommentAndReopenBugInput) int
		ChangeLabels        func(childComplexity int, input *models.ChangeLabelInput) int
		CloseBug            func(childComplexity int, input models.CloseBugInput) int
		EditComment         func(childComplexity int, input models.EditCommentInput) int
		NewBug              func(childComplexity int, input models.NewBugInput) int
		OpenBug             func(childComplexity int, input models.OpenBugInput) int
		SetTitle            func(childComplexity int, input models.SetTitleInput) int
	}

	NewBugPayload struct {
		Bug              func(childComplexity int) int
		ClientMutationID func(childComplexity int) int
		Operation        func(childComplexity int) int
	}

	OpenBugPayload struct {
		Bug              func(childComplexity int) int
		ClientMutationID func(childComplexity int) int
		Operation        func(childComplexity int) int
	}

	OperationConnection struct {
		Edges      func(childComplexity int) int
		Nodes      func(childComplexity int) int
		PageInfo   func(childComplexity int) int
		TotalCount func(childComplexity int) int
	}

	OperationEdge struct {
		Cursor func(childComplexity int) int
		Node   func(childComplexity int) int
	}

	PageInfo struct {
		EndCursor       func(childComplexity int) int
		HasNextPage     func(childComplexity int) int
		HasPreviousPage func(childComplexity int) int
		StartCursor     func(childComplexity int) int
	}

	Query struct {
		Repository func(childComplexity int, ref *string) int
	}

	Repository struct {
		AllBugs       func(childComplexity int, after *string, before *string, first *int, last *int, query *string) int
		AllIdentities func(childComplexity int, after *string, before *string, first *int, last *int) int
		Bug           func(childComplexity int, prefix string) int
		Identity      func(childComplexity int, prefix string) int
		Name          func(childComplexity int) int
		UserIdentity  func(childComplexity int) int
		ValidLabels   func(childComplexity int, after *string, before *string, first *int, last *int) int
	}

	SetStatusOperation struct {
		Author func(childComplexity int) int
		Date   func(childComplexity int) int
		Id     func(childComplexity int) int
		Status func(childComplexity int) int
	}

	SetStatusTimelineItem struct {
		Author func(childComplexity int) int
		Date   func(childComplexity int) int
		ID     func(childComplexity int) int
		Status func(childComplexity int) int
	}

	SetTitleOperation struct {
		Author func(childComplexity int) int
		Date   func(childComplexity int) int
		Id     func(childComplexity int) int
		Title  func(childComplexity int) int
		Was    func(childComplexity int) int
	}

	SetTitlePayload struct {
		Bug              func(childComplexity int) int
		ClientMutationID func(childComplexity int) int
		Operation        func(childComplexity int) int
	}

	SetTitleTimelineItem struct {
		Author func(childComplexity int) int
		Date   func(childComplexity int) int
		ID     func(childComplexity int) int
		Title  func(childComplexity int) int
		Was    func(childComplexity int) int
	}

	TimelineItemConnection struct {
		Edges      func(childComplexity int) int
		Nodes      func(childComplexity int) int
		PageInfo   func(childComplexity int) int
		TotalCount func(childComplexity int) int
	}

	TimelineItemEdge struct {
		Cursor func(childComplexity int) int
		Node   func(childComplexity int) int
	}
}

type Config

type Config struct {
	Resolvers  ResolverRoot
	Directives DirectiveRoot
	Complexity ComplexityRoot
}

type CreateOperationResolver

type CreateOperationResolver interface {
	Author(ctx context.Context, obj *bug.CreateOperation) (models.IdentityWrapper, error)
	Date(ctx context.Context, obj *bug.CreateOperation) (*time.Time, error)
}

type CreateTimelineItemResolver

type CreateTimelineItemResolver interface {
	ID(ctx context.Context, obj *bug.CreateTimelineItem) (entity.CombinedId, error)
	Author(ctx context.Context, obj *bug.CreateTimelineItem) (models.IdentityWrapper, error)

	CreatedAt(ctx context.Context, obj *bug.CreateTimelineItem) (*time.Time, error)
	LastEdit(ctx context.Context, obj *bug.CreateTimelineItem) (*time.Time, error)
}

type DirectiveRoot

type DirectiveRoot struct {
}

type EditCommentOperationResolver

type EditCommentOperationResolver interface {
	Author(ctx context.Context, obj *bug.EditCommentOperation) (models.IdentityWrapper, error)
	Date(ctx context.Context, obj *bug.EditCommentOperation) (*time.Time, error)
	Target(ctx context.Context, obj *bug.EditCommentOperation) (string, error)
}

type IdentityResolver

type IdentityResolver interface {
	HumanID(ctx context.Context, obj models.IdentityWrapper) (string, error)
}

type LabelChangeOperationResolver

type LabelChangeOperationResolver interface {
	Author(ctx context.Context, obj *bug.LabelChangeOperation) (models.IdentityWrapper, error)
	Date(ctx context.Context, obj *bug.LabelChangeOperation) (*time.Time, error)
}

type LabelResolver

type LabelResolver interface {
	Name(ctx context.Context, obj *bug.Label) (string, error)
	Color(ctx context.Context, obj *bug.Label) (*color.RGBA, error)
}

type QueryResolver

type QueryResolver interface {
	Repository(ctx context.Context, ref *string) (*models.Repository, error)
}

type RepositoryResolver

type RepositoryResolver interface {
	Name(ctx context.Context, obj *models.Repository) (*string, error)
	AllBugs(ctx context.Context, obj *models.Repository, after *string, before *string, first *int, last *int, query *string) (*models.BugConnection, error)
	Bug(ctx context.Context, obj *models.Repository, prefix string) (models.BugWrapper, error)
	AllIdentities(ctx context.Context, obj *models.Repository, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error)
	Identity(ctx context.Context, obj *models.Repository, prefix string) (models.IdentityWrapper, error)
	UserIdentity(ctx context.Context, obj *models.Repository) (models.IdentityWrapper, error)
	ValidLabels(ctx context.Context, obj *models.Repository, after *string, before *string, first *int, last *int) (*models.LabelConnection, error)
}

type ResolverRoot

type ResolverRoot interface {
	AddCommentOperation() AddCommentOperationResolver
	AddCommentTimelineItem() AddCommentTimelineItemResolver
	Bug() BugResolver
	Color() ColorResolver
	Comment() CommentResolver
	CommentHistoryStep() CommentHistoryStepResolver
	CreateOperation() CreateOperationResolver
	CreateTimelineItem() CreateTimelineItemResolver
	EditCommentOperation() EditCommentOperationResolver
	Identity() IdentityResolver
	Label() LabelResolver
	LabelChangeOperation() LabelChangeOperationResolver
	LabelChangeTimelineItem() LabelChangeTimelineItemResolver
	Mutation() MutationResolver
	Query() QueryResolver
	Repository() RepositoryResolver
	SetStatusOperation() SetStatusOperationResolver
	SetStatusTimelineItem() SetStatusTimelineItemResolver
	SetTitleOperation() SetTitleOperationResolver
	SetTitleTimelineItem() SetTitleTimelineItemResolver
}

type SetStatusOperationResolver

type SetStatusOperationResolver interface {
	Author(ctx context.Context, obj *bug.SetStatusOperation) (models.IdentityWrapper, error)
	Date(ctx context.Context, obj *bug.SetStatusOperation) (*time.Time, error)
}

type SetTitleOperationResolver

type SetTitleOperationResolver interface {
	Author(ctx context.Context, obj *bug.SetTitleOperation) (models.IdentityWrapper, error)
	Date(ctx context.Context, obj *bug.SetTitleOperation) (*time.Time, error)
}

type SetTitleTimelineItemResolver

type SetTitleTimelineItemResolver interface {
	ID(ctx context.Context, obj *bug.SetTitleTimelineItem) (entity.CombinedId, error)
	Author(ctx context.Context, obj *bug.SetTitleTimelineItem) (models.IdentityWrapper, error)
	Date(ctx context.Context, obj *bug.SetTitleTimelineItem) (*time.Time, error)
}

Jump to

Keyboard shortcuts

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