Class: JsDuck::Tag::Constructor
- Defined in:
- lib/jsduck/tag/constructor.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
Instance Attribute Summary
Attributes inherited from Tag
#css, #ext_define_default, #ext_define_pattern, #html_position, #pattern, #repeatable, #signature, #tagname
Instance Method Summary collapse
-
#initialize ⇒ Constructor
constructor
A new instance of Constructor.
- #parse_doc(p, pos) ⇒ Object
-
#process_doc(h, tags, pos) ⇒ Object
The method name will become “constructor” unless a separate.
-
#tag(alreadysuppliedthename.) ⇒ Object
The method name will become “constructor” unless a separate.
Methods inherited from Tag
descendants, #format, #parse_ext_define, #to_html
Constructor Details
#initialize ⇒ Constructor
Returns a new instance of Constructor.
5 6 7 8 |
# File 'lib/jsduck/tag/constructor.rb', line 5 def initialize @pattern = "constructor" @tagname = :constructor end |
Instance Method Details
#parse_doc(p, pos) ⇒ Object
11 12 13 |
# File 'lib/jsduck/tag/constructor.rb', line 11 def parse_doc(p, pos) {:tagname => :constructor, :doc => :multiline} end |
#process_doc(h, tags, pos) ⇒ Object
The method name will become “constructor” unless a separate
17 18 19 20 21 22 |
# File 'lib/jsduck/tag/constructor.rb', line 17 def process_doc(h, , pos) h[:name] = "constructor" unless h[:name] # Documentation after @constructor is part of the constructor # method top-level docs. h[:doc] += [0][:doc] end |
#tag(alreadysuppliedthename.) ⇒ Object
The method name will become “constructor” unless a separate
17 18 19 20 21 22 |
# File 'lib/jsduck/tag/constructor.rb', line 17 def process_doc(h, , pos) h[:name] = "constructor" unless h[:name] # Documentation after @constructor is part of the constructor # method top-level docs. h[:doc] += [0][:doc] end |