Class: GraphQL::StaticValidation::TypeStack::DirectiveStrategy

Inherits:
Object
  • Object
show all
Defined in:
lib/graphql/static_validation/type_stack.rb

Instance Method Summary collapse

Instance Method Details

#pop(stack, node) ⇒ Object


108
109
110
# File 'lib/graphql/static_validation/type_stack.rb', line 108

def pop(stack, node)
  stack.directive_definitions.pop
end

#push(stack, node) ⇒ Object


103
104
105
106
# File 'lib/graphql/static_validation/type_stack.rb', line 103

def push(stack, node)
  directive_defn = stack.schema.directives[node.name]
  stack.directive_definitions.push(directive_defn)
end