Class: RBS::AST::Ruby::Members::DefMember
| Relationships & Source Files | |
| Super Chains via Extension / Inclusion / Inheritance | |
|
Class Chain:
self,
Base
|
|
|
Instance Chain:
|
|
| Inherits: |
RBS::AST::Ruby::Members::Base
|
| Defined in: | lib/rbs/ast/ruby/members.rb |
Constant Summary
Class Method Summary
Base - Inherited
Instance Attribute Summary
- #leading_comment readonly
- #method_type readonly
- #name readonly
- #node readonly
- #overloading? ⇒ Boolean readonly
Base - Inherited
Instance Method Summary
::RBS::AST::Ruby::Helpers::LocationHelper - Included
Constructor Details
.new(buffer, name, node, method_type, leading_comment) ⇒ DefMember
# File 'lib/rbs/ast/ruby/members.rb', line 555
def initialize(buffer, name, node, method_type, leading_comment) super(buffer) @name = name @node = node @method_type = method_type @leading_comment = leading_comment end
Instance Attribute Details
#leading_comment (readonly)
[ GitHub ]# File 'lib/rbs/ast/ruby/members.rb', line 553
attr_reader :leading_comment
#method_type (readonly)
[ GitHub ]# File 'lib/rbs/ast/ruby/members.rb', line 552
attr_reader :method_type
#name (readonly)
[ GitHub ]# File 'lib/rbs/ast/ruby/members.rb', line 550
attr_reader :name
#node (readonly)
[ GitHub ]# File 'lib/rbs/ast/ruby/members.rb', line 551
attr_reader :node
#overloading? ⇒ Boolean (readonly)
[ GitHub ]
# File 'lib/rbs/ast/ruby/members.rb', line 571
def overloading? method_type.overloading? end
Instance Method Details
#annotations
[ GitHub ]# File 'lib/rbs/ast/ruby/members.rb', line 575
def annotations [] end
#location
[ GitHub ]# File 'lib/rbs/ast/ruby/members.rb', line 563
def location rbs_location(node.location) end
#name_location
[ GitHub ]# File 'lib/rbs/ast/ruby/members.rb', line 579
def name_location rbs_location(node.name_loc) end
#overloads
[ GitHub ]# File 'lib/rbs/ast/ruby/members.rb', line 567
def overloads method_type.overloads end
#type_fingerprint
[ GitHub ]# File 'lib/rbs/ast/ruby/members.rb', line 583
def type_fingerprint [ "members/def", name.to_s, method_type.type_fingerprint, leading_comment&.as_comment&.string ] end