View Single Post
  #8  
Old October 30th, 2005, 08:43 PM
kainjow kainjow is offline
Registered User
 
Join Date: Nov 2000
Posts: 948
Thanks: 0
Thanked 0 Times in 0 Posts
kainjow is on a distinguished road
No, it's not smart to leave classes as "id" if you can...

Are you putting all your #includes in the .h or the .m? What you should do, is put all your #includes in the .m except for the Cocoa one and the #include if your class inherits from something besides NSObject. For all other classes that you define in your methods or as class variables, use the @class declaration (or whatever it's called) to define these. The syntax goes like this:
@class MyClass1, MyClass2, ...;

Ever since I've used this method, I've never had problems with classes that require each other.
Reply With Quote