Class: GraphQL::SchemaComparator::Changes::UnionMemberRemoved

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(union_type, union_member) ⇒ UnionMemberRemoved

Returns a new instance of UnionMemberRemoved


95
96
97
98
99
# File 'lib/graphql/schema_comparator/changes.rb', line 95

def initialize(union_type, union_member)
  @union_member = union_member
  @union_type = union_type
  @criticality = Changes::Criticality.breaking
end

Instance Attribute Details

#criticalityObject (readonly)

Returns the value of attribute criticality


93
94
95
# File 'lib/graphql/schema_comparator/changes.rb', line 93

def criticality
  @criticality
end

#union_memberObject (readonly)

Returns the value of attribute union_member


93
94
95
# File 'lib/graphql/schema_comparator/changes.rb', line 93

def union_member
  @union_member
end

#union_typeObject (readonly)

Returns the value of attribute union_type


93
94
95
# File 'lib/graphql/schema_comparator/changes.rb', line 93

def union_type
  @union_type
end

Instance Method Details

#messageObject


101
102
103
# File 'lib/graphql/schema_comparator/changes.rb', line 101

def message
  "Union member `#{union_member.name}` was removed from Union type `#{union_type.name}`"
end