Class: YARD::CodeObjects::ModuleObject
- Inherits:
-
NamespaceObject
- Object
- Base
- NamespaceObject
- YARD::CodeObjects::ModuleObject
- Defined in:
- lib/yard/code_objects/module_object.rb
Overview
Represents a Ruby module.
Instance Method Summary
- - (Array<NamespaceObject>) inheritance_tree(include_mods = false) Returns the inheritance tree of mixins.
Methods inherited from NamespaceObject
Methods inherited from Base
#==, ===, #[], #[]=, #add_file, #dynamic?, #file, #format, #format_source, #has_tag?, #initialize, #inspect, #line, #method_missing, #name, new, #parent, #parent=, #path, #relative_path, #root?, #sep, #tag, #tags, #to_s, #type
Constructor Details
This class inherits a constructor from YARD::CodeObjects::NamespaceObject
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class YARD::CodeObjects::Base
Instance Method Details
- (Array<NamespaceObject>) inheritance_tree(include_mods = false)
Returns the inheritance tree of mixins.
9 10 11 12 13 14 15 |
# File 'lib/yard/code_objects/module_object.rb', line 9 def inheritance_tree(include_mods = false) return [self] unless include_mods [self] + mixins(:instance).map do |m| next m unless m.respond_to?(:inheritance_tree) m.inheritance_tree(true) end.flatten end |