Class: GraphQL::SchemaComparator::Changes::TypeRemoved
- Inherits:
-
AbstractChange
- Object
- AbstractChange
- GraphQL::SchemaComparator::Changes::TypeRemoved
- Defined in:
- lib/graphql/schema_comparator/changes.rb
Overview
Mostly breaking changes
Instance Attribute Summary collapse
-
#criticality ⇒ Object
readonly
Returns the value of attribute criticality.
-
#removed_type ⇒ Object
readonly
Returns the value of attribute removed_type.
Instance Method Summary collapse
-
#initialize(removed_type) ⇒ TypeRemoved
constructor
A new instance of TypeRemoved.
- #message ⇒ Object
- #path ⇒ Object
Methods inherited from AbstractChange
#breaking?, #dangerous?, #non_breaking?
Constructor Details
#initialize(removed_type) ⇒ TypeRemoved
Returns a new instance of TypeRemoved.
46 47 48 49 50 51 |
# File 'lib/graphql/schema_comparator/changes.rb', line 46 def initialize(removed_type) @removed_type = removed_type @criticality = Changes::Criticality.breaking( reason: "Removing a type is a breaking change. It is preferable to deprecate and remove all references to this type first." ) end |
Instance Attribute Details
#criticality ⇒ Object (readonly)
Returns the value of attribute criticality.
44 45 46 |
# File 'lib/graphql/schema_comparator/changes.rb', line 44 def criticality @criticality end |
#removed_type ⇒ Object (readonly)
Returns the value of attribute removed_type.
44 45 46 |
# File 'lib/graphql/schema_comparator/changes.rb', line 44 def removed_type @removed_type end |
Instance Method Details
#message ⇒ Object
53 54 55 |
# File 'lib/graphql/schema_comparator/changes.rb', line 53 def "Type `#{removed_type.graphql_name}` was removed" end |
#path ⇒ Object
57 58 59 |
# File 'lib/graphql/schema_comparator/changes.rb', line 57 def path removed_type.path end |