gqlgen: github.com/99designs/gqlgen/example/selection Index | Files | Directories

package selection

import "github.com/99designs/gqlgen/example/selection"

Index

Package Files

generated.go models_gen.go selection.go

func NewExecutableSchema Uses

func NewExecutableSchema(cfg Config) graphql.ExecutableSchema

NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface.

type ComplexityRoot Uses

type ComplexityRoot struct {
    Like struct {
        Collected func(childComplexity int) int
        Reaction  func(childComplexity int) int
        Selection func(childComplexity int) int
        Sent      func(childComplexity int) int
    }

    Post struct {
        Collected func(childComplexity int) int
        Message   func(childComplexity int) int
        Selection func(childComplexity int) int
        Sent      func(childComplexity int) int
    }

    Query struct {
        Events func(childComplexity int) int
    }
}

type Config Uses

type Config struct {
    Resolvers  ResolverRoot
    Directives DirectiveRoot
    Complexity ComplexityRoot
}

type DirectiveRoot Uses

type DirectiveRoot struct {
}

type Event Uses

type Event interface {
    IsEvent()
}

type Like Uses

type Like struct {
    Reaction  string    `json:"reaction"`
    Sent      time.Time `json:"sent"`
    Selection []string  `json:"selection"`
    Collected []string  `json:"collected"`
}

func (Like) IsEvent Uses

func (Like) IsEvent()

type Post Uses

type Post struct {
    Message   string    `json:"message"`
    Sent      time.Time `json:"sent"`
    Selection []string  `json:"selection"`
    Collected []string  `json:"collected"`
}

func (Post) IsEvent Uses

func (Post) IsEvent()

type QueryResolver Uses

type QueryResolver interface {
    Events(ctx context.Context) ([]Event, error)
}

type Resolver Uses

type Resolver struct{}

func (*Resolver) Query Uses

func (r *Resolver) Query() QueryResolver

type ResolverRoot Uses

type ResolverRoot interface {
    Query() QueryResolver
}

Directories

PathSynopsis
server

Package selection imports 11 packages (graph) and is imported by 2 packages. Updated 2020-05-30. Refresh now. Tools for package owners.