Class: GraphQL::SchemaComparator::Changes::DirectiveArgumentRemoved

Inherits:
AbstractChange
  • Object
show all
Defined in:
lib/graphql/schema_comparator/changes.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from AbstractChange

#breaking?, #dangerous?, #non_breaking?

Constructor Details

#initialize(directive, argument) ⇒ DirectiveArgumentRemoved

Returns a new instance of DirectiveArgumentRemoved.



171
172
173
174
175
# File 'lib/graphql/schema_comparator/changes.rb', line 171

def initialize(directive, argument)
  @directive = directive
  @argument = argument
  @criticality = Changes::Criticality.breaking
end

Instance Attribute Details

#argumentObject (readonly)

Returns the value of attribute argument.



169
170
171
# File 'lib/graphql/schema_comparator/changes.rb', line 169

def argument
  @argument
end

#criticalityObject (readonly)

Returns the value of attribute criticality.



169
170
171
# File 'lib/graphql/schema_comparator/changes.rb', line 169

def criticality
  @criticality
end

#directiveObject (readonly)

Returns the value of attribute directive.



169
170
171
# File 'lib/graphql/schema_comparator/changes.rb', line 169

def directive
  @directive
end

Instance Method Details

#messageObject



177
178
179
# File 'lib/graphql/schema_comparator/changes.rb', line 177

def message
  "Argument `#{argument.name}` was removed from directive `#{directive.name}`"
end

#pathObject



181
182
183
# File 'lib/graphql/schema_comparator/changes.rb', line 181

def path
  ["@#{directive.name}", argument.name].join('.')
end