Some time back, I took a session on 'Getting Started with Android' in my previous company.
When we are getting started with android, there's so much to grasp. There are so many different components and it's very important to introduce each one of them to just the right depth, otherwise the audience may get lost in the middle. So, it was quite a challenge to prepare the material.
I decided to introduce the following components in the session :
- Activities
- Intents
- Services
- Broadcast Receiver
- Recycler View
- Storage in Android
- Async Task
- floating action button
And this repository contains the demo code that I used in my session. Something had to be done to make it easy for the audience to take all this, so this is the approach that I followed :
The repository contains different branches, each corresponding to a particular functionality. So, if you want to see the code changes for a particular one, you can just see the diff between this branch and the its previous branch.
Here's the order in which I have prepared the branches :
- helloworld : basic hello world project
- listview : added a simple listview
- addnewcontacts : added a floating action button to add a new contact to the list
- addeddatabase : integrated SQLite database, so that the contacts storage is persistent.
- syncusingasync : syncing the contacts from the server using AsyncTask
- syncusingservice : instead of asynctask, syncing with the server using an IntentService.
If you want to see how to move from async task to an intentservice, you can do :
git diff syncusingasync..syncusingservic
e
IMO, people won't be bored if you are showing them real code in between your theory slides.
Cheers !
Comments
Post a Comment