Documentation ¶
Index ¶
- func GenerateGoMethodMutationsForPackage(s *schema.Schema, genConfig *config.GeneratorConfig, ...) (*[]GoMethod, error)
- func GenerateGoMethodQueriesForPackage(s *schema.Schema, genConfig *config.GeneratorConfig, ...) (*[]GoMethod, error)
- func GenerateGoTypesForPackage(s *schema.Schema, genConfig *config.GeneratorConfig, ...) (*[]GoStruct, *[]GoEnum, *[]GoScalar, *[]GoInterface, error)
- type Command
- type CommandExampleData
- type CommandFlag
- type CommandGenerator
- type GoEnum
- type GoEnumValue
- type GoInterface
- type GoInterfacePossibleType
- type GoMethod
- type GoMethodInputType
- type GoMethodSignature
- type GoScalar
- type GoStruct
- type GoStructField
- type GolangGenerator
- type InputObject
- type QueryVar
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateGoMethodMutationsForPackage ¶ added in v0.2.4
func GenerateGoMethodMutationsForPackage(s *schema.Schema, genConfig *config.GeneratorConfig, pkgConfig *config.PackageConfig) (*[]GoMethod, error)
GenerateGoMethodMutationsForPackage uses the provided configuration to generate the GoMethod structs that contain the information about performing GraphQL mutations.
func GenerateGoMethodQueriesForPackage ¶ added in v0.2.4
func GenerateGoMethodQueriesForPackage(s *schema.Schema, genConfig *config.GeneratorConfig, pkgConfig *config.PackageConfig) (*[]GoMethod, error)
GenerateGoMethodQueriesForPackage uses the provided configuration to generate the GoMethod structs that contain the information about performing GraphQL queries.
func GenerateGoTypesForPackage ¶
func GenerateGoTypesForPackage(s *schema.Schema, genConfig *config.GeneratorConfig, pkgConfig *config.PackageConfig, expandedTypes *[]*schema.Type) (*[]GoStruct, *[]GoEnum, *[]GoScalar, *[]GoInterface, error)
Types ¶
type Command ¶ added in v0.2.4
type Command struct { Name string CmdVariableName string ShortDescription string LongDescription string Example string InputType string ClientMethod string ClientMethodArgs []string InputObjects []InputObject Flags []CommandFlag Subcommands []Command GraphQLPath []string // Should mutations also use this? Probably }
type CommandExampleData ¶ added in v0.3.0
type CommandExampleData struct { CLIName string PackageName string Command string Subcommand string Flags []CommandFlag }
type CommandFlag ¶ added in v0.2.4
type CommandGenerator ¶ added in v0.2.4
TODO: Move CommandGenerator and its friends to a proper home
type GoEnum ¶
type GoEnum struct { Name string Description string Values []GoEnumValue }
type GoEnumValue ¶
type GoInterface ¶
type GoInterface struct { Name string Description string Type string PossibleTypes []GoInterfacePossibleType Methods []string }
type GoInterfacePossibleType ¶ added in v0.2.5
type GoMethodInputType ¶ added in v0.2.0
type GoMethodSignature ¶ added in v0.2.0
type GoMethodSignature struct { Input []GoMethodInputType Return []string // ReturnSlice indicates if the response is a slice of objects or not. Used to flag KindList. ReturnSlice bool // Return path is the fields on the response object that nest the results the given method will return. ReturnPath []string }
type GoStructField ¶
type GolangGenerator ¶
type GolangGenerator struct { Types []GoStruct PackageName string Enums []GoEnum Imports []string Scalars []GoScalar Interfaces []GoInterface Mutations []GoMethod Queries []GoMethod }
GolangGenerator is enough information to generate Go code for a single package.
type InputObject ¶ added in v0.3.0
Click to show internal directories.
Click to hide internal directories.