Class: RubyLsp::Ree::BodyObjectsParser::CallObject
- Inherits:
-
Object
- Object
- RubyLsp::Ree::BodyObjectsParser::CallObject
- Defined in:
- lib/ruby_lsp/ruby_lsp_ree/parsing/body_parsers/body_objects_parser.rb
Instance Attribute Summary collapse
-
#method_name ⇒ Object
readonly
Returns the value of attribute method_name.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#receiver_name ⇒ Object
readonly
Returns the value of attribute receiver_name.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
- #has_receiver? ⇒ Boolean
-
#initialize(name:, type:, receiver_name: nil) ⇒ CallObject
constructor
A new instance of CallObject.
- #set_method_name(method_name) ⇒ Object
Constructor Details
#initialize(name:, type:, receiver_name: nil) ⇒ CallObject
Returns a new instance of CallObject.
15 16 17 18 19 20 |
# File 'lib/ruby_lsp/ruby_lsp_ree/parsing/body_parsers/body_objects_parser.rb', line 15 def initialize(name:, type:, receiver_name: nil) @name = name @type = type @receiver_name = receiver_name @method_name = nil end |
Instance Attribute Details
#method_name ⇒ Object (readonly)
Returns the value of attribute method_name.
13 14 15 |
# File 'lib/ruby_lsp/ruby_lsp_ree/parsing/body_parsers/body_objects_parser.rb', line 13 def method_name @method_name end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
13 14 15 |
# File 'lib/ruby_lsp/ruby_lsp_ree/parsing/body_parsers/body_objects_parser.rb', line 13 def name @name end |
#receiver_name ⇒ Object (readonly)
Returns the value of attribute receiver_name.
13 14 15 |
# File 'lib/ruby_lsp/ruby_lsp_ree/parsing/body_parsers/body_objects_parser.rb', line 13 def receiver_name @receiver_name end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
13 14 15 |
# File 'lib/ruby_lsp/ruby_lsp_ree/parsing/body_parsers/body_objects_parser.rb', line 13 def type @type end |
Instance Method Details
#has_receiver? ⇒ Boolean
26 27 28 |
# File 'lib/ruby_lsp/ruby_lsp_ree/parsing/body_parsers/body_objects_parser.rb', line 26 def has_receiver? !!@receiver_name end |
#set_method_name(method_name) ⇒ Object
22 23 24 |
# File 'lib/ruby_lsp/ruby_lsp_ree/parsing/body_parsers/body_objects_parser.rb', line 22 def set_method_name(method_name) @method_name = method_name end |