Class: JsDuck::Process::InheritDoc

Inherits:
Object
  • Object
show all
Defined in:
lib/jsduck/process/inherit_doc.rb

Overview

Deals with inheriting documentation

Instance Method Summary collapse

Constructor Details

#initialize(relations) ⇒ InheritDoc

Returns a new instance of InheritDoc.



11
12
13
14
15
# File 'lib/jsduck/process/inherit_doc.rb', line 11

def initialize(relations)
  @relations = relations
  @inherit_class = InheritClass.new(@relations)
  @inherit_members = InheritMembers.new(@relations)
end

Instance Method Details

#process_all!Object

Performs all inheriting



18
19
20
21
22
23
24
25
26
27
# File 'lib/jsduck/process/inherit_doc.rb', line 18

def process_all!
  @relations.each do |cls|
    @inherit_class.resolve(cls)
    @inherit_members.resolve(cls)
  end

  @relations.each do |cls|
    cls.refresh_member_ids!
  end
end