Forum: Ruby description, what is it?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Ffd881829651935d986c52d12279befb?d=identicon&s=25 Zhenning Guan (rubyernewbie)
on 2008-10-12 17:12
I read a class like this.what's the description work for?


class Employee
 description "xxxxxxxx"
 #some code continue here
end
7a561ec0875fcbbe3066ea8fe288ec77?d=identicon&s=25 Sebastian Hungerecker (Guest)
on 2008-10-12 19:45
(Received via mailing list)
Zhenning Guan wrote:
> I read a class like this.what's the description work for?
>
>
> class Employee
>  description "xxxxxxxx"
>  #some code continue here
> end

Well, it's not part of ruby core/stdlib, but it seems to be an instance
method
of Module or Class (or maybe Object) that, judging by its name, stores
the
description of a class/module (or maybe object) and presumably allows
you to
acces this description from a documentationt or source code browser of
some
sort - or something like that.

HTH,
Sebastian
Bee69cfed999cd13e3bff73d472a39ee?d=identicon&s=25 Hassan Schroeder (Guest)
on 2008-10-12 20:04
(Received via mailing list)
On Sun, Oct 12, 2008 at 10:40 AM, Sebastian Hungerecker
<sepp2k@googlemail.com> wrote:
> Zhenning Guan wrote:
>> I read a class like this.what's the description work for?

> Well, it's not part of ruby core/stdlib

erm, uh, at <http://www.ruby-doc.org/core/> I find "description" listed
as a method of Generators::HtmlMethod  :-)
7a561ec0875fcbbe3066ea8fe288ec77?d=identicon&s=25 Sebastian Hungerecker (Guest)
on 2008-10-12 20:12
(Received via mailing list)
Hassan Schroeder wrote:
> > Well, it's not part of ruby core/stdlib
>
> erm, uh, at <http://www.ruby-doc.org/core/> I find "description" listed
> as a method of Generators::HtmlMethod  :-)

Yeah, but that's not the one used in his code snippet.
This topic is locked and can not be replied to.