Class: Apipony::Documentation
- Inherits:
-
Object
- Object
- Apipony::Documentation
- Defined in:
- lib/apipony/documentation.rb
Class Attribute Summary collapse
-
.base_url ⇒ Object
Returns the value of attribute base_url.
-
.sections ⇒ Object
Returns the value of attribute sections.
-
.title ⇒ Object
Returns the value of attribute title.
Class Method Summary collapse
Class Attribute Details
.base_url ⇒ Object
Returns the value of attribute base_url.
3 4 5 |
# File 'lib/apipony/documentation.rb', line 3 def base_url @base_url end |
.sections ⇒ Object
Returns the value of attribute sections.
3 4 5 |
# File 'lib/apipony/documentation.rb', line 3 def sections @sections end |
.title ⇒ Object
Returns the value of attribute title.
3 4 5 |
# File 'lib/apipony/documentation.rb', line 3 def title @title end |
Class Method Details
.config(&block) ⇒ Object
17 18 19 |
# File 'lib/apipony/documentation.rb', line 17 def config(&block) instance_eval(&block) end |
.define(&block) ⇒ Object
5 6 7 8 9 10 11 |
# File 'lib/apipony/documentation.rb', line 5 def define(&block) @sections = [] @title = 'API Documentation' @base_url = '' instance_eval(&block) end |
.section(title, &block) ⇒ Object
13 14 15 |
# File 'lib/apipony/documentation.rb', line 13 def section(title, &block) @sections << Apipony::Section.new(title, &block) end |