• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Check the class of a variable?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Check the class of a variable?


  • Subject: Check the class of a variable?
  • From: d2kagw <email@hidden>
  • Date: Thu, 6 Apr 2006 23:24:17 +1000

Hey there all..

Just wondering if theres a easy way of checking the class of a variable...
I've gotten this far:


if ( [[theChildren objectForKey:@"data"]  class] == @"NSCFArray" )
{
	// do something
}

but it never matches [ and yes, im sure the values im testing are a mixture or NSArrays and NSStrings ]

Thanks a million !

- Aaron
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Check the class of a variable?
      • From: PGM <email@hidden>
    • Re: Check the class of a variable?
      • From: Charlton Wilbur <email@hidden>
    • Re: Check the class of a variable?
      • From: Jim Correia <email@hidden>
    • Re: Check the class of a variable?
      • From: Nick Zitzmann <email@hidden>
  • Prev by Date: Re: Major Nubie : adding ints get strange values?
  • Next by Date: Re: Check the class of a variable?
  • Previous by thread: Re: Major Nubie : adding ints get strange values?
  • Next by thread: Re: Check the class of a variable?
  • Index(es):
    • Date
    • Thread