I'm using some meta-programming to generate a bunch of methods in ruby like so:
class EmotionalObject
def self.mood( name, *details )
define_method(name) do
# ...
end
end
mood :happy, #...
mood :sad, #...
mood :ebuillent, #...
#...
end
I know that I can pass rdoc
'-A mood' to get it to recognize my mood
generation code as attributes, which is handy, since then they at least
get recognized.
However, they're really more like regular methods than attributes, so
I don't want them listed under the 'Attributes:' section when I look
at the documentation using ri
. I don't have any regular attributes,
so is there any simple way I can just change the title of this section to be 'Moods:'
or something like that, so my users are at least curious enough to type ri EmotionalObject#happy
.