• 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: Is a good practice to alloc an object and defer the initialization to another object?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Is a good practice to alloc an object and defer the initialization to another object?


  • Subject: Re: Is a good practice to alloc an object and defer the initialization to another object?
  • From: Scott Ribe <email@hidden>
  • Date: Wed, 10 Feb 2010 22:34:31 -0700
  • Thread-topic: Is a good practice to alloc an object and defer the initialization to another object?

> id obj;
> if (.....)
> obj = [Class1 alloc];
> else
> obj = [Class2 alloc];
> obj = [obj initWithFoo:.... bar:....];

--
Scott Ribe
email@hidden
http://www.killerbytes.com/
(303) 722-0567 voice


_______________________________________________

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: 
 >Re: Is a good practice to alloc an object and defer the initialization to another object? (From: Jens Alfke <email@hidden>)

  • Prev by Date: Re: What classes have -init?
  • Next by Date: [iPhone 3.1] NSInvocation on main thread?
  • Previous by thread: Re: Is a good practice to alloc an object and defer the initialization to another object?
  • Next by thread: Core Data Issue with Binding
  • Index(es):
    • Date
    • Thread