graphql

package
v0.0.0-...-ac925be Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action struct {
	Name        string            `json:"name"`
	Params      []*Param          `json:"params"`
	Return      *sadl.TypeSpec    `json:"return"`
	Provider    string            `json:"provider"`
	Comment     string            `json:"comment,omitempty"`
	Annotations map[string]string `json:"annotations,omitempty"`
}

type Extension

type Extension struct {
	Model *Model
}

func NewExtension

func NewExtension() *Extension

func (*Extension) IsAction

func (gql *Extension) IsAction(opname string, p *sadl.Parser) bool

func (*Extension) Name

func (gql *Extension) Name() string

func (*Extension) Parse

func (gql *Extension) Parse(p *sadl.Parser) error

func (*Extension) Result

func (gql *Extension) Result() interface{}

func (*Extension) Validate

func (gql *Extension) Validate(p *sadl.Parser) error

type Generator

type Generator struct {
	java.Generator
	Graphql *Model
}

func NewGenerator

func NewGenerator(model *sadl.Model, outdir string, config *sadl.Data) *Generator

func NewGenerator(model *sadl.Model, outdir, srcdir, rezdir, pkg string, useLombok, useInstants, useGetters bool) *Generator {

func (*Generator) CreateGraphqlHandler

func (gen *Generator) CreateGraphqlHandler()

func (*Generator) CreateGraphqlRequestPojo

func (gen *Generator) CreateGraphqlRequestPojo()

func (*Generator) CreateGraphqlResponsePojo

func (gen *Generator) CreateGraphqlResponsePojo()

func (*Generator) CreateGraphqlSchema

func (gen *Generator) CreateGraphqlSchema(dir string)

func (*Generator) CreateGraphqlServer

func (gen *Generator) CreateGraphqlServer()

func (*Generator) GraphqlClass

func (gen *Generator) GraphqlClass() string

func (*Generator) GraphqlFetchers

func (gen *Generator) GraphqlFetchers() string

func (*Generator) GraphqlResourceAsString

func (gen *Generator) GraphqlResourceAsString() string

type Model

type Model struct {
	Path        string            `json:"path"`
	Comment     string            `json:"comment,omitempty"`
	Annotations map[string]string `json:"annotations,omitempty"`
	Actions     []*Action         `json:"operations,omitempty"`
}

type Param

type Param struct {
	Name string `json:"name"`
	Type string `json:"type"`
}

Jump to

Keyboard shortcuts

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