Class: GraphQL::SchemaComparator::Changes::DirectiveAdded
- Inherits:
-
AbstractChange
- Object
- AbstractChange
- GraphQL::SchemaComparator::Changes::DirectiveAdded
- Defined in:
- lib/graphql/schema_comparator/changes.rb
Instance Attribute Summary collapse
-
#criticality ⇒ Object
readonly
Returns the value of attribute criticality.
-
#directive ⇒ Object
readonly
Returns the value of attribute directive.
Instance Method Summary collapse
-
#initialize(directive) ⇒ DirectiveAdded
constructor
A new instance of DirectiveAdded.
- #message ⇒ Object
- #path ⇒ Object
Methods inherited from AbstractChange
#breaking?, #dangerous?, #non_breaking?
Constructor Details
#initialize(directive) ⇒ DirectiveAdded
Returns a new instance of DirectiveAdded.
617 618 619 620 |
# File 'lib/graphql/schema_comparator/changes.rb', line 617 def initialize(directive) @directive = directive @criticality = Changes::Criticality.non_breaking end |
Instance Attribute Details
#criticality ⇒ Object (readonly)
Returns the value of attribute criticality.
615 616 617 |
# File 'lib/graphql/schema_comparator/changes.rb', line 615 def criticality @criticality end |
#directive ⇒ Object (readonly)
Returns the value of attribute directive.
615 616 617 |
# File 'lib/graphql/schema_comparator/changes.rb', line 615 def directive @directive end |
Instance Method Details
#message ⇒ Object
622 623 624 |
# File 'lib/graphql/schema_comparator/changes.rb', line 622 def "Directive `#{directive.name}` was added" end |
#path ⇒ Object
626 627 628 |
# File 'lib/graphql/schema_comparator/changes.rb', line 626 def path "@#{directive.name}" end |