开发者

How hard is iPhone/iPad development

I've been developing for quite a while but while I consider myself competent (or better) with C++, Java, C# & AS3/Flex in areas from web-servers to desktop applications to 3D games, I'm aware all these languages are 开发者_StackOverflow中文版pretty similar; even on the libraries side I know what to look for based on using libraries that do similar things in another language.

But Objective C I understand to be a different kettle of fish, and developing for mobile devices has always struck me as likely to be hard work since you have to develop on your PC and test on the actual device itself - my experience developing for PS2 put me off such things due to poor debuggers and other tools.

What's the reality? Is it a paradigm shift to move from web-servers and desktop apps and rich web-clients to iPhone... or for an experienced developer is it just another language to learn and new libraries to play with? Is there anything to be scared about at all?

edit: My main question on Obj-C specifically was if it's a different way of programming, like it would be moving to Haskell from Java for instance. It sounds this is not the case.


For starters, ObjC is fairly easy to grasp so long as you focus on the fundamentals. Don't worry about the syntax, there's not much there above C which I will presume you already are familiar with. There are excellent books out there this book is the definitive guide I recommend to most new users, Erica Sadun also has a good book on iPhone development, I recommend both of these highly.

Secondly, the tools aren't hard to use, and you will be pleasantly surprised with the debugger and other tool integration. Instruments was a long time coming, but it's indispensable for catching things like memory leaks, cpu time usage, and now power consumption.

But really, nothing to be scared about, and as for another platform to learn; well, yes and no. There is always going to be another thing to learn, regardless of iPhone or something else. Don't resist. :)


There's definitely a "paradigm shift" (ugh, buzzwords):

  • You don't have all the memory in the world (and there's no swap either)
  • You don't have all the CPU time in the world
  • You probably don't want a binary bigger than about 20 MB (the size that can be downloaded over the cell network)
  • You can't just change the server backend to make things right.
  • Graphic design is important if you want to be successful (but you don't want to bloat your app)
  • Web requests take a while (a website with redirects feels really slow compared to the desktop beside it).
  • JavaScript animations are painfully slow (ever tried the Google Maps website on an iPhone?)
  • UI design is heavily constrained by the size of the user's finger (even though the iPhone 4 has a comparatively huge screen).
  • UI design is really tedious.
  • The user can do more things than clicking and typing.

I find that the biggest difference is in the UI, not in the language. Languages are easy. Libraries require a little reading/searching/asking around, but then they're easy. UI design and UI programming are very difficult to do well.


Objective C is different but not far removed from normal OO methods. The syntax was the larger barrier for me.

The problem I saw was/is you learn ObjC for iPhone, and you can't take the skill (ObjC knowledge) outside the Applesphere really. I haven't seen a use for it. I have a handful of books I went through to get my feet wet. Some of these, the Apress books, contained errors in the code walkthroughs causing me to Google the book errata countless times.. so be careful of that, if you learn that way.

Also, unless this has changed, you can only develop under OSX with the SDK tools because no Windows version exists to my knowledge.

With that, you also have to play by Apples development rules to get published into the AppStore, which has had its share of dev horror stories.

That said, a working app is fun and beautiful in the end.


On a scale of 1 to 10, it's about a 6.


Apple does use Objective C and it is different then normal C. So Iphone and IPad development can be hard if you've never used Objective-C before. If you are familiar at all with a language called SmallTalk, then Objective-C will be very easy for you to pick up.

Now other mobile devices, such as Android, uses Java. If you are competent in Java then Android development may be easier for you.

Some devices use Windows Mobile. If you are a .NET programmer, you can use .NET compact framework to develop Windows Mobile Apps.

Just so you know too, most mobile SDKs come with an emulator to test your app on. So if you don't have an iPhone, for example, you can still test your app with the emulator. I understand that the emulator is supposed to be 99% as accurate as an actual device


I don't think there's anything to be scared of.

The simulator's pretty alright, even if it can't handle some things - it's hard to simulate the accelerometer, for instance!

Once you're over the hurdle of figuring out what certs you need and setting up the iPhone development account and such, it's fine.

It's a bit of a pain writing something, loading it on the device, trying it out, etc., but the fact that you can actually debug the code running on the device makes it rather a lot nicer than it could be. (I had to maintain an application for the Nokia 9110, and there I had to edit, compile, load, run, crash blindly, stare at code, guess, edit, compile, etc.)


As a long time Windows C++ / .NET developer, I didn't find it very difficult to begin developing in Objective C.

There are some syntax differences that take some getting used to, but in general it similar enough to C/C++ to not feel like a completely new language.

Learning the library code and what you can and can't do easily seems like the larger challenge to me, which is going to be a challenge with any new platform.


I am writing a beginner book called Hello! iPhone, and I've made a mailing list of beginner tips to help people get started. After a week or so of tips, you'll be much more equipped to check out other books and understand the basics a bit better to judge.

http://loufranco.com/beginner-iphone-programming-tips/

It will take you through Hello, World and some other simple stuff (Outlets and Actions, basic memory management, etc).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜