Welcome, Guest. Please login or register.
Kingdoms of Ahln
Pages: [1]
  Print  
Author Topic: Classes  (Read 512 times)
Saffire
Citizen
***
Posts: 136


View Profile
« on: February 10, 2009, 09:26:10 pm »

How do I check to make sure an object belongs to a certain class?
Logged
Justin
Administrator
Citizen
*****
Posts: 189



View Profile
« Reply #1 on: February 10, 2009, 09:29:43 pm »

I'm guessing this is more of a Ruby question?

Code:
o.is_a? Mobile
Logged
Saffire
Citizen
***
Posts: 136


View Profile
« Reply #2 on: February 10, 2009, 09:33:03 pm »

Yeah, it's a ruby question. Sorry, I looked online and couldn't find it for some odd reason...  Undecided

I'll try yours and let you know. Thanks!
« Last Edit: February 10, 2009, 09:35:54 pm by Saffire » Logged
Saffire
Citizen
***
Posts: 136


View Profile
« Reply #3 on: February 10, 2009, 09:39:49 pm »

It works! Thanks.
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by SMF 1.1.15 | SMF © 2006-2009, Simple Machines
Terra97 design by Bloc