aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/github.com/graphql-go/graphql/language/ast/directives.go
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2018-07-19 14:15:50 +0200
committerMichael Muré <batolettre@gmail.com>2018-07-19 14:15:50 +0200
commita2a50f3de0c428c5a61e6a449191be3c4ded86ac (patch)
tree5ecf4f5f1f26933b42a606b741963fa5f66c85aa /vendor/github.com/graphql-go/graphql/language/ast/directives.go
parent25fb88d7497b00bbe3dda540efde22ffd3de6e49 (diff)
downloadgit-bug-a2a50f3de0c428c5a61e6a449191be3c4ded86ac.tar.gz
webui: add a primitive graphql handler
Diffstat (limited to 'vendor/github.com/graphql-go/graphql/language/ast/directives.go')
-rw-r--r--vendor/github.com/graphql-go/graphql/language/ast/directives.go33
1 files changed, 33 insertions, 0 deletions
diff --git a/vendor/github.com/graphql-go/graphql/language/ast/directives.go b/vendor/github.com/graphql-go/graphql/language/ast/directives.go
new file mode 100644
index 00000000..0c8a8c0e
--- /dev/null
+++ b/vendor/github.com/graphql-go/graphql/language/ast/directives.go
@@ -0,0 +1,33 @@
+package ast
+
+import (
+ "github.com/graphql-go/graphql/language/kinds"
+)
+
+// Directive implements Node
+type Directive struct {
+ Kind string
+ Loc *Location
+ Name *Name
+ Arguments []*Argument
+}
+
+func NewDirective(dir *Directive) *Directive {
+ if dir == nil {
+ dir = &Directive{}
+ }
+ return &Directive{
+ Kind: kinds.Directive,
+ Loc: dir.Loc,
+ Name: dir.Name,
+ Arguments: dir.Arguments,
+ }
+}
+
+func (dir *Directive) GetKind() string {
+ return dir.Kind
+}
+
+func (dir *Directive) GetLoc() *Location {
+ return dir.Loc
+}