Joped.com

June 10, 2008

Starting to learn Objective-C

Filed under: Apple, Development — contact @ 8:56 pm

XCode 3.0I realized it was time to do some mild playing around with client side development on the Mac. Cocoa is the framework that runs the show on Mac (Carbon is on the way out). It requires the use of Objective-C.

For the most part, the languages I know are C style syntax. This makes it very easy to pick up new languages. When I switch from Perl to PHP, I picked things up very fast. I enjoy the look of PHP, which makes it my primary language.

Objective-C on the other hand is dead ugly. Function calls with []’s and class definitions with a plus sign.

C++
obj.method(value);

Objective-C
[obj method param1:value];

I find it very strange to have the left [ outside of object name. Its really going to take some getting used to. A few people have told me that once you get used to it you will love it. Well, we will have to see.

I have almost completed my first functional application. When I get better, I am going to rewrite it with a few more features and create a tool out of it. I will post more details in the future.

Powered by WordPress