Class: GraphQL::SchemaComparator::Changes::DirectiveLocationRemoved

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(directive, location) ⇒ DirectiveLocationRemoved

Returns a new instance of DirectiveLocationRemoved.



196
197
198
199
200
# File 'lib/graphql/schema_comparator/changes.rb', line 196

def initialize(directive, location)
  @directive = directive
  @location = location
  @breaking = true
end

Instance Attribute Details

#directiveObject (readonly)

Returns the value of attribute directive.



194
195
196
# File 'lib/graphql/schema_comparator/changes.rb', line 194

def directive
  @directive
end

#locationObject (readonly)

Returns the value of attribute location.



194
195
196
# File 'lib/graphql/schema_comparator/changes.rb', line 194

def location
  @location
end

Instance Method Details

#breaking?Boolean

Returns:

  • (Boolean)


206
207
208
# File 'lib/graphql/schema_comparator/changes.rb', line 206

def breaking?
  !!@breaking
end

#messageObject



202
203
204
# File 'lib/graphql/schema_comparator/changes.rb', line 202

def message
  "Location `#{location}` was removed from directive `#{directive.name}`"
end