Documentation ¶
Index ¶
- func GetDirective(node ast.Node, dirName string) *ast.Directive
- func GetDirectiveArg(node ast.Node, dirName, argName string) ast.Value
- func GetDirectiveArgBool(node ast.Node, dirName, argName string) (bool, bool, error)
- func GetDirectiveArgEnum(node ast.Node, dirName, argName string) (string, bool, error)
- func GetDirectiveArgStr(node ast.Node, dirName, argName string) (string, bool, error)
- func GetDirectives(node ast.Node) []*ast.Directive
- func SetDirectives(node ast.Node, directives []*ast.Directive) bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetDirective ¶
GetDirective gets a directive by name
func GetDirectiveArg ¶
GetDirectiveArg returns nil if the argument was not found
func GetDirectiveArgBool ¶
GetDirectiveArgBool returns `(false, false, nil)` if directive or argument was not found, or returns an `error` if it was found but it was not a boolean
func GetDirectiveArgEnum ¶
GetDirectiveArgEnum returns `false` if directive or argument was not found, or returns an `error` if it was found but it was not a string
func GetDirectiveArgStr ¶
GetDirectiveArgStr returns `false` if directive or argument was not found, or returns an `error` if it was found but it was not a string
func GetDirectives ¶
GetDirectives returns nil if the node does not have directives
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.