• 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: UUID Generation in Cocoa
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: UUID Generation in Cocoa


  • Subject: Re: UUID Generation in Cocoa
  • From: Vince DeMarco <email@hidden>
  • Date: Sun, 19 Jan 2003 11:48:26 -0800

On Saturday, January 18, 2003, at 08:37 PM, Joseph Jones wrote:

Is there a set of API's or objects in Cocoa that generate and work with UUIDs? After a LONG while of digging around I located Carbon APIs for this, but I'd like to stick to Obj C and Cocoa as much as > possible.


you have to call the CoreFoundation function


- (NSString *)uuid
{
CFUUIDRef UIDRef;
NSString *uidString;

UIDRef = CFUUIDCreate(NULL);
uidString = (NSString *)CFUUIDCreateString(NULL, UIDRef);
CFRelease(UIDRef);

return [uidString autorelease];
}
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >UUID Generation in Cocoa (From: Joseph Jones <email@hidden>)

  • Prev by Date: Re: Getting a reference to the data model from a delegate
  • Next by Date: OpenGL & Cocoa NSEvents
  • Previous by thread: Re: Autorelease pool questions
  • Next by thread: Re: Using NSCell to bold cells in a tableview
  • Index(es):
    • Date
    • Thread