Class: GraphQL::SchemaComparator::Changes::EnumValueDescriptionChanged
- Inherits:
-
AbstractChange
- Object
- AbstractChange
- GraphQL::SchemaComparator::Changes::EnumValueDescriptionChanged
- Defined in:
- lib/graphql/schema_comparator/changes.rb
Instance Attribute Summary collapse
-
#criticality ⇒ Object
readonly
Returns the value of attribute criticality.
-
#enum ⇒ Object
readonly
Returns the value of attribute enum.
-
#new_enum_value ⇒ Object
readonly
Returns the value of attribute new_enum_value.
-
#old_enum_value ⇒ Object
readonly
Returns the value of attribute old_enum_value.
Instance Method Summary collapse
-
#initialize(enum, old_enum_value, new_enum_value) ⇒ EnumValueDescriptionChanged
constructor
A new instance of EnumValueDescriptionChanged.
- #message ⇒ Object
- #path ⇒ Object
Methods inherited from AbstractChange
#breaking?, #dangerous?, #non_breaking?
Constructor Details
#initialize(enum, old_enum_value, new_enum_value) ⇒ EnumValueDescriptionChanged
Returns a new instance of EnumValueDescriptionChanged.
732 733 734 735 736 737 |
# File 'lib/graphql/schema_comparator/changes.rb', line 732 def initialize(enum, old_enum_value, new_enum_value) @enum = enum @old_enum_value = old_enum_value @new_enum_value = new_enum_value @criticality = Changes::Criticality.non_breaking end |
Instance Attribute Details
#criticality ⇒ Object (readonly)
Returns the value of attribute criticality.
730 731 732 |
# File 'lib/graphql/schema_comparator/changes.rb', line 730 def criticality @criticality end |
#enum ⇒ Object (readonly)
Returns the value of attribute enum.
730 731 732 |
# File 'lib/graphql/schema_comparator/changes.rb', line 730 def enum @enum end |
#new_enum_value ⇒ Object (readonly)
Returns the value of attribute new_enum_value.
730 731 732 |
# File 'lib/graphql/schema_comparator/changes.rb', line 730 def new_enum_value @new_enum_value end |
#old_enum_value ⇒ Object (readonly)
Returns the value of attribute old_enum_value.
730 731 732 |
# File 'lib/graphql/schema_comparator/changes.rb', line 730 def old_enum_value @old_enum_value end |
Instance Method Details
#message ⇒ Object
739 740 741 742 |
# File 'lib/graphql/schema_comparator/changes.rb', line 739 def "Description for enum value `#{new_enum_value.path}` changed from " \ "`#{old_enum_value.description}` to `#{new_enum_value.description}`" end |
#path ⇒ Object
744 745 746 |
# File 'lib/graphql/schema_comparator/changes.rb', line 744 def path old_enum_value.path end |