Two responses to the listener-feedback show (JavaPosse #313)

* Dick and Joe are more or less right about the handling of the remote
"clicker" on the iPhone. On iPhone OS 3, the system iPod application
owns the clicker, so if you're listening to Pandora / Shoutcast /
Last.fm / etc. and you click the headset clicker, your app loses and
the iPod starts playing (either the last thing you were listening to
or the first thing in your library).  Just like Dick says.  And it
sucks.  Like Android, the fix is an API change, meaning that apps need
to be updated to handle it correctly.  Joe speculated about this, but
thought it was tied into the audio session APIs -- the new
functionality is actually in the UIApplication class itself. You call
beginReceivingRemoteControlEvents, and then you'll get asynchronous
events either from the clicker or from the audio controls in the app-
switching space.

* More germane to the topic of Java: how should people new to
programming learn Android? The guys said, basically, "learn Java
first, then learn Android."  As an author, I disagree, and I think
there's actually a huge opportunity here.

Beginners get really turned off by pre-requisites, and are often
rooted in a concrete idea of what they want to do.  They don't say "I
want to learn the collection of skills that I need to write cool
Android apps", they say "I want to write cool Android apps."  I saw
this on an iPhone book I co-wrote when, despite the fact that we (like
all the other IPhone books) said "you gotta know C", we had an influx
of converts from web programming, Flash, and even first-time
programmers, all of whom were gob-smacked the first time they saw a
pointer.  There was, and still is, an opportunity for teaching the
whole kielbasa: learn basic programming with C as your first language
and iPhone SDK as the toolset.  It's not the easiest place to begin,
but it speaks to some people's motivations better than saying "go
learn some easy kiddie language, then learn C, and then you'll be
ready for iPhone SDK".

And that's why I think there's a huge opportunity here for a
beginner's Java book that's based on Android and its SDK.  Instead of
command-line-based exercises that do boring-ass println()s, and an
implicit assumption that the reader will be moving on to an oh-so-
fascinating career in webapp development, there could be a beginner's
Java book that embraces the Android APIs and its SDK from Day One.
The reader would learn loops, conditionals, object-orientation and the
rest not through artificial exercises, but by putting pixels on the
Android Emulator.

Plus, standardizing on Android's Eclipse-based toolset (available on
Windows, Mac, and at least one dirty hippie OS) solves numerous
"getting started" problems that a lot of authors hand-wave around by
saying "go to java.sun.com, find the appropriate SDK, figure out how
to install for your system, and boy I hope you enjoy working on the
command line".

I appreciate that there are purists who argue that this approach is
going to lead to tool dependency and bad habits, but I've come to
realize that beginners are deeply invested in concretes, and that
abstraction comes to them later. Trying to lecture a young person --
or someone contemplating a career swap -- on software engineering
principles and language concepts just doesn't work.  They want
results, and I think teachers and authors could try embracing that.
The wisdom and the conceptual understanding will come later to those
who stick with it.

--Chris

-- 
You received this message because you are subscribed to the Google Groups "The 
Java Posse" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/javaposse?hl=en.

Reply via email to