Re: NSStringPathExtensions thread safety?
Re: NSStringPathExtensions thread safety?
- Subject: Re: NSStringPathExtensions thread safety?
- From: Scott Thompson <email@hidden>
- Date: Sat, 25 Mar 2006 06:43:29 -0600
On Mar 24, 2006, at 11:53 AM, Jim Correia wrote:
NSString is documented as thread safe here:
http://developer.apple.com/documentation/Cocoa/Conceptual/
Multithreading/articles/CocoaSafety.html
Does that also include all the categories defined by Foundation and/
or AppKit on NSString, such as those in NSPathUtilities.h?
Do the docs follow a general pattern here? In other words, if the
docs claim that NSFoo is thread safe, does that imply that all
Apple supplied categories on NSFoo are also thread safe?
In general I would guess "No."
For a very specific example, I'd guess the "drawString:" methods
added to NSString (NSStringAdditions?) and are probably not supposed
to be called from another thread.
For a more general rule of thumb, I would expect that code in the
foundation kit is more likely to be thread safe than code in the AppKit.
Having said that, I can't remember anything in NSPathUtilities that
would prevent it from being thread-safe... but I doubt you can make
blanket statements about the thread safety of all categories.
Scott
_______________________________________________
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