Class: JsDuck::Tag::Required

Inherits:
MetaTag
  • Object
show all
Defined in:
lib/jsduck/tag/required.rb

Overview

There is no @required tag. Instead the :required attribute is detected after @cfg:

@cfg {Type} someName (required)

This class is only used for displaying the required attribute, not for detecting it. The detection is done with custom logic in DocParser and Merger classes.

Instance Attribute Summary

Attributes inherited from MetaTag

#assets, #boolean, #context, #formatter, #key, #multiline, #name, #position, #signature

Instance Method Summary collapse

Methods inherited from MetaTag

descendants, #format, #to_html, #to_value

Constructor Details

#initializeRequired

Returns a new instance of Required.



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

def initialize
  @name = "--non-matching-requried-tag--"
  @key = :required
  @signature = {:long => "required", :short => "REQ"}
  @boolean = true
end