Method: Module#doc
- Defined in:
- lib/quarry/document.rb
#doc(str) ⇒ Object
The idea here is to have dynamic docs.
doc "X does such and such"
doc "it is very powerful"
class X
doc "f does such and such"
doc "it is where the power lies"
def f
...
end
end
One of the great things about doc, is that it can be used to “inherit” documentation.
23 24 25 |
# File 'lib/quarry/document.rb', line 23 def doc(str) $_doc << string end |