Class: JsDuck::Tag::Member

Inherits:
Tag
  • Object
show all
Defined in:
lib/jsduck/tag/member.rb

Constant Summary

Constants inherited from Tag

Tag::POS_ASIDE, Tag::POS_DEFAULT, Tag::POS_DEPRECATED, Tag::POS_DOC, Tag::POS_ENUM, Tag::POS_FIRES, Tag::POS_LOCALDOC, Tag::POS_OVERRIDES, Tag::POS_PARAM, Tag::POS_PREVENTABLE, Tag::POS_PRIVATE, Tag::POS_RETURN, Tag::POS_SINCE, Tag::POS_SUBPROPERTIES, Tag::POS_TEMPLATE, Tag::POS_THROWS, Tag::PRIORITY_CLASS, Tag::PRIORITY_COMPONENT, Tag::PRIORITY_SINGLETON

Instance Attribute Summary

Attributes inherited from Tag

#class_icon, #css, #ext_define_default, #ext_define_pattern, #html_position, #pattern, #repeatable, #signature, #tagname

Instance Method Summary collapse

Methods inherited from Tag

descendants, #format, #parse_ext_define, #to_html

Constructor Details

#initializeMember

This is an odd case where tag itself is @member, but the value of it gets stored in :owner.



7
8
9
10
# File 'lib/jsduck/tag/member.rb', line 7

def initialize
  @pattern = "member"
  @tagname = :owner
end

Instance Method Details

#parse_doc(p, pos) ⇒ Object



13
14
15
16
17
18
# File 'lib/jsduck/tag/member.rb', line 13

def parse_doc(p, pos)
  {
    :tagname => :owner,
    :owner => p.ident_chain,
  }
end

#process_doc(h, tags, pos) ⇒ Object



20
21
22
# File 'lib/jsduck/tag/member.rb', line 20

def process_doc(h, tags, pos)
  h[:owner] = tags[0][:owner]
end