Asp Forum
Home
|
Login
|
Register
|
Search
Forums
>
comp.lang.ruby
Getting the module of a class
csshsh@gmail.com
3/26/2006 3:29:00 PM
Hi!
Can anybody think of a better way to get the module of a class in a module?
eval(some_class_in_a_module.to_s.gsub(/::[^:]*$/, ''))
Thanks!
Ciao!
Florian
Servizio di avviso nuovi messaggi
Ricevi direttamente nella tua mail i nuovi messaggi per
Getting the module of a class
Inserendo la tua e-mail nella casella sotto, riceverai un avviso tramite posta elettronica ogni volta che il motore di ricerca troverà un nuovo messaggio per te
Il servizio è completamente GRATUITO!
x
Login to ForumsZone
Login with Google
Login with E-Mail & Password