---2049402039-1354733574-1181943948863
Content-Type: MULTIPART/MIXED; BOUNDARY="-2049402039-1354733574-1181943948=:1863"

  This message is in MIME format.  The first part should be readable text,
  while the remaining parts are likely unreadable without MIME-aware tools.

---2049402039-1354733574-1181943948863
Content-Type: TEXT/PLAIN; charset=X-UNKNOWN; format=flowed
Content-Transfer-Encoding: QUOTED-PRINTABLE

Hi --

On Sat, 16 Jun 2007, Borja Mart¨¤ wrote:

> Hi,
> I was wondering if it is possible to create aliases for class methods, as 
> alias_method seems to work only for instance methods.
> Thanks in advance

Class methods are singleton methods defined in a class's singleton
class.  So, to get into the right scope you would do:

   class << YourClass

and then you can use alias and/or alias_method.


David

-- 
* Books:
   RAILS ROUTING (new! http://safari.awprofessional.com/9780321509246)
   RUBY FOR RAILS (http://www.manning.com/black)
* Ruby/Rails training
     & consulting:  Ruby Power and Light, LLC (http://www.rubypal.com)
---2049402039-1354733574-1181943948863--
---2049402039-1354733574-1181943948863--