Class: SectionContent::Section

Inherits:
Treetop::Runtime::SyntaxNode
  • Object
show all
Defined in:
lib/pdoc/parser/section_content_nodes.rb

Instance Method Summary collapse

Instance Method Details

#description ⇒ Object



7
8
9
# File 'lib/pdoc/parser/section_content_nodes.rb', line 7

def description
  text.to_s
end

#full_name ⇒ Object



11
12
13
# File 'lib/pdoc/parser/section_content_nodes.rb', line 11

def full_name
  name
end

#id ⇒ Object



15
16
17
# File 'lib/pdoc/parser/section_content_nodes.rb', line 15

def id
  name.downcase.gsub(/\s+/, "_")
end

#name ⇒ Object



3
4
5
# File 'lib/pdoc/parser/section_content_nodes.rb', line 3

def name
  title.text_value.strip
end