gqlutil

package
v0.0.0-...-c4be6ef Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2020 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidDirective = stderrors.New("invalid argument")

Functions

func HasProto

func HasProto(def *ast.Definition, defMap map[string]*ast.Definition) (resp bool, err error)

func IsBuiltinType

func IsBuiltinType(t *ast.Type) bool

func IsListType

func IsListType(t *ast.Type) bool

Types

type ProtoDirective

type ProtoDirective struct {
	FullName  string
	Package   string
	Name      string
	GoPackage string
	GoName    string
	Oneof     *ProtoDirectiveOneof
}

func ExtractProtoDirective

func ExtractProtoDirective(directives ast.DirectiveList) (*ProtoDirective, error)

func (*ProtoDirective) IsValid

func (d *ProtoDirective) IsValid() bool

type ProtoDirectiveOneof

type ProtoDirectiveOneof struct {
	Fields []*ProtoDirectiveOneofField
}

type ProtoDirectiveOneofField

type ProtoDirectiveOneofField struct {
	Name   string
	GoName string
}

func (*ProtoDirectiveOneofField) IsValid

func (f *ProtoDirectiveOneofField) IsValid() bool

type ProtoFieldDirective

type ProtoFieldDirective struct {
	Name          string
	Type          string
	GoName        string
	GoTypeName    string
	GoTypePackage string
	OneofName     string
	OneofGoName   string
}

func ExtractProtoFieldDirective

func ExtractProtoFieldDirective(directives ast.DirectiveList) (*ProtoFieldDirective, error)

func (*ProtoFieldDirective) IsGoBuiltinType

func (d *ProtoFieldDirective) IsGoBuiltinType() bool

func (*ProtoFieldDirective) IsValid

func (d *ProtoFieldDirective) IsValid() bool

func (*ProtoFieldDirective) IsWellKnownType

func (d *ProtoFieldDirective) IsWellKnownType() bool

Jump to

Keyboard shortcuts

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