View Single Post
  #1 (permalink)  
Old January 5th, 2014, 10:01 AM
wolfenr wolfenr is offline
Authorized User
Points: 65, Level: 1
Points: 65, Level: 1 Points: 65, Level: 1 Points: 65, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Oct 2012
Posts: 15
Thanks: 2
Thanked 1 Time in 1 Post
Default Critique of book (Beginning Android 4 Application Development)

OK, so I started going through this book over a year ago and, like many others, got stuck in the first couple of chapters. I then decided that I ought to get to grips with Java before getting into Android programming and spent a while on that. Several things unrelated to learning Android / Java distracted me for most of last year but I've been back and finally completed the book and all the tutorials within it and feel that it may be useful to others to give some general feedback on the book.

Firstly, the author clearly notes in the Intro two important things; a) " might want to take a programming course in Java programming first", and, b) that "...while it is always possible that by the time you read this book, a newer version of the tools may be available (SDK, Eclipse etc. etc.)... any variations should be manageable".

I agree 100% with his first statement in that you'll struggle if you don't have any other OOP programming knowledge but think his 2nd statement is somewhat of a cop-out as witnessed by many of the posts in this forum. OK, he's right, the tools have changed since it was published but, sadly he's made very little effort in these threads to help people struggling with the first few chapters. So I don't think the book deserves the title "Beginning Android 4..." as many people obviously haven't found these changes manageable.

So, to help those struggling getting started here's a couple of quick tips...

If you use the default Eclipse project setup wizard (I'd recommend this) you're likely to end up with a layout file called activity_main.xml and a Java file called and immediately you'll start running into conflicts with the code within the book. The author tends to use a layout file called main.xml so that should be easy to substitute for your own filename. For example on P33, the last line of real code he has:-
Whereas, because I used the default setup wizard, my code reads:
Because he tends to create a Java file with an appropriate name e.g. P24 he has, P38 he has etc. etc. So you either need to conform with how he creates his projects, labelling the java file with his filenames or be tuned into the fact that you'll need to change the code as you go along, replacing his calls to the java file with your own filename.

For example on P38 his 4th line of code reads:
public class Activity101Activity extends Activity {
Because I used the defaults in my project setup wizard, which many of you may do, my code reads:
public class MainActivity extends Activity {
The second problem that you're likely to experience if you use the default project setup wizard is the package name. He tends to use a default of net.learn2develop.his_package_name whereas the wizard uses com.example.your_package_name. Admittedly you'll be a few chapters in before this really starts to cause problems but problems will occur (particularly for tutorials using more than one java class file) unless the package name is correctly referenced. The first of these occurs on P54 when a 2nd java class file is created and the 2nd line of code on P55 as well as the almost last line of code on P56 needs to correctly reference whatever package name you created earlier.

Finally, what do I think of the book overall? Well I wouldn't recommend it for anyone who is really Beginning Android 4 Application Development, I'd give it a score of 5 out of 10 but, then, I don't really have any alternative recommendations.

In general I found it covers a lot of ground but doesn't really cover each step of the way thoroughly. There are some very interesting tutorials but I've been left wondering how I can adapt these coding examples for my own purposes.

Hope that helps some of you and good luck!
Reply With Quote
The Following User Says Thank You to wolfenr For This Useful Post:
nenad.bulatovic (December 5th, 2014)