Class: YARD::Tags::OptionTag

Inherits:
Tag
  • Object
show all
Defined in:
lib/yard/tags/option_tag.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(tag_name, name, pair) ⇒ OptionTag

Returns a new instance of OptionTag



6
7
8
9
# File 'lib/yard/tags/option_tag.rb', line 6

def initialize(tag_name, name, pair)
  super(tag_name, nil, nil, name)
  @pair = pair
end

Instance Attribute Details

#name ⇒ String Originally defined in class Tag

Returns a name associated with the tag

Returns:

  • (String) —

    a name associated with the tag

#object ⇒ CodeObjects::Base Originally defined in class Tag

Returns the associated object

Returns:

#pair ⇒ Object

Returns the value of attribute pair



4
5
6
# File 'lib/yard/tags/option_tag.rb', line 4

def pair
  @pair
end

#tag_name ⇒ String Originally defined in class Tag

Returns the name of the tag

Returns:

  • (String) —

    the name of the tag

#text ⇒ String? Originally defined in class Tag

Returns:

  • (String) —

    the tag text associated with the tag

  • (nil) —

    if no tag text is supplied

#types ⇒ Array<String>? Originally defined in class Tag

Returns:

  • (Array<String>) —

    a list of types associated with the tag

  • (nil) —

    if no types are associated with the tag