Hi, all!
I am a newbie on Mac programming, most of the past 15 years has been VB .net, VB, SQL Server, etc. on Windows. Another 15 years before that in mainframe, minis, supercomputers using Assembler, Fortran, and Pascal. I have to admit that the Cocoa and Objective-C learning curve has been tougher than I thought it would be. I am very encouraged by what I am seeing in terms of the Cocoa/Xcode toolset, environment, etc. I think that once I get up the curve, I will be able to create my applications quickly without a lot of the nuts and bolts that have been a pain in VB .net for a long time.
I am working through a few books that have been very helpful: Cocoa Programming for Mac OS X by Hillegass, Beginning Mac OS X Programming by Trent + McCCormack, and Beginning Xcode by Bucanek. These are all giving me a lot of info and examples, but I am still a bit confused as to understanding some points.
1. Using Core Data and the data modeler, I have created some nice models. This is way cool. The example of creating an Instant Interface was an eye opener. The question I had about this was, the model classes did not appear to generate any code for -init and -dealloc. Yet the auto generated program worked fine! Where is the magic mojo in this that I am not understanding? When I use these model classes 'in real life' with my code, am I correct in assuming that I need to have implementations for -init and -dealloc? I would think so.
2. In all of the examples, the emphasis is on using the Cocoa classes for things, such and NSNumber, NSString, etc. rather than using the similar C language equivalent. I somewhat understand how using the Cocoa classes helps things like Core Data, bindings, KVC, and KVO glue things together. This is cool. The question I have about this when should I use the C language in my coding. For example, I have some nested For loops to create a bunch of object instances. The number of iterations is entered by the user on the window. It seems that this would be an NSNumber. When I code the For loop, should I be indexing using an int or NSNumber?
Thanks!
I am a newbie on Mac programming, most of the past 15 years has been VB .net, VB, SQL Server, etc. on Windows. Another 15 years before that in mainframe, minis, supercomputers using Assembler, Fortran, and Pascal. I have to admit that the Cocoa and Objective-C learning curve has been tougher than I thought it would be. I am very encouraged by what I am seeing in terms of the Cocoa/Xcode toolset, environment, etc. I think that once I get up the curve, I will be able to create my applications quickly without a lot of the nuts and bolts that have been a pain in VB .net for a long time.
I am working through a few books that have been very helpful: Cocoa Programming for Mac OS X by Hillegass, Beginning Mac OS X Programming by Trent + McCCormack, and Beginning Xcode by Bucanek. These are all giving me a lot of info and examples, but I am still a bit confused as to understanding some points.
1. Using Core Data and the data modeler, I have created some nice models. This is way cool. The example of creating an Instant Interface was an eye opener. The question I had about this was, the model classes did not appear to generate any code for -init and -dealloc. Yet the auto generated program worked fine! Where is the magic mojo in this that I am not understanding? When I use these model classes 'in real life' with my code, am I correct in assuming that I need to have implementations for -init and -dealloc? I would think so.
2. In all of the examples, the emphasis is on using the Cocoa classes for things, such and NSNumber, NSString, etc. rather than using the similar C language equivalent. I somewhat understand how using the Cocoa classes helps things like Core Data, bindings, KVC, and KVO glue things together. This is cool. The question I have about this when should I use the C language in my coding. For example, I have some nested For loops to create a bunch of object instances. The number of iterations is entered by the user on the window. It seems that this would be an NSNumber. When I code the For loop, should I be indexing using an int or NSNumber?
Thanks!