Ashley Moran wrote: > On May 05, 2006, at 7:51 pm, Benjamin Pyles wrote: > >> Now I understand the self.name and self password reference the calling >> object. However, I am still trying to figure out why in this >> example the >> function is prefixed with self. > > If by "the function" you mean "def self.login" it's to make it a > class method, rather than a method that applies to objects of that > class. ie you call "User.login" and not "u = User.new; u.login". > > Ashley Thank you for supplying a example, It makes things even more clear then the other definitions provided here. Ben -- Posted via http://www.ruby-forum.com/.