Class: GraphQL::SchemaComparator::Changes::InputFieldRemoved

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(input_object_type, field) ⇒ InputFieldRemoved

Returns a new instance of InputFieldRemoved


109
110
111
112
113
# File 'lib/graphql/schema_comparator/changes.rb', line 109

def initialize(input_object_type, field)
  @input_object_type = input_object_type
  @field = field
  @criticality = Changes::Criticality.breaking
end

Instance Attribute Details

#criticalityObject (readonly)

Returns the value of attribute criticality


107
108
109
# File 'lib/graphql/schema_comparator/changes.rb', line 107

def criticality
  @criticality
end

#fieldObject (readonly)

Returns the value of attribute field


107
108
109
# File 'lib/graphql/schema_comparator/changes.rb', line 107

def field
  @field
end

#input_object_typeObject (readonly)

Returns the value of attribute input_object_type


107
108
109
# File 'lib/graphql/schema_comparator/changes.rb', line 107

def input_object_type
  @input_object_type
end

Instance Method Details

#messageObject


115
116
117
# File 'lib/graphql/schema_comparator/changes.rb', line 115

def message
  "Input field `#{field.name}` was removed from input object type `#{input_object_type.name}`"
end