• 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: NSString Question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSString Question


  • Subject: Re: NSString Question
  • From: Andy Lee <email@hidden>
  • Date: Mon, 18 Aug 2008 13:28:07 -0400

On Aug 18, 2008, at 10:54 AM, Dave wrote:
thePropertiesInfoPtr pointer to a C Structure that contains the following member:

NSString* mNameString;

As a general note, by mixing structs and objects you're opening the door to nasty memory management bugs. I'd recommend going with objects for everything -- create a class instead of using the struct, learn how to apply the standard Cocoa memory management techniques, and use existing classes like NSFileHandle and NSData.


Here's the Bible on memory management:

<http://developer.apple.com/documentation/Cocoa/Conceptual/MemoryMgmt/Tasks/MemoryManagementRules.html >

--Andy



_______________________________________________

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


References: 
 >NSString Question (From: Dave <email@hidden>)

  • Prev by Date: Re: NSString Question
  • Next by Date: Re: NSString Question
  • Previous by thread: Re: NSString Question
  • Next by thread: Re: NSString Question
  • Index(es):
    • Date
    • Thread