generated

package
v0.0.0-...-5262f89 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2021 License: GPL-3.0 Imports: 12 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 BlobResolver

type BlobResolver interface {
	Data(ctx context.Context, obj *model.Blob) (string, error)
}

type CommitResolver

type CommitResolver interface {
	Tree(ctx context.Context, obj *model.Commit) (*model.Tree, error)

	Parents(ctx context.Context, obj *model.Commit) ([]*model.Commit, error)
}

type ComplexityRoot

type ComplexityRoot struct {
	Blob struct {
		Data func(childComplexity int) int
		Hash func(childComplexity int) int
		Type func(childComplexity int) int
	}

	Commit struct {
		Author       func(childComplexity int) int
		Committer    func(childComplexity int) int
		Hash         func(childComplexity int) int
		Message      func(childComplexity int) int
		ParentHashes func(childComplexity int) int
		Parents      func(childComplexity int) int
		Signature    func(childComplexity int) int
		Tree         func(childComplexity int) int
		TreeHash     func(childComplexity int) int
		Type         func(childComplexity int) int
	}

	Query struct {
		Blob     func(childComplexity int, hash string) int
		Commit   func(childComplexity int, hash string) int
		Commits  func(childComplexity int) int
		Revision func(childComplexity int, name string) int
		Tree     func(childComplexity int, hash string) int
	}

	Signature struct {
		Email func(childComplexity int) int
		Name  func(childComplexity int) int
		When  func(childComplexity int) int
	}

	Tree struct {
		Entries func(childComplexity int) int
		Hash    func(childComplexity int) int
		Type    func(childComplexity int) int
	}

	TreeEntry struct {
		Hash   func(childComplexity int) int
		Mode   func(childComplexity int) int
		Name   func(childComplexity int) int
		Object func(childComplexity int) int
	}
}

type Config

type Config struct {
	Resolvers  ResolverRoot
	Directives DirectiveRoot
	Complexity ComplexityRoot
}

type DirectiveRoot

type DirectiveRoot struct {
}

type QueryResolver

type QueryResolver interface {
	Commit(ctx context.Context, hash string) (*model.Commit, error)
	Blob(ctx context.Context, hash string) (*model.Blob, error)
	Tree(ctx context.Context, hash string) (*model.Tree, error)
	Revision(ctx context.Context, name string) (*model.Commit, error)
	Commits(ctx context.Context) ([]*model.Commit, error)
}

type ResolverRoot

type ResolverRoot interface {
	Blob() BlobResolver
	Commit() CommitResolver
	Query() QueryResolver
	TreeEntry() TreeEntryResolver
}

type TreeEntryResolver

type TreeEntryResolver interface {
	Object(ctx context.Context, obj *model.TreeEntry) (model.Object, error)
}

Jump to

Keyboard shortcuts

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