50 lines
901 B
Plaintext
50 lines
901 B
Plaintext
### <%= name %>
|
|
|
|
Type: <%= type %>
|
|
|
|
<% if text -%>
|
|
<%= text %>
|
|
<% elsif summary -%>
|
|
<%= summary %>
|
|
<% else -%>
|
|
<%= "The #{name} class." %>
|
|
<% end -%>
|
|
|
|
<% signatures.each do |sig| -%>
|
|
#### `<%= sig.signature %>`
|
|
|
|
<% if sig.text -%>
|
|
<%= sig.text %>
|
|
|
|
<% end -%>
|
|
<% if sig.return_type -%>
|
|
Returns: `<%= sig.return_type %>`<% if sig.return_val %> <%= sig.return_val %><% end %>
|
|
|
|
<% end -%>
|
|
<% if raises -%>
|
|
Raises:
|
|
<% raises.each do |r| -%>
|
|
* <%= error_type(r[:text]) %> <%= error_text(r[:text]) %>
|
|
<% end -%>
|
|
|
|
<% end -%>
|
|
<% if sig.params -%>
|
|
<% sig.params.each do |param| -%>
|
|
##### `<%= param[:name] %>`
|
|
|
|
Data type: `<%= param[:types][0] %>`
|
|
|
|
<%= param[:text] %>
|
|
|
|
<% if sig.options_for_param(param[:name]) -%>
|
|
Options:
|
|
|
|
<% sig.options_for_param(param[:name]).each do |o| -%>
|
|
* **<%= o[:opt_name] %>** `<%= o[:opt_types][0] %>`: <%= o[:opt_text] %>
|
|
<% end -%>
|
|
|
|
<% end -%>
|
|
<% end -%>
|
|
<% end -%>
|
|
<% end -%>
|