• 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
Re: Integer as key in NSMutableDictionary
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Integer as key in NSMutableDictionary


  • Subject: Re: Integer as key in NSMutableDictionary
  • From: Alexander Heinz <email@hidden>
  • Date: Mon, 4 May 2009 16:58:36 -0400
  • Resent-date: Mon, 4 May 2009 16:58:57 -0400
  • Resent-from: Alexander Heinz <email@hidden>
  • Resent-message-id: <email@hidden>
  • Resent-to: email@hidden

On May 4, 2009, at 3:22 AM, Weydson Lima wrote:
I know that these methods are expecting pointers as parameters and I am passing a scalar. So, what's the best way to approach that?

That's correct. You really shouldn't put any scalar types in an NSDictionary (or any other container type in the Cocoa API.) You should wrap these values with an NSNumber instead. Look up the documentation for NSNumber, it should tell you what you need to know.


HTH,
- Alex

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Integer as key in NSMutableDictionary
      • From: Jean-Daniel Dupas <email@hidden>
References: 
 >Integer as key in NSMutableDictionary (From: Weydson Lima <email@hidden>)

  • Prev by Date: Re: Integer as key in NSMutableDictionary
  • Next by Date: Re: Integer as key in NSMutableDictionary
  • Previous by thread: Re: Integer as key in NSMutableDictionary
  • Next by thread: Re: Integer as key in NSMutableDictionary
  • Index(es):
    • Date
    • Thread