• 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: How can I set instance variables within a class?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How can I set instance variables within a class?


  • Subject: Re: How can I set instance variables within a class?
  • From: David Dunham <email@hidden>
  • Date: Mon, 21 Sep 2009 12:41:16 -0700


On 21 Sep 2009, at 12:38, Wayne Bishop wrote:

I am looking for a technique that will allow me track the state of a class in case of a specific error or failure. In .NET one can create class properties which can be set by the class itself. This technique works great for identifying if a database connection fails or if section of code can't connect to a web service. When I attempt to do the same thing in Xcode I get the warning message:

 "warning:instance variable accessed in class method"

Does anyone have any techniques / solutions for accomplishing what I am looking to do?

1. Use [Objective-] C++ and use class globals 2. Use globals.

Though, I don't know why you need the status of a class, as opposed to instances of the class. Unless you need to know if it was dynamically loaded or something.

David Dunham
Mobile: +1 206 769 2227             http://www.pensee.com/dunham/
Imagination is more important than knowledge. -- Albert Einstein

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >How can I set instance variables within a class? (From: Wayne Bishop <email@hidden>)

  • Prev by Date: How can I set instance variables within a class?
  • Next by Date: Re: Using 3.1's documentation window
  • Previous by thread: How can I set instance variables within a class?
  • Next by thread: Re: How can I set instance variables within a class?
  • Index(es):
    • Date
    • Thread