哪些移动平台会更有价值的学习作为一名开发人员(iPhone VS棕榈pre对Android的)? [英] Which mobile platform would be more rewarding to learn as a developer (iPhone vs Palm Pre vs. Android)?

查看:210
本文介绍了哪些移动平台会更有价值的学习作为一名开发人员(iPhone VS棕榈pre对Android的)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我很感兴趣,让我的脚湿的PDA /手机的发展。 只有两名司机对我来说是驱动学习爽(或者至少,新的)东西,可能是$ C C一些应用程序,我觉得我真的需要,但缺乏$。

I am interested in getting my feet wet in PDA/mobile development. The only two drivers for me are the drive to learn cool (or at least, new) stuff, and may be to code some app that I felt I really needed but lacked.

因此​​,我想知道的比较效益/缺点是什么,我作为一个开发者在选择这三个平台之一(iPhone VS棕榈pre对Android的 - 我将有机会获得任何3而不是到Windows Mobile)。例如。

As such, I would like to know what the comparative benefits/downsides would be for me as a developer in choosing one of the three platforms (iPhone vs Palm Pre vs. Android - I will have access to any of the 3 but not to Windows mobile). E.g.

  • 有什么令人兴奋的新技术,我能学到什么?

  • What exciting new technologies I can learn?

如何好现有的开发环境是什么?

How good the available development environments are?

哪些现有的框架/库可用或正在积极开发?

What existing frameworks/libraries are available or are under active development?

如何有据可查的平台和API是?

How well documented the platform and APIs are?

什么平台整齐的功能都可以通过API的访问与挡着?

What neat features of the platform are accessible via the APIs vs. blocked off?

任何其他开发人员为中心的考虑,我错过?

Any other developer-centric considerations I missed?

我是pretty的开放利用的任何好处我现有的技能设置,以减轻学习曲线,或学习全新的东西和冷静的利益,因此,虽然我很好奇怎么平台的发展涉及以我目前集(最近,Perl,SQL,Web开发,C ++和Java的部分,但我也挺舒服的函数式编程),所以它不会是一个决定点。

I am pretty open to either the benefits of leveraging my existing skill-set to ease the learning curve, or the benefits of learning something entirely new and cool, so while I'm curious how the platforms' development relates to my current set (recently, Perl, SQL, web development, C++ and some Java, but I'm also quite comfortable with functional programming), so it will not be a deciding point.

请注意:这不是这个问题,因为我不在乎在所有关于这个问题的数据点(手持设备的成本,该平台的普及)。同样,仅仅是明确的,我的目标不是金融在所有 - 我不打算赚钱了这样的发展,也直接使用在该地区的技能我会得到我的职业生涯(例如:我的东西的工作,有齐尔希手机曝光,今后仍将如此)。所以问题,如用户群是pretty的无关。我所关心的是有形的(学习)和无形(纯粹的喜悦它)给我好处作为一个开发者。

NOTE: This is not a duplicate of this question, since I do not care at all about that question's data points (cost of the handheld, popularity of the platform). Also, just to be clear, my goal is not financial at all - I don't plan to make money off of such development nor directly use the skills in the area I might obtain in my career (e.g. I work on stuff that has zilch mobile exposure and will remain so). So concerns such as "installed user base" are pretty irrelevant. All I care about are tangible (learning) and intangible (sheer joy of it) benefits to me as a developer.

此外,请是积极的,不要放下其他平台或以其他方式使用此作为一个神圣的平台战争借口。我有编辑的权限,并会毫不留情地编辑任何未备份的逐事实攻击未downvoted任何平台。

Also, please be positive and don't put down other platforms or otherwise use this as a holy platform war excuse. I have edit privileges and will mercilessly edit any un-backed-up-by-facts attacks on any platform that aren't downvoted.

推荐答案

我有商业开发在过去几年为iPhone和Android的经验。我只是写的的Hello World的对webOS的,所以我就不提了这里。

I have experience of developing commercially for the last years for iPhone and Android. I have only written "hello world" for webOS, so I will not mention it here.

文件

我的经验是,iPhone是闪亮的皇冠上的明珠,它在它自己的联赛发挥。文档和工具质朴。公共API中的一切:■有据可查,并从苹果公司的例子项目占地面积pretty的每样东西。在Cocoa Touch框架是经过深思熟虑的,一致的;学习怎么一类的工作,你可以直观地知道下一个是如何工作的,以及。

My experience is that the iPhone is the shining crown jewel, it plays in a league of it's own. The documentation and tools are pristine. Everything in the public API:s are well documented, and the example projects from Apple covers pretty much everything. The Cocoa Touch framework is well thought out and consistent; learn how one class works and you can intuitively know how the next works as well.

而在Android的1.6版本,仍然感觉像一个alpha其中API:仍然需要整理。该文档有很多大洞,最常量永远描述他们做什么,只是它们是什么。该API是不一致的,甚至还没有想通了,如果它要面向对象与否。对话框是最好的例子,在那里你定义整型的ID,并使用一些回调在C-喜欢时尚,以显示该对话框,但在另一方面,有一个工厂类,它是面向对象的一个​​基本结束工程学位实际创建一个警告对话框

Whereas Android at version 1.6 still feels like an alpha where the API:s still needs sorting out. The documentation have many gaping holes, most constants never describe what they do, just what they are. The API is inconsistent and has not even figured out if it should be Object Oriented or not. Dialogs are the best example, where you define integer ID's and use several callbacks in a C-like fashion to display the dialog, but on the other hand have a factory class that is OO to an almost over engineered degree to actually create an alert dialog.

编程语言

可可触摸打得很好用Objective-C语言,它的动态性。显而易见的基本范式,如代表团,和目标的行动。以及酷炫的框架,比如核心数据打勾。

Cocoa Touch plays well with the Objective-C language and it's dynamic nature. Evident in basic paradigms such as delegation, and target-actions. And making cool frameworks such as Core Data tick.

Android的API:■是​​建立在Java 5中,但对于性能的原因,许多Java 5的特性,不使用的。最明显的是完全没有枚举的,而是使用非安全型INT常数,但有时并不总是与prefixes来帮助你的的类型安全的。

The Android API:s are build on Java 5, but for performance reasons many Java 5 features are not used at all. Most evident is the complete lack of enums, and instead using non-type safe int constants, sometimes but not always with prefixes to help you with type safety.

设计用户界面

在iPhone SDK功能的界面生成器,一个GUI工具的用户界面,所见即所得的编辑。 IB(界面生成器)是一种不同的野兽比大多数图形用户界面的编辑;它不产生code,甚至秘方的XML或其它格式的文件。 IB而不是适用于被序列化,或归档对象 - 客厅活动对象。这是再未归档为在运行时的活动对象。需要一段时间才能使用,但理解的时候的伟大工程。

The iPhone SDK features the Interface Builder, a GUI tool with WYSIWYG editing of user interfaces. IB (Interface Builder) is a kind of different beast than most GUI editors; it do not generate code, or even "recipe" files in XML or some other format. IB instead works with live objects that are serialized, or archived on Obj-C parlor. That are then unarchived as live objects at run-time. Takes some getting use to, but works great when understood.

在你的Andr​​oid在XML文件中定义的用户界面,即照顾的虚增的在Android的客厅在运行时。这是一个伟大的想法和作品真的很好。主要是因为我个人比较讨厌的自动生成的标记为不修改(即11你超时了10无论如何也要修改,打破了工具)code块。常量UI元素的诠释,他XML都是为你自动生成的文件。在下行路上的书面文件表示XML文件几乎是不存在的,并且也确实shold是一个探测器拖N - 下降的工具,而不是简单的XML。

On Android you define UI in XML files, that care "inflated" in Android parlor at runtime. This is a great idea and works really nice. Mostly because I personally hate the auto generated code blocks marked as "do not edit" (that you 11 times out of 10 have to edit anyway, breaking the tools). Constants to UI elements int he XML files are auto generated for you. On the downside the documentation for writing said XML files is almost non-existent, and there really shold be a prober drag-n-drop tool, not plain XML.

性能分析

在iPhone SDK中有一个名为仪器很好的工具,它是建立在Sun的DTrace的工具之上。用它来分析任何运行的应用程序在模拟器或设备。无需更改源$ C ​​$ C,刚开始仪器,然后点击录制按钮,用于实时分析:内存,CPU,泄漏,GPU,ETS。然后找到你的尖峰上的视觉图形和显示实际堆栈踪迹的瓶颈,双击,以显示你的源$ C ​​$ C与覆盖CPU的花费上,例如每个源代码行个内联。

On the iPhone SDK you have a nice tool called Instruments, it is build on top of SUN's DTrace tool. Use it to profile any running application on simulator or on device. No changes to source code, just start Instruments and click the Record-button, for real-time profiling of: memory, CPU, leaks, GPU, ets. Then find your spikes on the visual graphs and display actual stack-traces for the bottle necks, double click to show your source code inline with overlays for percentage of CPU spend on each source line for example.

在Android上,你可以添加语句 Debug.startMethodTracing(字符串文件名),在源$ C ​​$ C。然后使用 traceview 工具检查的结果,拉出文件的模拟器或设备后。它的工作原理,但不是很漂亮。

On android you can add the statement Debug.startMethodTracing(String filename), in your source code. And then use the traceview tool to inspect the result, after pulling the file out of the emulator or device. It works, but is not quite as nice.

持久化数据

在iPhone OS,你有一个叫做核心数据非常不错的框架,它是在SQLite数据库之上的ORM。你有一个可视化的图形工具与属性和关系设计你的实体。除了视觉设计的版本升级。所有的SQL被隐藏起来。默认情况下所有实体的处理方式 NSManagedObject 的实例和值取一样,如果从地图,如果你喜欢,你可以实现自己的 NSManagedObject <子/ code>额外的逻辑,分配他们在可视化工具和核心数据将实例化你的类,而不是在那里approperiate。

On iPhone OS you have a very nice framework called Core Data, it is an ORM on top of SQLite databases. You have a visual graph tool for designing your entities with attributes and relations. As well as visually designing version upgrades. All SQL is hidden away. By default all entities are handled as instances of NSManagedObject and values are fetched like if from maps, if you like you can implement your own subclasses of NSManagedObject with extra logic, assign them in the visual tools and Core Data will instantiate your classes instead where approperiate.

安卓也使用SQLite,有一个被称为数据提供者,其中的数据可以在应用程序之间共享非常酷的功能。请求数据由URI和返回作为穿越游标。从客户端这个概念是非常灵活的,实际上辉煌。在服务器端不是很漂亮,你将必须实现从大部分URI的映射到SQL自己。通常,在两层,从一个URI的映射到实际的请求,然后下降到 SQLiteDatabase 查询,这是SQL但并不完全。

Android also uses SQLite and have a really cool feature called Data Providers, where data can be shared between applications. Data is requested by URI and returned as traversable cursors. From client side this concept is very flexible, brilliant actually. On server side not quite as nice, as you will have to implement most of the mapping from URI down to SQL yourself. Often in two layers, from from an URI-mapper to actual requests, and then down to SQLiteDatabase queries, that are SQL but not quite.

打开GL

在iPhone上你的OpenGL ES 1.1,或者2.0的iPhone 3GS和最新的iPod Touch一代。由于Objective-C的是一个严格的超集的C,你只需使用官方的OpenGL ES头。清凉值得注意的是,所有的用户界面是使用OpenGL iPhone上的硬件加速。所有的UI元素由 CGLayer 这是一个OpenGL的多边形的抽象的实例支持。这意味着,用户界面​​组合物,平移,缩放和所有其他转换是在GPU上完成的。在下行路上没有UI组件能超过1024×1024像素,如果你想要更多,你必须做的平铺。

On the iPhone you have OpenGL ES 1.1, or 2.0 for iPhone 3GS and latest iPod Touch generation. Since Objective-C is a strict superset of C, you simply use the official OpenGL ES headers. A cool note is that all UI is hardware accelerated using OpenGL on iPhone. All UI elements are backed by instances of CGLayer that is an abstraction of a OpenGL polygon. This means that UI composition, translation, scaling and all other transformations are done on the GPU. On the downside no UI component can be more than 1024x1024 pixels, if you want more you must do tiling.

在Android上,你必须的OpenGL ES 1.1的Java绑定 - JSR-239。它工作正常,UT需要在字节的使用,和int缓冲区从Java运行时的实际传输数据到本地的OpenGL ES的实现。 正常的用户界面软件渲染的,所以如果你想要的GPU加速,那么你必须明确地使用OpenGL。

On Android you have OpenGL ES 1.1 with Java-bindings - JSR-239. It works as expected, ut requires use on byte, and int buffers for transferring actual data from the Java run-time to the native OpenGL ES implementation. The "normal" UI is software rendered, so if you want GPU acceleration then you must use OpenGL explicitly.

用户交互

iPhone是唯一的接触 - 期间,没有硬件按钮,第三方应用程序可以利用。上档触摸API:■都被设计为多点触控。目前最多的平台,支持5个同时触摸点的API不公开这个平台的限制。这些API也暴露了基本的手势,如刷卡和震动的支持。

The iPhone is touch only - period, no hardware buttons that 3rd party applications can take advantage of. On the upside the touch API:s are all designed for multitouch. Currently the platform supports up to 5 simultaneous touch points, the API do not expose this platform limitation. The APIs also exposes support for rudimentary gestures such as swipes and shakes.

这是Android的,你有更多的输入法;硬件按钮,完整的QWERTY键盘,跟踪球,而不是最少的触摸。触摸API是在Android 1.6,势必1触摸点,所以不能没有引入新的API实现多点触控。这是游戏的一大缺点,使其无法实现播放模式,你可以在同一时间拍摄的走在触摸式输入,非常重要的现在,没有物理按键的设备进入市场。

An android you have many more input methods; hardware buttons, full qwerty-keyboards, track-balls, and not the least touch. The touch API as on Android 1.6 is bound to 1 touch point, so multi-touch can not be realized without introducing new APIs. This is a major drawback for games, making it impossible to implement a play-scheme where you can shoot at the same time as walking on touch-based inputs, very important now that devices without physical buttons are coming to market.

这篇关于哪些移动平台会更有价值的学习作为一名开发人员(iPhone VS棕榈pre对Android的)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆