Class: Steep::AST::Annotation::Implements
- Inherits:
-
Object
- Object
- Steep::AST::Annotation::Implements
- Defined in:
- lib/steep/ast/annotation.rb
Defined Under Namespace
Classes: Module
Instance Attribute Summary collapse
-
#location ⇒ Object
readonly
Returns the value of attribute location.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(name:, location: nil) ⇒ Implements
constructor
A new instance of Implements.
Constructor Details
#initialize(name:, location: nil) ⇒ Implements
Returns a new instance of Implements.
74 75 76 77 |
# File 'lib/steep/ast/annotation.rb', line 74 def initialize(name:, location: nil) @location = location @name = name end |
Instance Attribute Details
#location ⇒ Object (readonly)
Returns the value of attribute location.
71 72 73 |
# File 'lib/steep/ast/annotation.rb', line 71 def location @location end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
72 73 74 |
# File 'lib/steep/ast/annotation.rb', line 72 def name @name end |
Instance Method Details
#==(other) ⇒ Object
79 80 81 |
# File 'lib/steep/ast/annotation.rb', line 79 def ==(other) other.is_a?(Implements) && other.name == name end |