Class: Parser::Source::Map::MethodDefinition
- Inherits:
-
Map
- Object
- Map
- Parser::Source::Map::MethodDefinition
- Defined in:
- lib/parser/source/map/method_definition.rb
Instance Attribute Summary collapse
- #assignment ⇒ Object readonly
- #end ⇒ Object readonly
- #keyword ⇒ Object readonly
- #name ⇒ Object readonly
- #operator ⇒ Object readonly
Instance Method Summary collapse
-
#initialize(keyword_l, operator_l, name_l, end_l, assignment_l, body_l) ⇒ MethodDefinition
constructor
A new instance of MethodDefinition.
Constructor Details
#initialize(keyword_l, operator_l, name_l, end_l, assignment_l, body_l) ⇒ MethodDefinition
Returns a new instance of MethodDefinition.
13 14 15 16 17 18 19 20 21 |
# File 'lib/parser/source/map/method_definition.rb', line 13 def initialize(keyword_l, operator_l, name_l, end_l, assignment_l, body_l) @keyword = keyword_l @operator = operator_l @name = name_l @end = end_l @assignment = assignment_l super(@keyword.join(end_l || body_l)) end |
Instance Attribute Details
#assignment ⇒ Object (readonly)
11 12 13 |
# File 'lib/parser/source/map/method_definition.rb', line 11 def assignment @assignment end |
#end ⇒ Object (readonly)
10 11 12 |
# File 'lib/parser/source/map/method_definition.rb', line 10 def end @end end |
#keyword ⇒ Object (readonly)
7 8 9 |
# File 'lib/parser/source/map/method_definition.rb', line 7 def keyword @keyword end |
#name ⇒ Object (readonly)
9 10 11 |
# File 'lib/parser/source/map/method_definition.rb', line 9 def name @name end |
#operator ⇒ Object (readonly)
8 9 10 |
# File 'lib/parser/source/map/method_definition.rb', line 8 def operator @operator end |