Class: ReFe::ClassNode
- Inherits:
-
ModuleNode
- Object
- ModuleNode
- ReFe::ClassNode
- Defined in:
- lib/refe/inheritancegraph.rb
Instance Attribute Summary
Attributes inherited from ModuleNode
Instance Method Summary collapse
- #ancestors ⇒ Object
-
#initialize(name, super_node) ⇒ ClassNode
constructor
A new instance of ClassNode.
Methods inherited from ModuleNode
Constructor Details
#initialize(name, super_node) ⇒ ClassNode
Returns a new instance of ClassNode.
100 101 102 103 |
# File 'lib/refe/inheritancegraph.rb', line 100 def initialize( name, super_node ) super name @superclass = super_node end |
Instance Method Details
#ancestors ⇒ Object
105 106 107 |
# File 'lib/refe/inheritancegraph.rb', line 105 def ancestors (super() + (@superclass ? @superclass.ancestors : [])).uniq end |