• 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: Dumb newbie question about objects and scalars
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Dumb newbie question about objects and scalars


  • Subject: Re: Dumb newbie question about objects and scalars
  • From: Charilaos Skiadas <email@hidden>
  • Date: Mon, 14 Mar 2005 10:15:35 -0600

There probably is a more elegant way maybe, but how about creating a small wrapper NSObject subclass that would contain one instance variable of type yourStruct, and would have a method returning this variable, so you could replay your switch with something like:
switch ([myWrapperInstance GLBehaviorStyleValue])
...
...


Then you would just have a constructor method to initialize it with the struct value, and would store the wrapper object instead of your struct.

Haris

_______________________________________________
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


References: 
 >Dumb newbie question about objects and scalars (From: John Brownlow <email@hidden>)

  • Prev by Date: Dumb newbie question about objects and scalars
  • Next by Date: -[NSImage length]: selector not recognized
  • Previous by thread: Dumb newbie question about objects and scalars
  • Next by thread: Re: Dumb newbie question about objects and scalars
  • Index(es):
    • Date
    • Thread